hot to dot walk from request to catalog task related field

mohamudali
Kilo Contributor

I am creating notification from the request item and wanted to filter the assignment group of the catalog task and would like to dot walk to check the assignment group of the task to determined if the notification will be sent. It there way to dot walk from request to catalog task related field?

5 REPLIES 5

Abhinay Erra
Giga Sage

If that is the case, this is not the solution. You need to trigger an event from a business rule and fire a notification based on that event. Your business rule script will look like this


var task= new GlideRecord('sc_task');  


task.addQuery('request_item',current.getValue('sys_id'));  


task.addQuery('assignment_group.name','<name of your assignment group goes here>');  


taskquery();  


if(task.hasNext()){  


gs.eventQueue('event name',current, current.getValue('assigned_to'),'');


}  



http://wiki.servicenow.com/index.php?title=Events_and_Email_Notification#gsc.tab=0