Step-by-step guide
- Click on Modules.
- Select the Module with the appropriate form field to be filtered by a user’s role.
- Select the Forms tab.
- Select Master Schema button "Create/Update Fields".
- User the filter to find field that is intended to be made be filtered.
- Select Edit on the field.
- Select Custom JavaScript tab.
- As depicted in the picture below, within the "Filter” section type:
Only show SWAT-Team members in the assignee drop down:
var filteredItems = fieldScope.items.filter(function (elem) { return elem.roles.find(function (role)
return role.roleName=== 'SWAT-Team' }) !== undefined;});return filteredItems
Related articles