Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

How override a OOB UI Action?

Erica
Tera Guru

Hello All.

I need to override a UI Action (list banner button). What I already tried: 

1. Created a 2nd UI Action (list banner button) to the same table with the same action name and order less than the old one. 

Problem: This works when the condition field is true, BUT the problem here is when my 2nd UI Action is false the old UI Action applies for the table. I don't wanna this. If the 2nd UI Action is false any UI Action shouldn't appear. 

 

2. Created a 2nd UI Action (list banner button) to the same table with the same action name and the same order as the old one AND in field "overrides" I've selected the old UI Action.

Problem: The 2nd UI Action never appears. 

 

Any idea how I can achieve this? 

3 REPLIES 3

Chandra Sekhar6
Tera Guru

Make the first UI action - Active=false

Austin Tebbenh1
Tera Contributor

Experiencing this issue with form link UI Actions. When the actions are the same order, the override doesn't work. The override only works when the new/2nd UI action order is lower than the one I'm trying to override

Renat Akhmedov
Tera Guru

Hi @Erica,

I can see two options here:

1. You can change the UI Action condition, for example, from "gs.hasRole('itil')" to "gs.hasRole('itil') && gs.hasRole('admin')" - it's just an example, you know better what you need. 

2. As @Chandra Sekhar6 mentioned, just switch off the OOTB UI Action ("Active = false"), and create a new custom UI Action for the same table, same action name for the list banner, and same condition. 

I hope it helps you. If my answer was helpful, please don’t hesitate to give it a thumbs-up - it only takes a second, but it means a lot to me. Thank you!

Best regards, 
Renat Akhmedov