Assignment group Assign To is not populated

keval3
Tera Contributor

Hello All,

My requirement is in the service portal create incident part I have created some variables in which when category is hardware and sub category is mouse, 

then Assignment group should be Hardware

       Assign To should be Fred Luddy

I have written below script but the category and subcategory is working properly but assignment group and assigned_to is not populate. 

if(producer.category == 'hardware' && producer.sub_category == 'mouse'){
current.setDisplayValue('assignment_group', 'Hardware');
//current.assignment_group = '8a5055c9c61122780043563ef53438e3';
current.setDisplayValue('assigned_to', 'Fred Luddy');
}

 let me know what is issue with my script.

Thanks & Regards

Keval

15 REPLIES 15

keval3
Tera Contributor

I have written above script in Record prodecer

Also, you can write assignment rule like below and make it work instead of writing code in record producer. give a try. keep order as '10' so that it runs first and add value of group and assigned to directly in 'Assign to' tab. mark my answer as correct in case if it resolves your issue.

 

find_real_file.png

Please hit like and mark my response as correct if that helps
Regards,
Musab

Aman Singh_
Kilo Sage

Hi,

 

It should be

 

current.assignment_group.setDisplayValue('Hardware');

current.assigned_to.setDisplayValue('Fred Luddy');

 

Thanks,

Aman

Hi Aman,

still it's not working I have put screen snap as well.

find_real_file.png