- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-14-2024 12:29 AM
Hello all,
I have a requirement for making attachment mandatory on sc_task, but i have multiple catalog task and i want to make attachment mandatory on a particular task. please let me know how we can achieve it.
Thanks in Advance
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-14-2024 03:35 AM
Hello VickyRai1,
Please use the below code in Business Rule
(function executeRule(current, previous /*null when async*/) {
// gs.addInfoMessage("Result:"+current.hasAttachments());
if(current.hasAttachments() != true){
gs.addInfoMessage("Please add an attachment");
current.setAbortAction(true);
}}
)(current, previous);
And set When to run as before , update.
use condition as requested item.item is "catalog item name".
and state changes to closed complete.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-14-2024 03:37 AM
Thankyou So much Shubham Pal,
This works Fine.