- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-06-2015 04:39 AM
Hello,
We are reviewing all the notifications and trying to customize those if required.
While doing so, we have encounter with notification template "change.itil.approve.role" which uses the email script "change_request_summary"
var keys = [];
var set = new GlideappSequencedQuestionSet();
set.setTableName(current.sysapproval.sys_class_name);
set.setTableSysID(current.sysapproval);
set.load();
var vs = set.getFlatQuestions();
if (vs.size() > 0)
printVariables(vs);function printVariables(vs) {
template.space(4);
template.print("Summary of Change request:<br />");for (var i=0; i < vs.size(); i++) {
if(vs.get(i).getLabel() != '')
template.space(4);
template.print(' ' + vs.get(i).getLabel() + " = " + vs.get(i).getDisplayValue() + "<br />");
}
}
I haven't seen something being printed out on emails via this script though.
Also, I thought "GlideappSequencedQuestionSet" would be the script include but haven't found it in script include section.
Can someone share some light on it what exactly this script does? Also where I can find the function / method GlideappSequencedQuestionSet defined?
Any reason why it is not currently printing anything? We are not using record producers so no variables. Changes are created directly by ITIL role people.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-06-2015 06:45 AM
Hi Deepak,
I do not think there is a way that you can get to the definition of this Utility class.
I would go with current need here and say do not add this to your custom notification. In future, You can always add it,if at all required.
Thanks
Srinivas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-06-2015 06:14 AM
Hi Deepak,
"GlideappSequencedQuestionSet" is a package call. You wont find its definition in the instance.
More details about the package calls here http://wiki.servicenow.com/index.php?title=Packages_Call_Replacement_Script_Objects#gsc.tab=0
The script basically prints the producer variables(if any available)in a sorted order. Yes, You are correct. Since you are not creating the Change tickets to Record producers its not printing anything.
Thanks
Srini
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-06-2015 06:23 AM
Thank you Sri,
Any way to find its definition and its properties / methods?
Would you recommend to get rid of this script in our custom notification that we are planning to launch or to just append this one as well in that notifcation?
We might have changes via record producer in future.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-06-2015 06:45 AM
Hi Deepak,
I do not think there is a way that you can get to the definition of this Utility class.
I would go with current need here and say do not add this to your custom notification. In future, You can always add it,if at all required.
Thanks
Srinivas