How to hide a module from filter navigator depending on a particular role
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-05-2018 08:29 AM
I know that depending on role we can show/hide a module from users. However, the scenario is I have created a custom role and added that role to a specific set of users. Now I want to hide a module from navigation bar for that specific set of users.
Kindly let us know how can I achieve this?
- Labels:
-
Personal Developer Instance

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-05-2018 12:42 PM
To say the least You can definitely grant visibility to navigation bar for a set of user who has a certain role. Now naturally a solution would be just don't give the role to the set of user you don't want them to see it, and give the roles to all other users (using groups maybe)
Now I'm not sure if you can do the other way around as you described, to deny visibility for user based on role.
Anyhow, the related setting is in studio under navigation->application Menus

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-05-2018 12:46 PM
I don't think you can do it in this manner. I think the system only allows you to add roles that you want to see it not that you don't.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-05-2018 01:05 PM
This can be achieved by a 'before' Business Rule,however that will hamper the performance if you maintain too many users.
This post may be helpful for you: https://community.servicenow.com/community?id=community_question&sys_id=ec938765dbd8dbc01dcaf3231f96...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-08-2018 04:48 AM
Thanks Anubhav for your response!
I have tried to implement the solution mentioned in the post provided by you but no luck. I have also written one before query business rule as suggested by you, however the script is only able to hide the record. It shows "Record not found" when you click on "Edit module" button of a particular module but unable to hide it from the navigation bar.
Do you have any other idea by which I can accomplish this requirement?