I have a model with 2 actions. The 2 actions have a domain depends of the memberType field.
When I create a new record, I want to the field memberType take the value defined on the domain of the current action. Is it possible?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
I have a model with 2 actions. The 2 actions have a domain depends of the memberType field.
When I create a new record, I want to the field memberType take the value defined on the domain of the current action. Is it possible?
Hello ,
Please study this steps, I hope will find solution for your actions.
<record model="ir.actions.act_window" id="my_action_one">
<field name="name">Action One</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">my.model</field>
<field name="view_mode">tree,form</field>
<field name="domain">[('memberType', '=', 'A')]</field>
<field name="context">{'default_memberType': 'A'}</field>
</record>
<record model="ir.actions.act_window" id="my_action_two">
<field name="name">Action Two</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">my.model</field>
<field name="view_mode">tree,form</field>
<field name="domain">[('memberType', '=', 'B')]</field>
<field name="context">{'default_memberType': 'B'}</field>
</record>
Regards,
Email: odoo@aktivsoftware.com
Skype: kalpeshmaheshwari
สร้างบัญชีวันนี้เพื่อเพลิดเพลินไปกับฟีเจอร์พิเศษและมีส่วนร่วมกับคอมมูนิตี้ที่ยอดเยี่ยมของเรา!
ลงชื่อRelated Posts | ตอบกลับ | มุมมอง | กิจกรรม | |
---|---|---|---|---|
|
1
ก.พ. 16
|
3633 | ||
|
1
มี.ค. 15
|
15881 | ||
|
1
มี.ค. 15
|
8503 | ||
|
0
มี.ค. 15
|
3539 | ||
ERROR: Field does not exist
แก้ไขแล้ว
|
|
2
ส.ค. 20
|
9145 |