From 0f52e22906a969a8ca3b2c38acddf5bf8a6386be Mon Sep 17 00:00:00 2001 From: Denis Ledoux Date: Tue, 4 Nov 2014 13:04:50 +0100 Subject: [PATCH] [FIX] product: use new api to retrieve user company --- addons/product/product.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/product/product.py b/addons/product/product.py index 52ae27ed945..8f4921f3974 100644 --- a/addons/product/product.py +++ b/addons/product/product.py @@ -590,7 +590,7 @@ class product_template(osv.osv): if ptype != 'standard_price': res[product.id] = product[ptype] or 0.0 else: - company_id = self.pool['res.users'].read(cr, uid, uid, ['company_id'], context=context)[0] + company_id = product.env.user.company_id.id product = product.with_context(force_company=company_id) res[product.id] = res[product.id] = product.sudo()[ptype] if ptype == 'list_price':