- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2018 09:32 AM
Hi All,
Currently on our Normal change workflow we send out a peer review approval. This is sent to the primary group of the person who the log is request by.
Out change manager wants to change this step of approval. They would like the group approval to be sent to the assignment group of each change task.
How would we achieve this?
Thanks
Sam
Solved! Go to Solution.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-16-2018 05:04 AM
Youre getting the same sys_id x number of time due to the way javascript works behind the scenes here...
Try using the following which should get you the unique sys_id for each group.
gr.getValue('assignment_group');
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2018 09:52 AM
Hi Sam,
Has the Change tasks been created and assigned to groups at the point where you want to send out the approvals? Then you can create a script to loop all tasks related to the change record and fetch the assignment groups from the tasks.
Regards,
Niklas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2018 11:53 AM
Hi Nicklas
Thanks for the above, all tasks would be created and assigned to groups before the approvals would be requested.
Do you have an example script?
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-16-2018 03:43 AM
Hi All,
I've attempted to create a script in the group approval, but I am only getting an approval for the last group from the script. As can see below 'Server team' is the last group in my log statement. This is the only group I am getting an approval for. As their are 3 tasks on the change request I want each assignment group to be sent a group approval I.e. Strata Services, Server Team & Web Services Project. I'm guessing that my array is only being populated with the last result, fairly new to coding so not sure where I have gone wrong on the Below :
Scirpt
Log Statement Results
Approval being set
tasks on the change request before being sent for the approval
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-16-2018 04:59 AM