Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
2 Trả lời
11872 Lượt xem

Hi,

We are running Odoo Enterprise v10. And are using Multi-Company.

What I need help with:
Company  A Contacts should not be seen by Company B, and vice-versa.

What I tried:
I changed the record rule for res.partner, but then our employees were not able to create Timesheets, and were having several errors when they tried to access something. So I had to revert back to the way it was. Now everyone can see both companies Contacts, even when they are not set up to be able to have access to that company.

How can I achieve this?
Thanks.        

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

First : In Setting of multi company, unchick the Commo Contact Book option.

This will restrict users to see contact of other company which haven't access to it.

second: you can  add domain  rule like this in python code

 
return {
'domain':{'company_id':[('company_id','=', user.company_id)]},
}
Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 6 23
4474
1
thg 6 22
6510
0
thg 12 21
2724
1
thg 3 21
5920
1
thg 2 20
4409