From baecf92146298bd08b15a2c2afb07868cf45e6ef Mon Sep 17 00:00:00 2001 From: Enrique Date: Wed, 13 Nov 2019 10:59:39 +0100 Subject: [PATCH] [12.0][FIX] stock_secondary_unit: move line create round On move line creation, the precision of secondary qty rounding is wrong; the unit of measure factor is being used instead of rounding. --- stock_secondary_unit/models/stock_move.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stock_secondary_unit/models/stock_move.py b/stock_secondary_unit/models/stock_move.py index 5b9273f10..342cac6bb 100644 --- a/stock_secondary_unit/models/stock_move.py +++ b/stock_secondary_unit/models/stock_move.py @@ -43,7 +43,7 @@ class StockMoveLine(models.Model): 'product_uom_qty', vals.get('qty_done', 0.0)) qty = float_round( move_line_qty / (factor or 1.0), - precision_rounding=move.secondary_uom_id.uom_id.factor + precision_rounding=move.secondary_uom_id.uom_id.rounding ) vals.update({ 'secondary_uom_qty': qty,