From 3167d838a6446283a8978cece82ea60071b65ca0 Mon Sep 17 00:00:00 2001
From: Admin <Admin@ADMIN>
Date: 星期四, 15 一月 2026 08:53:30 +0800
Subject: [PATCH] 最新

---
 项目代码/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/MESTaskService.cs |  128 ++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 128 insertions(+), 0 deletions(-)

diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/MESTaskService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/MESTaskService.cs"
index 966532b..fe525d2 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/MESTaskService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/MESTaskService.cs"
@@ -261,5 +261,133 @@
                 return apiResponse.Error($"WMS浠诲姟鍙栨秷鎺ュ彛閿欒锛屽師鍥狅細{ex.Message}");
             }
         }
+
+        //鍏ュ簱浠诲姟鍙嶉鎺ュ彛
+        public MES_parameter InStoreDocCallback(string TransNo, string Result, string ResultMsg, string ContainerNo, string LocationCode)
+        {
+            MES_parameter mES_Parame= new MES_parameter();
+            try
+            {
+                MesInResultResponse mesInResult = new MesInResultResponse();
+                mesInResult.TransNo = TransNo;
+                mesInResult.Result = Result;
+                mesInResult.ResultMsg = ResultMsg;
+                mesInResult.ContainerNo = ContainerNo;
+                mesInResult.LocationCode = LocationCode;
+                mES_Parame = HttpHelper.Post<MES_parameter>(MES_InReporttask, mesInResult, "鍏ュ簱浠诲姟姹囨姤");
+                return mES_Parame;
+            }
+            catch (Exception ex)
+            {
+                mES_Parame.Result = "N";
+                mES_Parame.ResultMsg= $"鍏ュ簱锛歐MS绯荤粺涓婁紶澶辫触,鍘熷洜锛歿ex.Message}";
+                return mES_Parame;
+            }
+
+        }
+        //鍑哄簱浠诲姟鍙嶉鎺ュ彛
+        public MES_parameter OutStoreDocCallback(string TransNo,string Result,string ResultMsg,string ContainerNo,string LocationCode)
+        {
+            MES_parameter mES_Parame = new MES_parameter();
+            try
+            {
+                MesInResultResponse mesInResult = new MesInResultResponse();
+                mesInResult.TransNo = TransNo;
+                mesInResult.Result = Result;
+                mesInResult.ResultMsg = ResultMsg;
+                mesInResult.ContainerNo = ContainerNo;
+                mesInResult.LocationCode = LocationCode;
+                mES_Parame = HttpHelper.Post<MES_parameter>(MES_OutReporttask, mesInResult, "鍑哄簱浠诲姟姹囨姤");
+                return mES_Parame;
+            }
+            catch (Exception ex)
+            {
+                mES_Parame.Result = "N";
+                mES_Parame.ResultMsg = $"鍑哄簱锛歐MS绯荤粺涓婁紶澶辫触,鍘熷洜锛歿ex.Message}";
+                return mES_Parame;
+            }
+        }
+
+        /// <summary>
+        /// 鍌ㄤ綅寮傚姩鐢宠
+        /// </summary>
+        /// <param name="ContainerNo">鎵樼洏鏉$爜</param>
+        /// <param name="OriginalLocationCode">鍘熷偍浣�</param>
+        /// <param name="NewLocationCode">鏂板偍浣�</param>
+        /// <returns></returns>
+        public MES_parameter ApplicationChangeStorageLocation(string ContainerNo,string OriginalLocationCode,string NewLocationCode)
+        {
+            MES_parameter mES_Parame = new MES_parameter();
+            try
+            {
+                MES_Storagelocation Storagelocation = new MES_Storagelocation();
+                Storagelocation.ContainerNo = ContainerNo;
+                Storagelocation.OriginalLocationCode = OriginalLocationCode;
+                Storagelocation.NewLocationCode = NewLocationCode;
+                mES_Parame = HttpHelper.Post<MES_parameter>(MES_InventoryUpdateApply, Storagelocation, "鍌ㄤ綅寮傚姩鐢宠");
+                return mES_Parame;
+            }
+            catch (Exception ex)
+            {
+                mES_Parame.Result = "N";
+                mES_Parame.ResultMsg = $"鍌ㄤ綅寮傚姩鐢宠锛歐MS绯荤粺璋冨彇澶辫触,鍘熷洜锛歿ex.Message}";
+                return mES_Parame;
+            }
+        }
+
+        /// <summary>
+        /// 鍌ㄤ綅寮傚姩
+        /// </summary>
+        /// <param name="ContainerNo">鎵樼洏鏉$爜</param>
+        /// <param name="OriginalLocationCode">鍘熷偍浣�</param>
+        /// <param name="NewLocationCode">鏂板偍浣�</param>
+        /// <returns></returns>
+        public MES_parameter AbnormalStorageLocation(string ContainerNo, string OriginalLocationCode, string NewLocationCode)
+        {
+            MES_parameter mES_Parame = new MES_parameter();
+            try
+            {
+                MES_Storagelocation Storagelocation = new MES_Storagelocation();
+                Storagelocation.ContainerNo = ContainerNo;
+                Storagelocation.OriginalLocationCode = OriginalLocationCode;
+                Storagelocation.NewLocationCode = NewLocationCode;
+                mES_Parame = HttpHelper.Post<MES_parameter>(MES_InventoryUpdateCallback, Storagelocation, "鍌ㄤ綅寮傚姩");
+                return mES_Parame;
+            }
+            catch (Exception ex)
+            {
+                mES_Parame.Result = "N";
+                mES_Parame.ResultMsg = $"鍌ㄤ綅寮傚姩锛歐MS绯荤粺璋冨彇澶辫触,鍘熷洜锛歿ex.Message}";
+                return mES_Parame;
+            }
+        }
+        /// <summary>
+        /// 浠诲姟寮傚父
+        /// </summary>
+        /// <param name="TransNo">鍗曟嵁缂栧彿</param>
+        /// <param name="EquipmentType">璁惧绫诲瀷</param>
+        /// <param name="EquipmentNumber">璁惧缂栫爜</param>
+        /// <param name="ErrorInfo">寮傚父鎶ユ枃</param>MES_TaskErrorInfoCallback
+        /// <returns></returns>
+        public MES_parameter ToMES_TaskException(string TransNo,string EquipmentType,string EquipmentNumber,string ErrorInfo)
+        {
+            MES_parameter mES_Parame = new MES_parameter();
+            try
+            {
+                MES_TaskException Storagelocation = new MES_TaskException();
+                Storagelocation.TransNo = TransNo;
+                Storagelocation.EquipmentType = EquipmentType;
+                Storagelocation.EquipmentNumber = EquipmentNumber;
+                Storagelocation.ErrorInfo = ErrorInfo;
+                mES_Parame = HttpHelper.Post<MES_parameter>(MES_TaskErrorInfoCallback, Storagelocation, "浠诲姟寮傚父");
+                return mES_Parame;
+            }
+            catch (Exception ex)
+            {
+                mES_Parame.Result = "N";
+                mES_Parame.ResultMsg = $"浠诲姟寮傚父锛歐MS绯荤粺璋冨彇澶辫触,鍘熷洜锛歿ex.Message}";
+                return mES_Parame;
+            }
+        }
     }
 }

--
Gitblit v1.9.3