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

How can I make a field (M2o) invisible if it doesn't contain any values?

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

Hi,
If your Many2one field is ‘partner_id’. Then you can set ‘invisible’ attribute inside ‘attrs’ like this in your xml file.

<field name="partner_id" attrs="{'invisible':[('partner_id', '=', False)]}"/>

Regards

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
2
ธ.ค. 19
4164
4
ม.ค. 24
23234
Attrs attribute แก้ไขแล้ว
2
ม.ค. 24
2541
Odoo Mail Sending Limit แก้ไขแล้ว
2
ธ.ค. 23
14851
0
ต.ค. 23
33