diff --git a/addons/sale_stock/sale_stock.py b/addons/sale_stock/sale_stock.py index 63f03f4a64f..2f817e09978 100644 --- a/addons/sale_stock/sale_stock.py +++ b/addons/sale_stock/sale_stock.py @@ -197,7 +197,8 @@ class SaleOrderLine(models.Model): #Note that we don't decrease quantity for customer returns on purpose: these are exeptions that must be treated manually. Indeed, #modifying automatically the delivered quantity may trigger an automatic reinvoicing (refund) of the SO, which is definitively not wanted if move.location_dest_id.usage == "customer": - qty += self.env['product.uom']._compute_qty_obj(move.product_uom, move.product_uom_qty, self.product_uom) + if not move.origin_returned_move_id: + qty += self.env['product.uom']._compute_qty_obj(move.product_uom, move.product_uom_qty, self.product_uom) return qty @api.multi