From 332dbce76911bf28f275025b672c422a90100d95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=83=A1=E5=B0=A7?= Date: Tue, 25 Feb 2025 17:25:04 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B7=A5=E5=8D=95=E8=BF=94=E5=B7=A5=E5=AE=8C?= =?UTF-8?q?=E6=88=90=E4=B8=8D=E8=A7=A6=E5=8F=91=E5=88=B6=E9=80=A0=E8=AE=A2?= =?UTF-8?q?=E5=8D=95=E7=9A=84=E5=AE=8C=E6=88=90=E4=BA=8B=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sf_manufacturing/models/mrp_workorder.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sf_manufacturing/models/mrp_workorder.py b/sf_manufacturing/models/mrp_workorder.py index 3c29ab79..907c207d 100644 --- a/sf_manufacturing/models/mrp_workorder.py +++ b/sf_manufacturing/models/mrp_workorder.py @@ -1384,7 +1384,8 @@ class ResMrpWorkOrder(models.Model): # ('state', '!=', 'done')]) # if raw_move: # raw_move.write({'state': 'done'}) - record.production_id.button_mark_done1() + if record.production_id.state != 'rework': + record.production_id.button_mark_done1() # record.production_id.state = 'done' # ============工单完成,修改对应[质检单]的值=====================