콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
1 회신
1824 화면

Hello

I am trying to create a record rule (Odoo 16) that hides all suppliers for users who are not assigned to the user group "Purchase / Users".

So far I've created an additional record rule for the model res.partner with the rule definition (domain filter): [('supplier_rank', '>', 0)]

Also I've added the group "Purchase / User" on this record rule.

This rule doesn't change anything. Users which are not assigned to the group still can see every supplier.

This rule used to work for me in odoo 12.

Thanks for all the help.

아바타
취소
작성자 베스트 답변

The record rule did not work because of another odoo standard rule: res.partner.rule.private.employee

I changed the domain of this rule from ['|', ('type', '!=', 'private'), ('type', '=', False)] to ['|', ('type', '!=', 'private'), ('type', '=', False),('supplier_rank','

Now it works.

아바타
취소
관련 게시물 답글 화면 활동
2
5월 25
885
1
7월 24
1467
4
12월 23
23984
1
8월 22
1880
1
10월 21
2091