From 3443d00c1c23f84d8559e802a27eb9ba7ff0858a Mon Sep 17 00:00:00 2001
From: wangxinhui <wangxinhui@hnkhzn.com>
Date: 星期二, 10 六月 2025 16:32:34 +0800
Subject: [PATCH] 1

---
 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/InvokeAGVService.cs |   83 +++++++++++++++++++++++++++++++++++++++++
 1 files changed, 82 insertions(+), 1 deletions(-)

diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/InvokeAGVService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/InvokeAGVService.cs"
index 153dccf..a8e082b 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/InvokeAGVService.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/InvokeAGVService.cs"
@@ -83,6 +83,87 @@
             return content;
         }
         /// <summary>
+        /// CTU鍙栨秷浠诲姟
+        /// </summary>
+        public WebResponseContent AgvBoxApplyPass(AgvCTUCancelDTO applyPassDTO, APIEnum SecureReply = APIEnum.AGV_CTUCancelTask)
+        {
+            WebResponseContent content = new WebResponseContent();
+            try
+            {
+                string? apiAddress = apiInfos.FirstOrDefault(x => x.ApiCode == SecureReply.ToString())?.ApiAddress;
+                if (string.IsNullOrEmpty(apiAddress))
+                    return WebResponseContent.Instance.Error($"鏈壘鍒癆GV鍙栨秷浠诲姟鎺ュ彛,璇锋鏌ユ帴鍙i厤缃�");
+                string response = HttpHelper.Post(apiAddress, applyPassDTO.Serialize());
+                AgvResponseContent agvContent = response.DeserializeObject<AgvResponseContent>();
+                if (agvContent.Code == "0")
+                {
+                    content.OK(agvContent.Message);
+                }
+                else
+                {
+                    content.Error(agvContent.Message);
+                }
+            }
+            catch (Exception ex)
+            {
+                content.Error(ex.Message);
+            }
+            return content;
+        }
+        /// <summary>
+        /// AGV鎴愬搧鍙栨斁璐ч�氱煡
+        /// </summary>
+        public WebResponseContent AgvBoxApplyPass(AGVBoxApplyPassDTO applyPassDTO, APIEnum SecureReply = APIEnum.AGV_CPBoxApplyPass)
+        {
+            WebResponseContent content = new WebResponseContent();
+            try
+            {
+                string? apiAddress = apiInfos.FirstOrDefault(x => x.ApiCode == SecureReply.ToString())?.ApiAddress;
+                if (string.IsNullOrEmpty(apiAddress))
+                    return WebResponseContent.Instance.Error($"鏈壘鍒板彂閫丄GV浠诲姟鎺ュ彛,璇锋鏌ユ帴鍙i厤缃�");
+                string response = HttpHelper.Post(apiAddress, applyPassDTO.Serialize());
+                AgvResponseContent agvContent = response.DeserializeObject<AgvResponseContent>();
+                if (agvContent.Code == "0")
+                {
+                    content.OK(agvContent.Message);
+                }
+                else
+                {
+                    content.Error(agvContent.Message);
+                }
+            }
+            catch (Exception ex)
+            {
+                content.Error(ex.Message);
+            }
+            return content;
+        }
+        public WebResponseContent AgvPreScheduleTask(AgvScheduleTaskDTO scheduleTaskDTO, APIEnum ScheduleTask = APIEnum.AGV_CTUScheduleTaskTask)
+        {
+            WebResponseContent content = new WebResponseContent();
+            try
+            {
+                string? apiAddress = apiInfos.FirstOrDefault(x => x.ApiCode == ScheduleTask.ToString())?.ApiAddress;
+                if (string.IsNullOrEmpty(apiAddress))
+                    return WebResponseContent.Instance.Error($"鏈壘鍒板彂閫丄GV浠诲姟鎺ュ彛,璇锋鏌ユ帴鍙i厤缃�");
+                string response = HttpHelper.Post(apiAddress, scheduleTaskDTO.Serialize());
+                AgvResponseContent agvContent = response.DeserializeObject<AgvResponseContent>();
+                if (agvContent.Code == "0")
+                {
+                    content.OK(agvContent.Message);
+                }
+                else
+                {
+                    content.Error(agvContent.Message);
+                }
+            }
+            catch (Exception ex)
+            {
+                content.Error(ex.Message);
+            }
+            return content;
+        }
+        /// <summary>
         /// AGV浠诲姟鐘舵�佸埛鏂�/AGV浠诲姟瀹屾垚
         /// </summary>
         /// <param name="agvUpdateModel"></param>
@@ -101,7 +182,7 @@
                     return WebResponseContent.Instance.Error($"鏈壘鍒板彂閫丄GV浠诲姟鎺ュ彛,璇锋鏌ユ帴鍙i厤缃�");
                 string response = HttpHelper.Post(apiAddress, agvPodModel.Serialize());
                 AgvResponseContent agvContent = response.DeserializeObject<AgvResponseContent>();
-                if (agvContent.Code == "0")
+                if (agvContent.Code == "1")
                 {
                     content.OK(agvContent.Message);
                 }

--
Gitblit v1.9.3