- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-20-2018 08:13 PM
Hello,
I have more than 10 approvals that goes to different users and groups. These requests generated as user selects variables, in this case I am trying to add comments to the approval form to let user know what he is trying to approve. Please let me know if there is any way to add comments or have a description field. Thanks!
Solved! Go to Solution.
- Labels:
-
Service Catalog
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-22-2018 05:07 PM
Thanks for the reply Bryan. I found a way to add a comment/activities by gliding approval table. To achieve this, I've created a run-script activity right after the approval activity. Once the approval request in place, my script run, look for current item's request and add a comment to let approval user know some information. Do you think this process affect anything or not a best practice to do? Thanks!
Note: This is only related to one particular Catalog Item.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-21-2018 06:36 AM
Hi SK,
Here you go..Let me know if you have any questions.
function addTexttoApprovals1(){
var currentField = current.variables.material_risk_rsp;
var apprv1 = new GlideRecord("sysapproval_approver");
apprv1.addEncodedQuery('sysapproval='+current.sys_id+'^state=requested^');
apprv1.query();
while (apprv1.next()) {
var rsp = current.variables.hnb_app_rsp;
var app = rsp.u_application;
var appName = current.variables.hnb_app;
var hnbApp = appName.name;
var lineofBusiness = app.u_primary_line_of_business;
var riskOfficer = lineofBusiness.u_segment_risk_officer;
var rof = apprv1.approver;
var wflow = apprv1.wf_activity;
var wf1ow1 = wflow.name;
//if (riskOfficer == rof && commn.indexOf('approving/rejecting') != -1){
if (riskOfficer == rof && wf1ow1 == 'Material Risk field owner approval'){
apprv1.comments='You are approving/rejecting [Material Risk - '+currentField+ '] field on the application '+hnbApp+'' ;
apprv1.update();
}
}
}
addTexttoApprovals1();
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-09-2024 04:54 AM
Hi Paul,
I have a query. As per my understanding, after the approval gets created it suppose to wait at that activity only until the approval is completed then if we put Run Script after it then how it is adding comments once the approval is created and no action has been taken on it.