We've updated the ServiceNow Community Code of Conduct, adding guidelines around AI usage, professionalism, and content violations. Read more

assign to field is not displaying in incident form

Fahimas
Tera Contributor

hello!! iam new to servicenow

i have created a button assign to me for incident table. that was not displaying on the form ,what can i do to overcome these?

visibility script:

              current.state=='1'&&gs.getUser().isMemberOf(current.assignment_group); 

onclick script:

function assign(){
current.assigned_to = gs.getUserName();
current.state = '2';
current.update();
current.actionRedirectUrl();
}
 
and iam also having an doubt to write the script for visiblty that the condition is the button should be visible only caller assigned to ,how can i write the script for it ?
 

 

1 ACCEPTED SOLUTION

Dr Atul G- LNG
Tera Patron

Hi @Fahimas 

 

Did you added that button /UI Action on Form ?

In UI action, you need to select the positions where UI action will be showed. 

Also just to let you know Assign to me is OOTB available. Give some separate name.

*************************************************************************************************************
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/dratulgrover [ Connect for 1-1 Session]

****************************************************************************************************************

View solution in original post

1 REPLY 1

Dr Atul G- LNG
Tera Patron

Hi @Fahimas 

 

Did you added that button /UI Action on Form ?

In UI action, you need to select the positions where UI action will be showed. 

Also just to let you know Assign to me is OOTB available. Give some separate name.

*************************************************************************************************************
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/dratulgrover [ Connect for 1-1 Session]

****************************************************************************************************************