From 9e369f0150d3f6137e172d6d570fd7c01614c436 Mon Sep 17 00:00:00 2001 From: yuxianghui <3437689193@qq.com> Date: Thu, 17 Oct 2024 15:51:00 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=B0=83=E7=94=A8=E5=88=9B?= =?UTF-8?q?=E5=BB=BAcam=E7=A8=8B=E5=BA=8F=E7=94=A8=E5=88=80=E8=AE=A1?= =?UTF-8?q?=E5=88=92=E6=96=B9=E6=B3=95=E7=9A=84=E5=88=A4=E6=96=AD=E6=9D=A1?= =?UTF-8?q?=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sf_tool_management/models/mrp_workorder.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sf_tool_management/models/mrp_workorder.py b/sf_tool_management/models/mrp_workorder.py index 38d952f5..d346937a 100644 --- a/sf_tool_management/models/mrp_workorder.py +++ b/sf_tool_management/models/mrp_workorder.py @@ -209,7 +209,7 @@ class MrpProduction(models.Model): logging.info(f'库存缺刀:{missing_tool_2}') # 调用CAM工单程序用刀计划创建方法 cnc_ids = self.env['sf.cnc.processing'].sudo().search( - [('workorder_id', 'in', workorder_ids.filtered(lambda a: a.production_id == self[0].id).ids), + [('workorder_id', 'in', workorder_ids.filtered(lambda a: a.production_id == self[0]).ids), ('cutting_tool_name', 'in', missing_tool_2)]) if cnc_ids: logging.info('调用CAM工单程序用刀计划创建方法!!!')