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')})