From 1f6e674ae663df7df392d8f937c7a523ede83555 Mon Sep 17 00:00:00 2001 From: yostashiro Date: Mon, 16 Mar 2026 10:25:54 +0000 Subject: [PATCH] [6505][IMP] stock_outgoing_shipment_report: fall back to product template to identify stock secondary UoM --- stock_outgoing_shipment_report/models/stock_picking.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/stock_outgoing_shipment_report/models/stock_picking.py b/stock_outgoing_shipment_report/models/stock_picking.py index dcf21813..2cc95e54 100644 --- a/stock_outgoing_shipment_report/models/stock_picking.py +++ b/stock_outgoing_shipment_report/models/stock_picking.py @@ -27,7 +27,10 @@ def generate_stock_outgoing_shipment_report(self): "client_order_ref": sale_line.client_order_ref, "memo": sale_line.note[:9] if sale_line.note else False, } - secondary_uom = move.product_id.stock_secondary_uom_id + secondary_uom = ( + product.stock_secondary_uom_id + or move.product_tmpl_id.stock_secondary_uom_id + ) if secondary_uom: factor = secondary_uom.factor * move.product_uom.factor vals.update({"case_qty": int(move.quantity / (factor or 1.0))})