Get Started with Redwood for Oracle Cloud HCM Begin Now
To ensure that questions get required attention from community members and are NOT left unanswered, it’s important for the author to indicate (by selecting “Yes” or “No” when prompted) whether the question was answered. (newly added) Please note that it is also important to respond to EACH comment your question receives. Your Yes or No response ensures an accurate status for your question.
For more information, please refer to this announcement explaining best practices for getting answers to questions.
For more information, please refer to this announcement explaining best practices for getting answers to questions.
EL Expressions - Possible to have a 'true' and a 'false' within the same statement.
Summary
Attempting to limit icons to be visible by role and also invisible by role.Content
Hello,
I am trying to limit an icon using an EL Expression that looks at roles, I'd like to grant permission to the icon for Role1 and Role 2, but hide if a user has Role 3.
#{securityContext.userInRole['ROLE_1,ROLE_2]} and
#{(securityContext.userInRole['ROLE_3'])?true: false} - the validation returns True and False but hides the icon entirely.
It works correctly using each expression individually but not together, its almost as if the expression is saying, ROLE 1, ROLE2 or ROLE 3 = false
Is anybody aware of a way to use both true and false statements within an expression? or another way of limiting an the icon.
Tagged:
1