Availability |
Odoo Online
Odoo.sh
On Premise
|
Lines of code | 90 |
Technical Name |
hide_menu_user |
License | LGPL-3 |
Website | https://www.cybrosys.com |
Versions | 14.0 15.0 16.0 17.0 18.0 |
This Module Helps To Hide any Menu items user wise.
Hide Any Menu User Wise

Blog and Video Details

Read Blog
Read Our Detailed Blog
https://www.cybrosys.com/blog/how-to-hide-specific-menus-for-individual-users-in-odoo-18
Are you ready to make your business more
organized?
Improve now!
Key Highlights
Compatible
Available in Odoo 18.0 Community and Enterprise.
Easiness
Easily hide any menu/submenu items user-wise.

Sale Order Menu
Before adding the hide menu option you can see the Specific Menu.

Create New Hide Specific Menu
Go to Settings > Users and there you can see the 'Hide Specific Menu' tab where you can select any Menu/Submenu that needs to be hidden to the selected user.

Select Menu
Click on 'Add a line' and select the menus that needs to be hidden for this user.

As you can see the menus and corresponding views are now hidden for the user.

Available in Odoo 17.0 Community and Enterprise
Easily hide any menu/submenu items user-wise.
Yes, you can. When you hide a menu for a user, the system automatically updates the restricted user list for that menu. You can hide the same menu for multiple users by selecting it in each user's form.
No, by default, admin users will still have access to all menus. There is a feature that checks if a user is an admin, and the "Hidden Menu" field will not be available for admins.
Yes, you can hide both submenus and parent menus. However, you need to manually select each menu (parent or child) that you want to hide.
Latest Release 18.0.1.0.0
01st October, 2024- Initial Commit
Please log in to comment on this module
Report comment
Any abuse of this reporting system will be penalizedLogIn error with portal user.
Bellow error faced while log-in with portal user:
Error message:
Simple and works well
Thank you!
correction in v16,v17,v18
ir.ui.menu model and create an ir.rule for it, but there's an issue with how Odoo handles security rules for this particular model.
donc:
1- delete rule:
<record id="restrict_menu_user" model="ir.rule"> <field name="name">Restrict Menu from Users</field> <field ref="model_ir_ui_menu" name="model_id"/> <field name="domain_force">[('restrict_user_ids', 'not in', [user.id])]</field>
</record>
2- you should override the _filter_visible_menus method of the menu model to implement your restriction logic
Re: correction in v16,v17,v18
Thanks for reporting. We have updated the app in all three versions.
Looks like it works.
Haven't tested hiding a menu, but it shows up under the user's profile, so that's a good sign.
not working in v18
When trying to install it I get the following error:
while parsing /tmp/tmpqd_tut2i/hide_menu_user/security/security.xml:4, somewhere inside <record id="ir_ui_menu_rule_user" model="ir.rule"> <field name="name">Restrict Menu from Users</field> <field name="model_id" ref="model_ir_ui_menu"/> <field name="domain_force">[('restrict_user_ids','not in',user.id)]</field> </record>
Re: not working in v18
Sorry, We were not able to reproduce the issue you mentioned.
Following ur guide but does't working in v17!!
Re: Following ur guide but does't working in v17!!
Are you using v18 or v17?