[MERGE] lp:742100
bzr revid: qdp-launchpad@openerp.com-20110518161317-94ohmoiq5mqtrfrj
This commit is contained in:
commit
b40383f099
|
@ -234,6 +234,7 @@ class product_pricelist(osv.osv):
|
|||
[res['base_pricelist_id']], product_id,
|
||||
qty, context=context)[res['base_pricelist_id']]
|
||||
ptype_src = self.browse(cr, uid, res['base_pricelist_id']).currency_id.id
|
||||
uom_price_already_computed = True
|
||||
price = currency_obj.compute(cr, uid, ptype_src, res['currency_id'], price_tmp, round=False)
|
||||
elif res['base'] == -2:
|
||||
# this section could be improved by moving the queries outside the loop:
|
||||
|
|
|
@ -595,7 +595,7 @@ class product_product(osv.osv):
|
|||
res[product.id] = (res[product.id] * (product.price_margin or 1.0)) + \
|
||||
product.price_extra
|
||||
if 'uom' in context:
|
||||
uom = product.uos_id or product.uom_id
|
||||
uom = product.uom_id or product.uos_id
|
||||
res[product.id] = product_uom_obj._compute_price(cr, uid,
|
||||
uom.id, res[product.id], context['uom'])
|
||||
# Convert from price_type currency to asked one
|
||||
|
|
|
@ -1127,7 +1127,7 @@ class sale_order_line(osv.osv):
|
|||
else:
|
||||
price = self.pool.get('product.pricelist').price_get(cr, uid, [pricelist],
|
||||
product, qty or 1.0, partner_id, {
|
||||
'uom': uom,
|
||||
'uom': uom or result.get('product_uom'),
|
||||
'date': date_order,
|
||||
})[pricelist]
|
||||
if price is False:
|
||||
|
|
Loading…
Reference in New Issue