OIM11gR2: ADF: Frequently used EL expressions

Category

Usage

EL [Expression Language]

User

Get the current user’s attribute value by passing the attribute name

#{oimcontext.currentUser['ATTRIBUTE_NAME']}

User

Similarly get the value for a UDF

#{oimcontext.currentUser['UDF_NAME']}

User

Gets the roles assigned to current user. Returns list of RoleEntity objects. It is a Java Bean having name, description, key, and displayName properties

#{oimcontext.currentUser.roles}

User

Return true if user is a system administrator

#{oimcontext.currentUser.roles['SYSTEM ADMINISTRATORS'] ne null}
 
User

Returns true if user is assigned with admin role

'OrclOIMSystemAdministrator'

#{oimcontext.currentUser.adminRoles['OrclOIMSystemAdministrator'] ne null}
 
User

Returns user key

#{oimcontext.currentUser.usr_key}
 
User

Returns user key

#{oimcontext.currentUser['usr_key']}
 
User

Returns user login

#{oimcontext.currentUser['User Login']}
 
Request

Returns current operation. Possible values: CREATE/MODIFY

#{pageFlowScope.requestFormContext.operation}
 
Request

Returns true if the current operation is Modify

#{pageFlowScope.requestFormContext.operation eq 'MODIFY'}
 
Request

Return the current action type. Possible values: APPROVAL/ FULFILL/ REQUEST/ VIEW/ SUMMARY.

On all approval pages/ approver view the value is APPROVAL

For Manual fulfillment page the value is FULFILL

#{pageFlowScope.requestFormContext.actionType}
 
Request

Returns true if the action type is Request i.e. the user is about to submit the request

#{pageFlowScope.requestFormContext.actionType eq 'REQUEST'}
 
Request

Returns true if the request is bulk

#{pageFlowScope.requestFormContext.bulk}
 
Request

Returns beneficiaries user ids[user login values]

#{pageFlowScope.requestFormContext.beneficiaryIds}
 
Request

Returns keys for cart items

#{pageFlowScope.requestFormContext.cartItemIds}
 
Request

Returns the type of item added to request. Possible values: ROLE/ ENTITLEMENT/ APP_INSTANCE/ USER.

#{pageFlowScope.requestFormContext.requestEntityType}
 
Request

Returns true if added item is Application Instance

#{pageFlowScope.requestFormContext.requestEntityType eq 'APP_INSTANCE'}
 
Request

Returns application instance key for the item added

#{pageFlowScope.requestFormContext.requestEntitySubType}
 
Request

Returns provisioned instance key for a modify type request

#{pageFlowScope.requestFormContext.instanceKey}
 
General

Invoke a method present on backing bean

#{backingBean.<Bean Name>.<bean method>}
General

To show a field disabled on all FULFILL and APPROVAL pages

disabled="#{pageFlowScope.requestFormContext.actionType ne 'REQUEST'}"
Comments:

Hi Shashidhar,
I would enable a menu only to users who have any AdminRoles.
So I specify in the visible parameter the following expression:

#{oimcontext.currentUser.adminRoles ne null}

But it returns always "true".
What is wrong?
Many thanks.
roberto

Posted by guest on January 21, 2014 at 08:17 AM PST #

Please try this

#{oimcontext.currentUser.adminRoles[0] ne null}

Regards
Shashidhar

Posted by guest on January 21, 2014 at 10:08 PM PST #

Where to find all the properties of beans? user, request, application_instance etc. Is there any doc reference which we can refer to build any EL ?

Posted by guest on November 27, 2015 at 05:47 AM PST #

Hi Shashidhar,

We are trying to customize the attributes based on USER type. could you please suggest the possible expression for this?

Thanks,
Kesav

Posted by guest on December 04, 2015 at 03:58 AM PST #

Try 'Xellerate Type' as the attribute name on the EL#{oimcontext.currentUser['ATTRIBUTE_NAME']}

Posted by guest on December 04, 2015 at 04:45 AM PST #

HI Shashidhar,

Thanks for the suggestion. It seems the suggested EL works for user created under specific Org, but we are trying to achieve this based on user type i.e. Employee or Contractor. Could you please suggest any EL which suits for this requirement?

Thanks,
Kesav

Posted by Kesav on December 06, 2015 at 08:58 PM PST #

Post a Comment:
  • HTML Syntax: NOT allowed
About

OIM11gR2 Blog by NA-TAG Offshore IDAM team

Search

Categories
Archives
« February 2016
SunMonTueWedThuFriSat
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
     
       
Today