Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
5812 มุมมอง

I have a model called Department, which contains two ManyToOne fields, one each for Manager and one for Publicist (there are more, but I have simplified the example).

I would like to create a new Security Record Rule so that each Manager can see only Users from their own department.

As far as I Know, to do this, I have to set the Object to Users when creating a new Record Rule. Where I struggle is how to iterate through all departments for each user.

Here is a Pseudocode example of what a want, the object is res.users

for each object for each department if(manager = user.id & publicist = object.id) display object

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
2
ส.ค. 24
1959
4
เม.ย. 19
5332
1
ก.พ. 16
3345
1
พ.ย. 15
4930
3
ส.ค. 15
10021