Hello,
I was wondering if one of you can answer this question : why core user fields are not available for the currentUserField() formula ?
Is there a logical reason I am missing that explains this ?
Because, while digging in the code, we understand that one property was missing for core fields (calculation_visible) but it seems that other vardefs properties are involved.
For instance, we were looking on an easy way to set a field as readonly if you are not an admin. The admin field is a core user field. We are able to customize the sugarfield_is_admin.php file and include
- include/Expressions/Expression/Generic/CurrentUserFieldExpression.php
- modules/ExpressionEngine/formulaHelper.php with cleanFields function used from getValidUserFields function