|
@ -32,29 +32,27 @@ |
|
|
</group> |
|
|
</group> |
|
|
</field> |
|
|
</field> |
|
|
<!-- Add firstname and last name in inner contact form of child_ids --> |
|
|
<!-- Add firstname and last name in inner contact form of child_ids --> |
|
|
<xpath expr="//form[@string='Contact']/sheet//field[@name='category_id']" position="before"> |
|
|
|
|
|
|
|
|
<xpath expr="//field[@name='child_ids']/form//field[@name='category_id']" position="before"> |
|
|
<group attrs="{'invisible': [('is_company', '=', True)]}"> |
|
|
<group attrs="{'invisible': [('is_company', '=', True)]}"> |
|
|
<field name="lastname" attrs="{'required': [('is_company', '=', False)]}"/> |
|
|
|
|
|
<field name="firstname"/> |
|
|
|
|
|
</group> |
|
|
|
|
|
|
|
|
<field name="lastname" attrs="{'required': [('is_company', '=', False)]}"/> |
|
|
|
|
|
<field name="firstname"/> |
|
|
|
|
|
</group> |
|
|
</xpath> |
|
|
</xpath> |
|
|
<xpath expr="//form[@string='Contact']/sheet//field[@name='category_id']" position="attributes"> |
|
|
|
|
|
|
|
|
<xpath expr="//field[@name='child_ids']/form//field[@name='category_id']" position="attributes"> |
|
|
<attribute name="style"/> |
|
|
<attribute name="style"/> |
|
|
</xpath> |
|
|
</xpath> |
|
|
<xpath expr="//form[@string='Contact']/sheet/div/label" position="replace"> |
|
|
|
|
|
|
|
|
<xpath expr="//field[@name='child_ids']/form//label[@for='name']" position="before"> |
|
|
<div class="oe_edit_only"> |
|
|
<div class="oe_edit_only"> |
|
|
<label for="name"/> ( |
|
|
|
|
|
<field name="is_company" on_change="onchange_type(is_company)" class="oe_inline"/> |
|
|
|
|
|
<label for="is_company" string="Is a Company?"/>) |
|
|
|
|
|
|
|
|
<field name="is_company" |
|
|
|
|
|
on_change="onchange_type(is_company)"/> |
|
|
|
|
|
<label for="is_company" |
|
|
|
|
|
string="Is a Company?"/> |
|
|
</div> |
|
|
</div> |
|
|
</xpath> |
|
|
</xpath> |
|
|
<xpath expr="//form[@string='Contact']/sheet/div/h1/field[@name='name']" position="attributes"> |
|
|
|
|
|
<div class="oe_edit_only"> |
|
|
|
|
|
<attribute name="attrs">{'readonly': [('is_company', '=', False)], 'required': [('is_company', '=', True)]}</attribute> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
<xpath expr="//field[@name='child_ids']/form//field[@name='name']" position="attributes"> |
|
|
|
|
|
<attribute name="attrs">{'readonly': [('is_company', '=', False)], 'required': [('is_company', '=', True)]}</attribute> |
|
|
</xpath> |
|
|
</xpath> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</field> |
|
|
</field> |
|
|
</record> |
|
|
</record> |
|
|
|
|
|
|
|
|