[FIX] stock_account: default new price if compute from BoM

When the new standard price is computed from the BoM (thanks to module
`product_extended`), the price suggested is still the standard price of
the product.
This commit is contained in:
Nicolas Martinelli
2016-07-05 09:43:29 +02:00
parent bcff661bc6
commit 51cdffcb9e
@@ -36,7 +36,7 @@ class change_standard_price(osv.osv_memory):
res = super(change_standard_price, self).default_get(cr, uid, fields, context=context)
price = product_obj.standard_price
price = context.get('default_new_price') or product_obj.standard_price
if 'new_price' in fields:
res.update({'new_price': price})