How to make a user see only reccord he has created, and admin user see all the reccord created by all users.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Accounting
- Inventory
- PoS
- Project management
- MRP
This question has been flagged
As an example, check the access group “Sales / User: Own Documents Only” which has a Record Rule on Sales Orders (and Quotations) with this domain:
['|', ('user_id','=',user.id), ('user_id','=',False) ]
This will only allow access to a user’s own orders / quotations (or any with no salesman (user_id
) specified). Then you need a second Record Rule to allow other users access to all quotations.
you should use record rule for that
https://www.odoo.com/documentation/13.0/reference/security.html#record-rules
https://github.com/odoo/odoo/blob/12.0/addons/mail/security/mail_security.xml#L46
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
Sign up
See: https://www.youtube.com/watch?v=p8gj1dEfYUM&list=PLqRRLx0cl0hoJhjFWkFYowveq2Zn55dhM&index=33
Show Records that are related to active user: https://goo.gl/F42kRf
or use
Server Action: http://learnopenerp.blogspot.com/2020/01/odoo-server-action.html