I want to write business rule for task sla table [please see description]

snow34
Tera Contributor

Once the SLA is breached the assignment group should be "abc"

so in the business rule i have given condition as "HasBreached is true " 

so how to write script in advanced section so that it will set the assignemnet group on incident table

1 ACCEPTED SOLUTION

HI,

Use the below..

var gr = new GlideRecord('sc_task');
gr.addQuery('sys_id',current.task);
gr.query();
if(gr.next())
{
gr.assignment_group = "sys id of the group name";
gr.update();
}

View solution in original post

7 REPLIES 7

HI,

Use the below..

var gr = new GlideRecord('sc_task');
gr.addQuery('sys_id',current.task);
gr.query();
if(gr.next())
{
gr.assignment_group = "sys id of the group name";
gr.update();
}

Kailash Bhange
Kilo Sage
Kilo Sage

Hi snow,

you can refer to the below BR, I have created for you.

find_real_file.png

find_real_file.png

 

 

Hope this helps.
If my answer resolves your issue, please mark my answer as ✅ Correct & Helpful based on the validations.

Thank You!
Regards,
Kailash

This same thing i want on sc_task table in the sc_task table the assignment group should be change once the SLA is breache