How to limit a button/UI action to appear only in certain custom application modules?

Ma_ April Rais1
Kilo Contributor

Hi ServiceNow Developers,

Is there a way to limit a button/UI action to only appear in certain custom application modules?

Example: I'm trying to create a custom application that is using the "sc_req_item" table to create 3 different list view.

I tried to create a button/UI action for the users to print what is on the list. But since I am using the "sc_req_item" table the button will also appear in the default "Requested Items" module under the Self-Service app of ServiceNow since it is dependent on the same table.

Your suggestions would be highly appreciated.

Thanks  

1 ACCEPTED SOLUTION

Pradeep Sharma
ServiceNow Employee
ServiceNow Employee

View Level control :


You can use the UI Action Visibility related list to restrict a UI action by specific views.


The UI action is available for a given view according to the following rules:


  1. If there are no visibility rules, the action appears on all views.
  2. Any exclude rule on a given view means the action does not appear on that view.
  3. If there is at least one include rule, then the action appears only on views that are specifically included.

Condition level control :


To control base on tables you can use the condition something like for ex current.sys_class_name = "sc_req_item"


The above condition will make sure that the button will be visible only for table sc_req_item.



http://wiki.servicenow.com/index.php?title=UI_Actions#Restricting_Access_to_UI_Actions


View solution in original post

5 REPLIES 5

bernyalvarado
Mega Sage

Hi April,



Have you tried using the View Name field in your Application Module setup?



Administering Application Menus and Modules - ServiceNow Wiki


View Management - ServiceNow Wiki



Thanks,


Berny