İçereği Atla
Menü
Bu soru işaretlendi
1141 Görünümler

Hi,


I would like to restrict salespeople to see only Customers from specific industries.

For example: Salespeople who sell to Supermarkets should only see Customers that have Supermaket as their Industry_id


What I've done:

- Created a Rule with domain filter [('industry_id','=','Supermarket')] on model Contact

- Tested the Rule as a Global Rule and it worked fine

- Created a Group, added Users (Salesperson) and added the Rule to it

- Tested the Rule again and it did not work!


I believe it's not working because Odoo handles non-global rules with an OR operator:

- Since Group: Internal Users already uses a domain filter altering Contact to display only non-private customers

- Than Odoo is displaying Customers that either are non-private OR that have Industry_id = Supermarket


How can I solve this problem?


Note:

- If I deactivate the non-private customers Rule from Group: Internal Users, than the administrator loses access to Settings/Users records

Avatar
Vazgeç