Odoo Help


record rules - labels / field names; from where to take it / where to look for?

Tomasz Serwanski
on 10/8/15, 5:42 AM 684 views


I am trying to set some record rules to limit visibility of records; general rule how to do it I  know, thing is that for some case I cen guess / find in internet how the rule should look like. Examples like:


are quite obvious in internet I've found also:


are also somehow clear. I've tried to find such names browsing using developer mode, and browsing what is available via 'debug window' - but even there I was not able to find labels / entries like:


where is 'user.context_departament.id'.. :/

Is there something like full list of such labels / fields? How can I  know which one I  could use? Also there are entries similar to below:


Where to find what '|' means? Also where to read what is role of all these chars like , ' | ?




Axel Mendoza

--Axel Mendoza--
| 7 8 8
Camaguey, Cuba
--Axel Mendoza--

DevOps - Full stack - Software Architect - Developer - Technology Integrator

I could help you to develop anything and solve complex problems based on technologies, integrations and tricky stuffs mostly in Python with OpenERP/Odoo, Zato, Django and many others frameworks programming languages and technologies.

I offers consulting services to anyone with an unanswered questions or needs for customizations. Think about it, maybe it's better to have an expert to solve your issues and projects than having a full-time employee trying to understand what to do and how

Reach me at aekroft@gmail.com

Axel Mendoza
On 10/8/15, 11:08 PM

For know what it's available for domains operators, check this:


For how to build a domain rule like using a function field to return a list of ids for using it in the domain, check this:


Thanks Axel - it is helpful, however still have question - where should I look to find list of all these 'user.id', 'manager_id' and others? Also where to find relation between these? I guess there are some connection between these like in any relational database, but where to find these fields and relation between them explained? regards Tomasz

Tomasz Serwanski
on 10/10/15, 6:48 AM

You define a domain for a model in Odoo. That model contains fields, you use that fields in your domain to apply criterions to the query generated by Odoo to search your model. for example, model1 have a field code you can use that field code to build a domain: [('code','=','15')]
You cannot use a field in the domain that do not belong to the model that will receive the domain search.

Axel Mendoza
on 10/10/15, 11:34 AM

For domain rules you also have the current user object to be used in the right to compare with the model field on the left. You could use domain dot notation to walk through the model relation fields, normally many2one fields

Axel Mendoza
on 10/10/15, 11:37 AM

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

2 follower(s)


Asked: 10/8/15, 5:42 AM
Seen: 684 times
Last updated: 10/8/15, 11:08 PM