Send Notification to SCTASK Assignment group When any comments added to RITM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-28-2024 02:47 AM
HI All,
I Have a requirement to send a notification for Assignment Group of catalog task, When there is any update on Related RITM. Can Anyone Please help me on this.
Thanks,
Ravichandra G
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-28-2024 03:15 AM
You can write After update business rule, and you can call eventQueue method to trigger notification:
below is the Business rule script:
(function executeRule(current, previous /*null when async*/) {
// Check if the assignment group has been updated
if (current.assignment_group != previous.assignment_group) {
// Get the related catalog task
var catalogTask = new GlideRecord('sc_task');
catalogTask.addQuery('request_item', current.sys_id);
catalogTask.query();
if (catalogTask.next()) {
// Send notification to the assignment group of the catalog task
var assignmentGroup = catalogTask.assignment_group;
gs.eventQueue('sc_task.assigned', catalogTask, assignmentGroup, 'notification');
}
}
})(current, previous);
Create this event sc_task.assigned in event registry then use it in notification.
Please Mark ✅Correct if this solves your query and also mark 👍Helpful if you find my response worthy based on the impact.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2024 12:30 AM
If you're looking for the best programming assignment help, look no further! This service offers top-quality assistance from experienced professionals who understand the complexities of coding. Whether you're stuck on a difficult problem or need help with a project, they provide reliable support that ensures you achieve great results. Highly recommended for all programming students!