From 36a13c04deb79269a337d9abeee264704afdc86d Mon Sep 17 00:00:00 2001 From: liaodanlong Date: Mon, 12 May 2025 10:55:21 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=87=E8=B4=AD=E7=94=B3=E8=AF=B7=E6=95=B0?= =?UTF-8?q?=E9=87=8F=E4=B8=8E=E4=BA=A7=E5=93=81=E6=95=B0=E9=87=8F=E4=B8=8D?= =?UTF-8?q?=E4=B8=80=E8=87=B4=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sf_manufacturing/models/mrp_production.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sf_manufacturing/models/mrp_production.py b/sf_manufacturing/models/mrp_production.py index b9d75545..e8dd3b10 100644 --- a/sf_manufacturing/models/mrp_production.py +++ b/sf_manufacturing/models/mrp_production.py @@ -928,6 +928,8 @@ class MrpProduction(models.Model): 'sf_stock.stock_route_process_outsourcing').id)] for product_id, request_line_list in grouped_purchase_request_line_sorted_list.items(): cur_request_line = request_line_list[0] + if cur_request_line['product_qty'] == 1: + cur_request_line['product_qty'] = len(request_line_list) # cur_request_line['product_qty'] = cur_request_line['product_qty'] cur_request_line['request_id'] = pr.id cur_request_line['origin'] = ", ".join({item['production_name'] for item in request_line_list if item.get('production_name')})