Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
2915 Widoki

Hello,


I need to provide a Manager of the Parent department with access to a record of the child's department. 

I created a domain: ['|', '|', '|', '|',
('x_studio_department.manager_id.user_id', '=', user.id),
('x_studio_department.parent_id.manager_id.user_id', '=', user.id), ('x_studio_department.parent_id.parent_id.manager_id.user_id', '=', user.id),
('x_studio_department.parent_id.parent_id.parent_id.manager_id.user_id', '=', user.id),
('x_studio_department.parent_id.parent_id.parent_id.parent_id.manager_id.user_id', '=', user.id)]
but would like to minimize it's length and complexity.

Could you please advise how to rewrite it to avoid multiple 'parent' levels, and to provide access to all Managers of higher levels??

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
2
sty 24
3206
0
sty 24
1545
0
gru 20
2088
1
wrz 19
4874
0
cze 17
3132