|
|
|
@ -1230,19 +1230,16 @@ class sale_order_line(osv.osv):
|
|
|
|
|
return self.product_id_change(cursor, user, ids, pricelist, product,
|
|
|
|
|
qty=qty, uom=uom, qty_uos=qty_uos, uos=uos, name=name,
|
|
|
|
|
partner_id=partner_id, lang=lang, update_tax=update_tax,
|
|
|
|
|
date_order=date_order, context=context)
|
|
|
|
|
date_order=date_order, fiscal_position=context.get('fiscal_position', False), context=context)
|
|
|
|
|
|
|
|
|
|
def onchange_product_uom(self, cursor, user, ids, pricelist, product, qty=0,
|
|
|
|
|
uom=False, qty_uos=0, uos=False, name='', partner_id=False,
|
|
|
|
|
lang=False, update_tax=True, date_order=False, fiscal_position=False, context=None):
|
|
|
|
|
context = context or {}
|
|
|
|
|
lang = lang or ('lang' in context and context['lang'])
|
|
|
|
|
if not uom:
|
|
|
|
|
return {'value': {'price_unit': 0.0, 'product_uom' : uom or False}}
|
|
|
|
|
return self.product_id_change(cursor, user, ids, pricelist, product,
|
|
|
|
|
ctx = dict(context or {}, fiscal_position=fiscal_position)
|
|
|
|
|
return self.product_uom_change(cursor, user, ids, pricelist, product,
|
|
|
|
|
qty=qty, uom=uom, qty_uos=qty_uos, uos=uos, name=name,
|
|
|
|
|
partner_id=partner_id, lang=lang, update_tax=update_tax,
|
|
|
|
|
date_order=date_order, fiscal_position=fiscal_position, context=context)
|
|
|
|
|
date_order=date_order, context=ctx)
|
|
|
|
|
|
|
|
|
|
def unlink(self, cr, uid, ids, context=None):
|
|
|
|
|
if context is None:
|
|
|
|
|