From 595b44f79c7580b3d95c63194b1df4f00600f926 Mon Sep 17 00:00:00 2001
From: xiazhengtongxue <133085197+xiazhengtongxue@users.noreply.github.com>
Date: 星期六, 18 四月 2026 15:08:14 +0800
Subject: [PATCH] Revert "fix(WMS): 修复货位状态变动记录"

---
 Code/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Record/LocationStatusChangeRecordController.cs |   25 ++++++++++++++++++++++++-
 1 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/Code/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Record/LocationStatusChangeRecordController.cs b/Code/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Record/LocationStatusChangeRecordController.cs
index 8df163d..88febce 100644
--- a/Code/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Record/LocationStatusChangeRecordController.cs
+++ b/Code/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Record/LocationStatusChangeRecordController.cs
@@ -17,7 +17,30 @@
     {
         public LocationStatusChangeRecordController(ILocationStatusChangeRecordService service) : base(service)
         {
+        }
+        /// <summary>
+        /// 鏍规嵁ID鑾峰彇璐т綅鐘舵�佸彉鍔ㄨ褰�
+        /// </summary>
+        /// <param name="id">璐т綅鐘舵�佸彉鍔ㄨ褰旾D</param>
+        /// <returns>璐т綅鐘舵�佸彉鍔ㄨ褰曚俊鎭�</returns>
+        [HttpPost("GetLocationState"), AllowAnonymous]
+        public WebResponseContent GetLocationState(int id)
+        {
+            try
+            {
+                if (id <= 0)
+                    return WebResponseContent.Instance.Error("ID鍙傛暟鏃犳晥");
+
+                var records = Service.Repository.QueryData(x => x.LocationId == id);
+                if (records == null || records.Count == 0)
+                    return WebResponseContent.Instance.Error("鏈壘鍒板搴旂殑璐т綅鐘舵�佸彉鍔ㄨ褰�");
+
+                return WebResponseContent.Instance.OK(null, records);
+            }
+            catch (Exception ex)
+            {
+                return WebResponseContent.Instance.Error($"鑾峰彇璐т綅鐘舵�佸彉鍔ㄨ褰曞け璐�: {ex.Message}");
+            }
         }
-       
     }
 }

--
Gitblit v1.9.3