From 60b77e09d6590a9886167d845c5e2d2feb5a9fbe Mon Sep 17 00:00:00 2001 From: "jinling.yang" Date: Thu, 25 Jul 2024 15:40:44 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=B7=A5=E4=BB=B6=E9=85=8D?= =?UTF-8?q?=E9=80=81=E7=9B=AE=E7=9A=84=E7=94=9F=E4=BA=A7=E7=BA=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sf_manufacturing/models/mrp_workorder.py | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/sf_manufacturing/models/mrp_workorder.py b/sf_manufacturing/models/mrp_workorder.py index a2745150..ef1f6b6f 100644 --- a/sf_manufacturing/models/mrp_workorder.py +++ b/sf_manufacturing/models/mrp_workorder.py @@ -567,12 +567,16 @@ class ResMrpWorkOrder(models.Model): up_route = self.env['sf.agv.task.route'].search([('route_type', '=', '上产线')], limit=1, order='id asc') down_route = self.env['sf.agv.task.route'].search([('route_type', '=', '下产线')], limit=1, order='id asc') return [ - [0, '', {'production_id': production.id, 'type': '上产线', 'route_id': up_route.id, - 'feeder_station_start_id': up_route.start_site_id.id, - 'feeder_station_destination_id': up_route.end_site_id.id}], - [0, '', {'production_id': production.id, 'type': '下产线', 'route_id': down_route.id, - 'feeder_station_start_id': down_route.start_site_id.id, - 'feeder_station_destination_id': down_route.end_site_id.id}]] + [0, '', + {'production_id': production.id, 'production_line_id': production.production_line_id.id, 'type': '上产线', + 'route_id': up_route.id, + 'feeder_station_start_id': up_route.start_site_id.id, + 'feeder_station_destination_id': up_route.end_site_id.id}], + [0, '', + {'production_id': production.id, 'production_line_id': production.production_line_id.id, 'type': '下产线', + 'route_id': down_route.id, + 'feeder_station_start_id': down_route.start_site_id.id, + 'feeder_station_destination_id': down_route.end_site_id.id}]] # 拼接工单对象属性值(表面工艺) def _json_workorder_surface_process_str(self, production, route, process_parameter, supplier_id):