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

Good day

i'm trying to edit the hr_applicant form view and there's a selection field, with values "Yes" and "No" (ok, ok is not boolean but the bosses want a selection field) and they want to keep other fields hidden when the selection field says no... if the selection field says "yes" the other fields appears; example:

Have car? = "Yes or not"

if "Yes" appears:

marc: chevrolet

model: camaro

year: 1969


is there a way to do that?

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

yes, there is a way like this:

<field name="have_car"/>
<field name="marc" attrs="{'invisible': [('have_car', '=', 'no')]}"/>
<field name="model" attrs="{'invisible': [('have_car', '=', 'no')]}"/>
<field name="year" attrs="{'invisible': [('have_car', '=', 'no')]}"/>


อวตาร
ละทิ้ง
ผู้เขียน

Perfect, Thank you bro.

Related Posts ตอบกลับ มุมมอง กิจกรรม
2
ก.ย. 17
8292
0
ก.ย. 15
4478
2
ก.ย. 15
11008
1
ก.ย. 15
3627
1
ก.ย. 15
6995