From 0d8c62c3d7f2a57ec8b9ff34c4f7e1a9221e9004 Mon Sep 17 00:00:00 2001 From: Rodney Chen <rodney.chen@hotmail.com> Date: 星期四, 02 一月 2025 10:27:43 +0800 Subject: [PATCH] Merge branch 'master' of http://47.115.28.255:8110/r/TigerClouds-Tech/Server/TigerApi6_2024 --- Tiger.Business.MES/Common/WorkBatch.cs | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Tiger.Business.MES/Common/WorkBatch.cs b/Tiger.Business.MES/Common/WorkBatch.cs index 30c2ec7..0d1811e 100644 --- a/Tiger.Business.MES/Common/WorkBatch.cs +++ b/Tiger.Business.MES/Common/WorkBatch.cs @@ -259,7 +259,7 @@ //鍒ゆ柇褰撳墠宸ュ崟鎵规鏄惁宸插畬宸� if (!woSNs.Any(q => q.BATCH_NO == Batch.BATCH_NO && q.STATUS < BIZ_MES_WO_SN.STATUSs.Finished.GetValue()) && - woSNs.Count(q => q.BATCH_NO == Batch.BATCH_NO && q.STATUS == BIZ_MES_WO_SN.STATUSs.Finished.GetValue()) == Batch.PLAN_QTY) + woSNs.Where(q => q.BATCH_NO == Batch.BATCH_NO && q.STATUS == BIZ_MES_WO_SN.STATUSs.Finished.GetValue()).Sum(q=>q.QTY) == Batch.PLAN_QTY) { Batch.STATUS = BIZ_MES_WO_BATCH.STATUSs.Closed.GetValue(); Batch.ACT_END_TIME = DateTime.Now; @@ -267,7 +267,7 @@ //鍒ゆ柇褰撳墠宸ュ崟鏄惁宸插畬宸� if (!woSNs.Any(q => q.STATUS < BIZ_MES_WO_SN.STATUSs.Finished.GetValue()) && - woSNs.Count(q => q.STATUS == BIZ_MES_WO_SN.STATUSs.Finished.GetValue()) == WO.PLAN_QTY) + woSNs.Where(q => q.STATUS == BIZ_MES_WO_SN.STATUSs.Finished.GetValue()).Sum(q => q.QTY) == WO.PLAN_QTY) { WO.STATUS = BIZ_MES_WO.STATUSs.Closed.GetValue(); WO.ACT_END_TIME = DateTime.Now; -- Gitblit v1.9.3