Overview
Companies often need to remove certain menus for certain people without creating many groups. This module adds a hidden menus field to the user form and filters the menu tree for that user. The restriction is mirrored on the menu itself with restricted users. Administrators control who sees what across all apps.
Usage steps
- 1
Open the user record
Go to Settings > Users and open the user to restrict. Only administrators see the new field.
- Administrator-only field
- is_admin computed
- 2
Pick the menus to hide
Select the menu items in the Hide Menu field. The list is shown as a many-to-many selector.
- hide_menu_ids
- Many2many selector
- 3
Sync with the menu record
On write the user's hidden menus update the restricted user list on each menu. This keeps both sides consistent.
- restrict_user_ids on menu
- write override
- 4
Filter visible menus
When the menu tree loads, hidden items are removed for the user. The user simply does not see them in the app switcher.
- Menu filter override
- Admins unaffected
- 5
Show only specific menus
A computed flag supports showing a chosen set of menus for a user. It helps build very limited views.
- is_show_specific_menu
Screens
Illustrative mockups with placeholder data.
—
Added by this module
—
Added by this module
Roles
| Role |
|---|
| Administrator |
Dependencies
Want to know more or try this app? Contact us
We can arrange a demo or a trial and answer your questions about Hide Menus Per User.