Users should not be able to approve their own requests
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-27-2024 09:10 PM
Hi Team ,
can anyone please help me here with my requirement .
if Requested for = approver then error message should come or abort
scirpt i have tried these many scripts
not working , can any one please help me here , what was the issue here .

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-27-2024 09:19 PM
Hi @nameisnani ,
Condition: current.source_table == 'sc_req_item' && current.sysapproval.opened_by == current.approver
Script:
(function executeRule(current, previous /*null when async*/) {
// Add your code here
current.approver = current.approver.manager;
current.comments = 'Approver is also Requester - Moved to Manager';
})(current, previous);
It was modified from a BR that I've used to auto-approved if Requester is also Approver.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2024 07:17 PM
Hi @Community Alums
This is the condition
If "Requested for " and same requested for if member of the group approval of the same catalog then requested for user shouldn't be able approve the request instead it should abort with some error message.
could you please provide me the script