Radion is_coworker

This commit is contained in:
michel 2017-11-27 14:52:39 +01:00
parent 6a1e2cdd28
commit 7e9a754b44
2 changed files with 5 additions and 7 deletions

View File

@ -11,6 +11,7 @@ class ResPartner(models.Model):
is_coworker = fields.Selection([('is_coworker', 'Is_coworker')])
company_ids = fields.One2many(
string="Company",
comodel_name="res.partner",

View File

@ -8,16 +8,13 @@
<field name="inherit_id" ref ="base.view_partner_form" />
<field name="arch" type="xml">
<field name="company_type" position="after">
<div class="oe_title">
<field name="is_company" position="before">
<field name="is_coworker" widget="radio" class="oe_edit_only" options="{'horizontal': true}"/>
</div>
</field>
</field>
<field name="parent_id" position="after">
<field name="coworker_type" />
<field name="contact_date" />
<field name="coworker_type" attrs="{'invisible': [('is_coworker','!=', 'is_coworker')]}" />
<field name="contact_date" attrs="{'invisible': [('is_coworker','!=', 'is_coworker')]}"/>
</field>
<field name="email" position="after">