- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-19-2020 08:26 PM
Hello Everyone,
I have a requirement that, - Create a New Group like, "Infrastructure Approval" with Approval names in it and add this group to the workflow. Actually,the "Infrastructure Approval" only to be the part of the approval process for the citrix option of this form, not for all the other options.
Here, I have Created a New Group like,"Infrastructure Approval" with Approval names in Workflow. And i have created a few requests for, if we select the "Citrix" option in 'Targeted OS', the "Infrastructure Approvals" were trigger(It is working fine). But, Here The Infrastructure Approvals were triggered when the Citrix is unselected(it means when we select other options).
Could anyone please suggest me how to write the Script in Workflow for "Infrastructure Approval"/ Catalog Client Script for this( "Infrastructure Approval" only to be the part of the citrix option of this form, not for all the other options)? or if any other usage works?
For your reference, Please find the below Screenshots.
Thanks&Regards,
Jayashree
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-19-2020 09:03 PM
Hello Jayashree,
Instead of writing catalog client script you can simply use wait for condition activity and set condition as
citrix is true.
Hope this will help you.
Kindly mark an answer as correct and helpful if it will resolve your query.
Regards,
Akshata
(ServiceNow Developer)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-19-2020 09:03 PM
Hello Jayashree,
Instead of writing catalog client script you can simply use wait for condition activity and set condition as
citrix is true.
Hope this will help you.
Kindly mark an answer as correct and helpful if it will resolve your query.
Regards,
Akshata
(ServiceNow Developer)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-19-2020 10:20 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-19-2020 10:33 PM
Hi Jayashree,
Are you saying if Citrix is selected you need to send approval; if not selected then skip
you can use if activity for this
Ensure you use proper variable name and value for comparison
answer = ifScript();
function ifScript(){
if(current.variables.variableName == 'Citrix')
return 'yes';
else
return 'no';
}
Mark ✅ Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-20-2020 01:27 AM
Hi Ankur,
When i have used this Script the same issue i am facing which i have mentioned in the Akshata's reply. It is not going to the next Approvals just the request is closing.
Whether i have to change the flow from Line Manager Approval to Security-SecOps team and the next Approvals?
Thanks&Regards,
Jayashree