Approve UI Action condition not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2024 02:40 AM
Hi All,
I am trying to create a new approval UI Action for a specific user role (duplicating the existing sysapproval_approver Approve UI Action). I want to hide this new UI Action from the Change request table which I have got working using
RP.isRelatedList()&&parent.sys_class_name!='change_request'
However as soon as I add more it just shows all the time even on the change table Is there something wrong with my syntax?
RP.isRelatedList()&&parent.sys_class_name!='change_request' && current.state == 'requested' && (gs.hasRole('approval_admin') || isApprovalMine(current))
I have tried a few different ways however cant get this to work
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2024 05:30 AM
Can you check the dictionary value of state? It should be numeric one.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2024 10:24 AM
current.state == 'requested' && (gs.hasRole('approval_admin') || isApprovalMine(current))
is it a list action? if so, current object will not be accessible