From d1baa8a7633fc7042861916192a5ccc14ae02fa7 Mon Sep 17 00:00:00 2001
From: Ben Lin <maobin001@msn.com>
Date: 星期五, 23 八月 2024 08:52:08 +0800
Subject: [PATCH] 一些更改

---
 Tiger.Business.MES/WorkAction/PrintLabel.cs |   13 +++++++++++--
 1 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/Tiger.Business.MES/WorkAction/PrintLabel.cs b/Tiger.Business.MES/WorkAction/PrintLabel.cs
index ff6a384..a3f2941 100644
--- a/Tiger.Business.MES/WorkAction/PrintLabel.cs
+++ b/Tiger.Business.MES/WorkAction/PrintLabel.cs
@@ -69,6 +69,7 @@
 
             //濡傛灉杩斿洖鎴愬姛鍒欒涓哄綋鍓嶈涓哄彲浠ュ紑濮嬫墽琛岋紝鍚﹀垯杩斿洖澶辫触
             action.IsSuccessed = true;
+            action.Data.ShortMsg = new("鎵撳嵃寮�濮�", ShortMessage.Types.Success);
             return action;
         }
 
@@ -87,6 +88,7 @@
             //鎻愪氦鏁版嵁鎵ц澶辫触
             else
             {
+                action.Data.ShortMsg = new("鎵撳嵃澶辫触", ShortMessage.Types.Failed);
                 action.IsSuccessed = false;
                 //action.LocaleMsg = new($"鏍囩{Label.LABEL_NAME}[{Label.LABEL_CODE}]鎵撳嵃澶辫触", Label.LABEL_NAME);
                 action.LocaleMsg = new("MES.WorkAction.PrintLabel.PrintFail", Label.LABEL_NAME, Label.LABEL_CODE);
@@ -115,6 +117,7 @@
                     AUTH_ORG = CurPosition.WorkBatch.WO.AUTH_ORG,
                     AUTH_PROD = CurPosition.CurLine.LINE_CODE,
                     HIS_ID = CurPosition.CurWipSNHiss.First(q => q.SN == wipSn.SN).ID,
+                    WIP_ID = wipSn.ID,
                     SN = wipSn.SN,
                     STATUS = wipSn.STATUS,
                     ITEM_CODE = wipSn.ITEM_CODE,
@@ -131,7 +134,11 @@
                     POST_CODE = wipSn.POST_CODE,
                     OPER_CODE = wipSn.OPER_CODE,
                     SEGMENT = wipSn.SEGMENT,
+                    FLOW_SN = wipSn.FLOW_SN,
                     TRAY_SN = wipSn.TRAY_SN,
+                    INNER_SN = wipSn.INNER_SN,
+                    CARTON_SN = wipSn.CARTON_SN,
+                    PALLET_SN = wipSn.PALLET_SN,
                     OPERATION_TIME = DateTime.Now,
                     SFTS_CODE = wipSn.SFTS_CODE,
                     SFT_CODE = wipSn.SFT_CODE,
@@ -145,16 +152,18 @@
                 };
                 wipActs.Add(wipAct);
             }
-            
 
+            //鍒涘缓鍙橀噺鍏嬮殕瀵硅薄鐢ㄤ簬浼犲叆DBSubmitAction涓繚瀛樺綋鍓嶉渶瑕佹殏瀛樼殑鏁版嵁鍊�
+            var _wipActs = wipActs.Clone();
             //淇濆瓨鏁版嵁
             CurStep.DBSubmitAction = () =>
             {
                 var db = CurPosition.GetCommitDB();
-                db.Storageable(wipActs, CurPosition.UserCode).ExecuteCommand();
+                db.Storageable(_wipActs, CurPosition.UserCode).ExecuteCommand();
             };
 
             IsFinished = true;
+            action.Data.ShortMsg = new("鎵撳嵃瀹屾垚", ShortMessage.Types.Success);
             //action.LocaleMsg = new($"鏍囩{Label.LABEL_NAME}[{Label.LABEL_CODE}]鎵撳嵃鎴愬姛", Label.LABEL_NAME);
             action.LocaleMsg = new("MES.WorkAction.PrintLabel.PrintSuccess", Label.LABEL_NAME, Label.LABEL_CODE);
             return action;

--
Gitblit v1.9.3