From b0327633d7d0c19693a4e577d1e17b3b22e8274e Mon Sep 17 00:00:00 2001
From: wanshenmean <cathay_xy@163.com>
Date: 星期日, 12 四月 2026 01:23:56 +0800
Subject: [PATCH] refactor(WCS&WMS): 新增手动下发输送线任务

---
 Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs |   35 +++++++++++++++++++++++++++++++++++
 1 files changed, 35 insertions(+), 0 deletions(-)

diff --git a/Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs b/Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs
index 02204d3..ac3cb72 100644
--- a/Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs
+++ b/Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs
@@ -644,6 +644,41 @@
         {
             return BaseDal.QueryFirst(x => x.TaskNum == taskNum);
         }
+
+        /// <summary>
+        /// 鎺ユ敹WMS鎵嬪姩鍒涘缓鐨勪换鍔★紝鍒涘缓WCS浠诲姟
+        /// </summary>
+        /// <param name="taskDTOs">WMS浠诲姟瀵硅薄闆嗗悎</param>
+        /// <returns>杩斿洖澶勭悊缁撴灉</returns>
+        public WebResponseContent ReceiveManualTask([NotNull] List<WMSTaskDTO> taskDTOs)
+        {
+            WebResponseContent content = new WebResponseContent();
+            try
+            {
+                // 璋冪敤 ReceiveWMSTask 鍒涘缓 WCS 浠诲姟
+                content = ReceiveWMSTask(taskDTOs);
+                return content;
+            }
+            catch (Exception ex)
+            {
+                content = WebResponseContent.Instance.Error($"鎵嬪姩浠诲姟鎺ユ敹閿欒,閿欒淇℃伅:{ex.Message}");
+                return content;
+            }
+        }
+
+        /// <summary>
+        /// 鏌ヨ鎸囧畾璧风偣鍦板潃鐨勬柊寤烘墜鍔ㄥ叆搴撲换鍔�
+        /// </summary>
+        /// <param name="sourceAddress">璧风偣鍦板潃</param>
+        /// <returns>浠诲姟瀹炰綋</returns>
+        public Dt_Task QueryManualInboundTask(string sourceAddress)
+        {
+            return BaseDal.QueryFirst(x =>
+                x.TaskType == (int)TaskInboundTypeEnum.Inbound &&
+                x.TaskStatus == (int)TaskInStatusEnum.InNew &&
+                x.SourceAddress == sourceAddress &&
+                x.Creater == "WMS");
+        }
     }
 
     public enum ConveyorLineDBNameNew

--
Gitblit v1.9.3