Control when the system displays a view
-
- UpdatedAug 1, 2024
- 2 minutes to read
- Xanadu
- Navigation and UI
Administrators can create rules that determine the conditions for when the system should display a form or list in a specified view. Administrators can also restrict views by user role.
Before you begin
Role required: admin
Procedure
Restrict view by role
You can use a script to control the form view used by different roles.
Name: Restrict View by Role
Type:
Table: Any
Description: Generally the view used on a form is controlled by either specifying the sysparm_view parameter in the url or module properties, or by inheriting the view from the previous form or list. Sometimes this does not apply, such as when opening a referenced field form from a record producer. In this case, you may want to control the view of the form based on roles. This script assumes there is a view called ess available to the current table.
- view - A string containing the name of the current view.
- is_list - A Boolean value indicating whether this is a list view.
Script: