[FIX]Corrected indentation issue.
bzr revid: tta@openerp.com-20121009062305-kxsxabgrjrzz5gr3
This commit is contained in:
parent
ecd65f4b88
commit
90079f6752
|
@ -152,10 +152,10 @@ class product_uom(osv.osv):
|
|||
def onchange_category_id(self, cr, uid, ids, category_id):
|
||||
reference_uom = False
|
||||
if category_id:
|
||||
uom_ids = self.search(cr, uid, [('category_id', '=',category_id),('uom_type', '=', 'reference')])
|
||||
uom_ids = self.search(cr, uid, [('category_id', '=',category_id),('uom_type', '=', 'reference')])
|
||||
if uom_ids:
|
||||
reference_uom = uom_ids[0]
|
||||
return {'value':{'reference_uom_id': reference_uom}}
|
||||
reference_uom = uom_ids[0]
|
||||
return {'value':{'reference_uom_id': reference_uom}}
|
||||
|
||||
def _compute_qty(self, cr, uid, from_uom_id, qty, to_uom_id=False):
|
||||
if not from_uom_id or not qty or not to_uom_id:
|
||||
|
|
|
@ -461,7 +461,7 @@
|
|||
<group>
|
||||
<group>
|
||||
<field name="name" on_change="onchange_name(name)"/>
|
||||
<field name="category_id" on_change="onchange_category_id(category_id)"/>
|
||||
<field name="category_id" on_change="onchange_category_id(category_id)"/>
|
||||
<field name="active"/>
|
||||
</group>
|
||||
<group>
|
||||
|
@ -471,8 +471,8 @@
|
|||
<div style="margin-left: -12px;">
|
||||
<field name="factor_inv" class="oe_inline" attrs="{'invisible':[('uom_type','!=','bigger')]}" String="Computation" nolabel="1"/>
|
||||
<label string="1" attrs="{'invisible':[('uom_type','!=','smaller')]}"/>
|
||||
<field class="oe_inline" name="reference_uom_id" attrs="{'invisible':[('uom_type','=','reference')]}" nolabel="1"/>
|
||||
<label string="="/>
|
||||
<field class="oe_inline" name="reference_uom_id" attrs="{'invisible':[('uom_type','=','reference')]}" nolabel="1"/>
|
||||
<label string="="/>
|
||||
<field class="oe_inline" name="factor" attrs="{'invisible':[('uom_type','!=','smaller')]}" String="Computation" nolabel="1"/>
|
||||
<label string="1" attrs="{'invisible':[('uom_type','!=','bigger')]}"/>
|
||||
<field class="oe_inline" name="name_ref" nolabel="1" attrs="{'readonly': True}" width="1"/>
|
||||
|
|
Loading…
Reference in New Issue