[FIX] stock: correctly forward-port 5b83f7214f

Oversight of previous forward-port.
This commit is contained in:
Christophe Simonis
2019-08-19 19:27:53 +02:00
parent 168e54d488
commit 20e69b3299
+3 -1
View File
@@ -748,7 +748,9 @@ class UoM(models.Model):
procurement_uom = self
computed_qty = qty
get_param = self.env['ir.config_parameter'].sudo().get_param
if procurement_uom.id != quant_uom.id and get_param('stock.propagate_uom') != '1':
if get_param('stock.propagate_uom') != '1':
computed_qty = self._compute_quantity(qty, quant_uom, rounding_method='HALF-UP')
procurement_uom = quant_uom
else:
computed_qty = self._compute_quantity(qty, procurement_uom, rounding_method='HALF-UP')
return (computed_qty, procurement_uom)