If logged user is from USA or Canada the catalog form need to change.

kishorkumar
Tera Contributor

Hi folks

i have requirement

  If the user is from US or Canada, the users should be able to order A new Line A new Device If the user is from rest of the countries, the Request Type should be defaulted to "New Line" and should be read-only. servicenow catalog item?

 

kishorkumar_0-1698664417224.png

 

I tired the script its not fully working 

kishorkumar_1-1698664587143.png

 

Here is the script if am passing the sys id of the country it will execute properly in the if condition. If i make it like dynamically its not working as i expect so anyone help me with requirement.
3 REPLIES 3

Ankur Bawiskar
Tera Patron
Tera Patron

@kishorkumar 

why not use onChange client script + GlideAjax?

Also store the country in system property and do the comparison in script include to make it dynamic

If my response helped please mark it correct and close the thread so that it benefits future readers.

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

can you give some example script for that 

can you give some example script for that script include