How to make the assignment group mandatory

Pooja Khatri
Tera Contributor

Hello All ,

I have a requirement , where  I need to make the assignment group mandatory field and also when the assigned_to value changes the assignment group should become empty and it should become mandatory again.

Can anyone help me how I can configure this on the client side.

Thank You in advance !!

 

1 ACCEPTED SOLUTION

Hi,

is the field on form or not?

please share client script screenshot

if that doesn't work then use this normal client script on sc_req_item table

function onLoad(){

	var itemName = g_form.getDisplayBox('cat_item').value;
	if(itemName == 'Your Item 1'){
		g_form.setMandatory('assignment_group', true);
	}
}

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

20 REPLIES 20

Hi,

it should work fine

can you try making some other field as mandatory and check

Try to replicate in PDI and if possible share details

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi @Ankur Bawiskar  -- the same script is working when I make the due_date mandatory , but its not working for assignment group  .. Is this happening because assignment group is a reference field ?

 

Hi @Ankur Bawiskar   -- I tried to implement this using the UI policy and it is working correctly now .

Hi,

Good to know.

Please close the question by marking appropriate response as correct.

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Thank You for all your help