custom ui actions are not visbile to delegation approvals
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-26-2024 05:46 AM
hi
we have custom ui actions for approve and reject the requests those ui actions are working good for the approver, but when approver is not available, he is delegating his work to another user. when delegated user opens the request,
please find below script for your reference.
isValidApprover: function(approver) {
var isreturn = false;
var appr = new GlideRecord('sysapproval_approver');
appr.addEncodedQuery('sysapproval=' + approver.sys_id + '^approver=' + gs.getUserID() + '^state=requested');
appr.query();
if (appr.next()) {
isreturn = true;
}
isreturn = new ApprovalDelegationUtil().isMyApproval(current);
return isreturn;
},
approveRejectTask: function(approver, action) {
var appr = new GlideRecord('sysapproval_approver');
appr.addEncodedQuery('sysapproval=' + approver.sys_id + '^approver=' + gs.getUserID() + '^state=requested');
appr.query();
if (appr.next()) {
if (action == 'approve') {
appr.state = 'approved';
} else if (action == 'reject') {
appr.state = 'rejected';
}
appr.update();
}
},
he is not able see the ui actions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-26-2024 05:48 AM
delegated person not able to see the UI actions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2024 03:01 AM
Hello lakshman nalla, does the delegated user have the same roles than the delegator?
It seems to be a permission issue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-08-2024 10:42 AM
Unfortunately it doesn't seem to be a permission issue, I'm facing the same problem