From 9f30a029c5f151c19c673eb8b29c2820c8260f8d Mon Sep 17 00:00:00 2001 From: "jinling.yang" Date: Mon, 30 Oct 2023 09:36:52 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9C=BA=E5=BA=8Aid=E6=94=B9=E4=B8=BA=E8=AE=BE?= =?UTF-8?q?=E5=A4=87id?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sf_manufacturing/models/mrp_workorder.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sf_manufacturing/models/mrp_workorder.py b/sf_manufacturing/models/mrp_workorder.py index 86fc9dd5..b4fa41c8 100644 --- a/sf_manufacturing/models/mrp_workorder.py +++ b/sf_manufacturing/models/mrp_workorder.py @@ -401,7 +401,7 @@ class ResMrpWorkOrder(models.Model): [('routing_type', '=', 'CNC加工'), ('production_id', '=', self.production_id.id)], limit=1) res = {'model_code': '' if not cnc.product_id.model_code else cnc.product_id.model_code, 'production_no': self.production_id.name, - 'machine_tool_code': cnc.workcenter_id.machine_tool_id.code, + 'machine_tool_code': cnc.workcenter_id.equipment_id.code, 'material_code': cnc.env['sf.production.materials'].search( [('id', '=', cnc.product_id.materials_id.id)]).materials_no, 'material_type_code': cnc.env['sf.materials.model'].search(