- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-07-2016 10:24 PM
Hi All,
We need to hide/remove the approve/reject when the state is not requested in approval record.
I have tried by giving current.state != 'requested' in OOB two list context menu UI action defined for sysapproval_approver table. But this is not helping. The "current" is not working in list context menu.
We can hide/remove by validating roles(gs.hasRoleExactly("zzz")), but we need to hide/remove it based on state of the approval record.
Is there any other way we can achieve this???
Thanks in advance.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-08-2016 01:35 AM
Hi All,
Thank you for your wonderful time.
Actually the "current" works in right click context menu. As am having the condition current.state == 'requested' on the UI action approve, the functionality is supposed to hide the context menu "approve" whenever the state is not 'requested'. but instead of the its throwing a "security error" as "Security does not allow the execution of that action against the specified record".
Thanks,
Joshwa

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-07-2016 10:50 PM
Hi Joshwa,
Instead of making changes in OOB UI Action it will better if you can override OOB UI Action with your own custom UI Action & make all customization in that UI Action.Refer below link for more information
Example: Override or remove a UI action for an extended table
Thanks,
Abhinandan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-07-2016 10:56 PM
Will the "current" works on right click list context menu??
I have tried it.. Its not helping me to remove approve/reject when the state is not requested.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-07-2016 10:58 PM
Hi Joshwa,
Could you please paste your condition code here?
Ideally current works on list context menu
Thanks,
Sunil Safare
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-07-2016 11:30 PM