How to show / hide UI actions dynamically on record page

shubham_kumar
ServiceNow Employee
ServiceNow Employee


I need to show / hide a UI action on a record page based on whether the mandatory fields are filled in or not . I referred these already answered questions here

https://www.servicenow.com/community/developer-forum/isolate-script-false-and-dom-manipulation-not-w...

https://www.servicenow.com/community/developer-blog/isolate-script-in-london/ba-p/2275821



With property glide.script.block.client.globals , the client script is able to show / hide the button via DOM manipulation.
But  i am facing an issue that when i do not have the property "glide.script.block.client.globals" as false (or it's set to true ) , it's not working for me (even when i change the isolate script option to true) . Not sure why . I am working on Xanadu release .

Any suggestions would be greatly appreciated 

1 REPLY 1

Bert_c1
Kilo Patron

UI Actions have a condition field, where logic can be specified.

 

If you have friends on the Customer Support Team, you can ask there.  Maybe someone here will provide something useful if using the Condition field won't help.