UI actions on analyst workspaces

Swetha M
Mega Guru

We've a UI action REQUEST IP BLOCK on our security incident form and it does the following, populates the IP block into the form field.

 

 

var ip_block = new GlideRecord("u_ip_block");
//var inc_record = new GlideRecord("sn_si_incident");
ip_block.u_sec_ticket = current.sys_id;
ip_block.state='-1';
ip_block.u_ip_geo_loc=current.location;
ip_block.u_ip_lob_target=current.u_lob_target;
var sysID = ip_block.insert();
current.u_ip_blocker_reqnumber = sysID;
var mySysID = current.update();

gs.addInfoMessage("IP Block Request " + ip_block.number + " created");
action.setRedirectURL(ip_block);
action.setReturnURL(current);

 

 

I want the same to be on my Analyst workspace as a button. Any advise.?

6 REPLIES 6

UI Action contains this:

 

Screenshot 2023-05-04 at 10.18.54 AM.png

Yes.. That is also done right... But there's something with the Security analyst workspaces I Believe..

 

https://docs.servicenow.com/bundle/utah-security-management/page/product/security-incident-response/...