From dc4c76b2b5e57d28e3c4bfff9ec86e11efe22d20 Mon Sep 17 00:00:00 2001 From: Rodney Chen <rodney.chen@hotmail.com> Date: 星期一, 23 九月 2024 19:49:23 +0800 Subject: [PATCH] 优化工序逻辑 --- Tiger.Business.MES/Transaction/PackingNode.cs | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Tiger.Business.MES/Transaction/PackingNode.cs b/Tiger.Business.MES/Transaction/PackingNode.cs index ef98c60..dbca424 100644 --- a/Tiger.Business.MES/Transaction/PackingNode.cs +++ b/Tiger.Business.MES/Transaction/PackingNode.cs @@ -89,8 +89,9 @@ else { var wosns = Biz.Db.Queryable<BIZ_MES_WO_BATCH, BIZ_MES_WO_SN>((q, s) => new JoinQueryInfos(JoinType.Inner, q.ORDER_NO == s.WORK_ORDER)) - .ByAuth(input.AuthOption).Where((q, s) => s.SN == input.SN || s.FLOW_SN == input.SN || s.TRAY_SN == input.SN).Select((q, s) => new { Batch = q, SN = s }).ToList(); - + .ByAuth(input.AuthOption).Where((q, s) => s.STATUS < BIZ_MES_WO_SN.STATUSs.Finished.GetValue()) + .Where((q, s) => s.SN == input.SN || s.FLOW_SN == input.SN || s.TRAY_SN == input.SN).Select((q, s) => new { Batch = q, SN = s }).ToList(); + //鏌ユ壘鍒版潯鐮佸凡缁戝畾鐨勫伐鍗� if (!wosns.IsNullOrEmpty()) { @@ -615,9 +616,9 @@ { action.IsSuccessed = false; //action.LocaleMsg = new($"鍑鸿揣鏁伴噺璁惧畾涓篬{0}]锛岀洰鍓嶅寘瑁呬簡[{1}]锛屽寘瑁呭熬鏁扮殑鏁伴噺蹇呴渶鏄痆{2}]锛岃瑁呭鏁伴噺鍚庡啀缁撴潫鍖呰"); - action.LocaleMsg = new("MES.Transaction.PackingNode.NotMatchShipQty", shipQty, curQty, shipQty % ruleQty); + action.LocaleMsg = new("MES.Transaction.PackingNode.NotMatchShipQty", shipQty, curQty, shipQty % ruleQty); + return action; } - action = TempPkgAction.Submit(null); } else -- Gitblit v1.9.3