[IMP] mrp, product, stock, project_mrp: usability of product form view
authorQuentin (OpenERP) <qdp-launchpad@openerp.com>
Fri, 20 Dec 2013 09:58:06 +0000 (10:58 +0100)
committerQuentin (OpenERP) <qdp-launchpad@openerp.com>
Fri, 20 Dec 2013 09:58:06 +0000 (10:58 +0100)
bzr revid: qdp-launchpad@openerp.com-20131220095806-16siwncivyuokrym

addons/mrp/mrp_view.xml
addons/product/product_view.xml
addons/project_mrp/project_mrp_view.xml
addons/stock/stock_view.xml

index e0591d3..0f223ab 100644 (file)
                         </div>                        
                     </group>                
                 </xpath>
-                <xpath expr="//field[@name='standard_price']" position="after">
-                    <field name="active" />                                    
-                </xpath>
             </field>
         </record>
         
index dfeb9ac..e9aac74 100644 (file)
                             <page string="Procurements" groups="base.group_user">
                                 <group name="procurement">
                                     <group name="general">
+                                        <field name="active"/>
                                         <field name="standard_price"/>
                                     </group>
                                     <group name="procurement_uom" groups="product.group_uom" string="Purchase">
                                         <field name="uom_po_id"/>
                                     </group>
                                 </group>
-                                <label for="active"/>
-                                <field name="active"/>
                                 <separator string="Description for Suppliers"/>
                                 <field name="description_purchase" placeholder="This note will be displayed on requests for quotation..."/>
                             </page>
index 08ac6c9..9964ff1 100644 (file)
             <field name="model">product.product</field>
             <field name="inherit_id" ref="product.product_normal_form_view"/>
             <field name="arch" type="xml">
-                <field name="type" position="after">
-                    <field name="project_id" attrs="{'invisible':[('type','!=','service')]}" />
-                    <field name="auto_create_task" attrs="{'invisible': [('type', '!=', 'service')]}"/>
-                </field>
+                <xpath expr="//group[@name='general']" position="after">
+                    <group string="Project Management Information" attrs="{'invisible': [('type', '!=', 'service')]}">
+                        <field name="auto_create_task"/>
+                        <field name="project_id" attrs="{'invisible':['|', ('type','!=','service'), ('auto_create_task', '=', False)]}"/>
+                    </group>
+                </xpath>
             </field>
         </record>
         <record id="task_type_edit_mrp_inherit" model="ir.ui.view">
index 6083cf4..b16fe20 100644 (file)
                 
                 <xpath expr="//group[@name='general']" position="after" >
                    <newline/>
-                   <group string="Supply Chain Information">
+                   <group string="Supply Chain Information" attrs="{'invisible': [('type', '=', 'service')]}">
                        <field name="route_ids" widget="many2many_checkboxes"/>
                    </group>
                    <newline/>