- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Tuesday
Upfront my grasp of Glide and coding in general is rudimentary and working on being more proficient but it's a challenge. What I am trying to do is display specific variables based on the Approver's ID. This mail script is called by a notification that is specific to this one catalogue item. What seems to be happening is the validation piece isn't working though I have no errors. Below is the script I have (cobbled together using a couple other community posts I have seen). Variable 1 and Variable 2 were the two paths I was going down without much success but hopefully someone can guide me and it is just a small change.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Tuesday
If the notification calling this mail script is running on the sysapproval_approver table, then 'current' will refer to the approval record. Technically, your 'while(getvariables... should be if(... since only one record will be returned, but in this case 'while' will also work. Your if statement would look more like this to access the 'variables' object on the retrieved sc_req_item record:
if (getvariables.variables.uar_approver_1 == sysapprover) {
template.print('Access Details:' + getvariables.variables.uar_reason_1);
}
There are still a bunch of reasons this could not be working - incorrect variable names or types,... so try adding some gs.info messages to log the progress.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Wednesday
My issue was I had deleted the last line <current, template, email, email_action, event) which is required for the script to run, added it back in and everything worked with the suggestions from Brad before. Thanks Gentlemen for the assistance.

