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

Hi,

Working on Odoo13, when creating a new contact (individual) in debug mode there is a field where it let you chose direction type (private, delivery...).

How can grant permission to a specific group of users to this field?

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hi, Kiko Rivera


groups="base.group_no_one"  is used for showing fields  only in debug mode
 
<field name="type" groups="base.group_no_one" attrs="{'invisible': [('is_company','=', True)], 'readonly': [('user_ids', '!=', [])]}"/>

If you want to  give access to any other groups assign multiple groups for that field ,

<field name="type" groups="base.group_no_one,base.user_admin" attrs="{'invisible': [('is_company','=', True)], 'readonly': [('user_ids', '!=', [])]}"/>
อวตาร
ละทิ้ง
ผู้เขียน คำตอบที่ดีที่สุด

How can I identify all groups available in Odoo?

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hello Kiko Rivera,

Yes, you can very well do this by assigning group to that particular field .

for reference, please consider this ...

<field name ="test" groups="group_name"/>

you can also define multiple group using comma
I hope you will understand this
Thank you....

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
0
ส.ค. 25
799
0
ก.ค. 25
524
1
ก.ค. 25
754
0
มิ.ย. 25
662
1
พ.ค. 25
1316