[FIX] purchase: do not pass uom in product_id_change when changing of product
authorDenis Ledoux <dle@odoo.com>
Wed, 8 Oct 2014 15:20:13 +0000 (17:20 +0200)
committerDenis Ledoux <dle@odoo.com>
Wed, 8 Oct 2014 15:21:29 +0000 (17:21 +0200)
To allow the on change to set the product default unit of measure when changing of product, and only in this case (not when changing price or quantity)

addons/purchase/purchase_view.xml

index 1746fcc..c719707 100644 (file)
                         <page string="Products">
                             <field name="order_line">
                                 <tree string="Purchase Order Lines" editable="bottom">
-                                    <field name="product_id" on_change="onchange_product_id(parent.pricelist_id,product_id,0,product_uom,parent.partner_id, parent.date_order,parent.fiscal_position,date_planned,name,False,parent.state,context)"/>
+                                    <field name="product_id" on_change="onchange_product_id(parent.pricelist_id,product_id,0,False,parent.partner_id, parent.date_order,parent.fiscal_position,date_planned,name,False,parent.state,context)"/>
                                     <field name="name"/>
                                     <field name="date_planned"/>
                                     <field name="company_id" groups="base.group_multi_company" widget="selection"/>