[IMP] useability: invisible contract type if defined by default

bzr revid: fp@openerp.com-20121103133510-nsuenjvgbkbxx2ub
This commit is contained in:
Fabien Pinckaers 2012-11-03 14:35:10 +01:00
parent f3a92c9633
commit e0453227ef
1 changed files with 2 additions and 2 deletions

View File

@ -23,11 +23,11 @@
<group>
<field name="partner_id" on_change="on_change_partner_id(partner_id, name)"/>
<field name="manager_id"/>
<field name="code"/>
<field name="currency_id" attrs="{'invisible': ['|',('type', '&lt;&gt;', 'view'), ('company_id', '&lt;&gt;', False)]}"/>
</group>
<group>
<field name="type"/>
<field name="code"/>
<field name="type" invisible="context.get('default_type', False)"/>
<field name="parent_id" on_change="on_change_parent(parent_id)" attrs="{'invisible': [('type','in',['contract','template'])]}"/>
<field name="template_id" on_change="on_change_template(template_id,context)" domain="[('type','=','template')]" attrs="{'invisible': [('type','in',['view', 'normal','template'])]}" context="{'default_type' : 'template'}"/>
<field name="company_id" on_change="on_change_company(company_id)" widget="selection" groups="base.group_multi_company" attrs="{'required': [('type','&lt;&gt;','view')]}"/>