From 681d093f9ea16ab2d480d77e6b04b197e506ff60 Mon Sep 17 00:00:00 2001
From: dengjunjie <dengjunjie@hnkhzn.com>
Date: 星期四, 19 六月 2025 01:29:12 +0800
Subject: [PATCH] 1

---
 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_DTO/Basic/LocationArea.cs                                                 |   60 +++++
 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/CommonStackerCraneJob.cs                         |   10 
 代码管理/WMS/WIDESEA_WMSClient/src/views/basic/materielInfo.vue                                                  |    1 
 代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/12584657-ebd1-4698-830a-6e4c8ce29c77.vsidx |    0 
 代码管理/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b8abb72d-5a76-4a3b-bd9c-ecbcde909f62.vsidx |    0 
 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_DTO/Enum/TaskEnum.cs                                                   |    2 
 代码管理/WMS/WIDESEA_WMSClient/src/views/Home.vue                                                                |  369 +++++++++++++++++++++++++++++
 代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/bf268493-a788-4833-aa05-92fb21936af2.vsidx |    0 
 代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/0a5d4cfb-1461-4c61-96e9-484d536b0fb2.vsidx |    0 
 /dev/null                                                                                                    |    0 
 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/LocationInfoRowController.cs                  |  106 ++++++++
 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs                                         |  133 +++++-----
 代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/af454f43-a2e0-43b7-b5ea-099c1370dd5d.vsidx |    0 
 13 files changed, 605 insertions(+), 76 deletions(-)

diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/62b5ac34-861b-44ca-8306-87349bba393f.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/62b5ac34-861b-44ca-8306-87349bba393f.vsidx"
deleted file mode 100644
index e781914..0000000
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/62b5ac34-861b-44ca-8306-87349bba393f.vsidx"
+++ /dev/null
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b8abb72d-5a76-4a3b-bd9c-ecbcde909f62.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b8abb72d-5a76-4a3b-bd9c-ecbcde909f62.vsidx"
new file mode 100644
index 0000000..5b8084b
--- /dev/null
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b8abb72d-5a76-4a3b-bd9c-ecbcde909f62.vsidx"
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_DTO/Enum/TaskEnum.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_DTO/Enum/TaskEnum.cs"
index 340c9e2..6b41cc9 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_DTO/Enum/TaskEnum.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_DTO/Enum/TaskEnum.cs"
@@ -164,7 +164,7 @@
     public enum OutTaskStatusEnum
     {
         /// <summary>
-        /// 鏂板缓浠诲姟
+        /// 鏂板缓鍑哄簱浠诲姟
         /// </summary>
         [Description("鏂板缓")]
         OutNew = 100,
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs"
index cbee66c..2d4c02c 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs"
@@ -50,6 +50,7 @@
         private Dictionary<string, OrderByType> _taskOrderBy = new()
             {
                 {nameof(Dt_Task.Grade),OrderByType.Asc },
+                {nameof(Dt_Task.Roadway),OrderByType.Asc },
                 {nameof(Dt_Task.CreateDate),OrderByType.Asc},
             };
 
@@ -201,7 +202,7 @@
         /// <returns>杩斿洖浠诲姟瀹炰綋瀵硅薄锛屽彲鑳戒负null</returns>
         public Dt_Task? QueryStackerCraneTask(string deviceNo, string currentAddress = "")
         {
-            return BaseDal.QueryFirst(x => x.TaskStatus == (int)InTaskStatusEnum.InNew || x.TaskStatus == (int)OutTaskStatusEnum.OutNew || x.TaskStatus == (int)RelocationTaskStatusEnum.RelocationNew, TaskOrderBy);
+            return BaseDal.QueryFirst(x => x.Roadway.Contains(deviceNo) && (x.TaskStatus == (int)InTaskStatusEnum.InNew || x.TaskStatus == (int)OutTaskStatusEnum.OutNew || x.TaskStatus == (int)RelocationTaskStatusEnum.RelocationNew), TaskOrderBy);
         }
 
         /// <summary>
@@ -212,37 +213,40 @@
         /// <returns>杩斿洖浠诲姟瀹炰綋瀵硅薄锛屽彲鑳戒负null</returns>
         public Dt_Task QueryStackerCraneInTask(string deviceNo, string currentAddress = "")
         {
-            Dt_Task taskGrade = BaseDal.QueryFirst(x => true, TaskOrderBy);
-            if (taskGrade != null)
-            {
-                return taskGrade;
-            }
-            else
-            {
-                Dt_Task task = BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
-                Dt_Task tasks = BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
-                if (task != null && tasks == null)
-                {
-                    if (string.IsNullOrEmpty(currentAddress))
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
-                    else
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew && x.CurrentAddress == currentAddress, TaskOrderBy);
-                }
-                else if (task == null && tasks != null)
-                {
-                    if (string.IsNullOrEmpty(currentAddress))
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
-                    else
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew && x.CurrentAddress == currentAddress, TaskOrderBy);
-                }
-                else
-                {
-                    if (string.IsNullOrEmpty(currentAddress))
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
-                    else
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew && x.CurrentAddress == currentAddress, TaskOrderBy);
-                }
-            }
+            return BaseDal.QueryFirst(x => x.Roadway.Contains(deviceNo) && x.TaskStatus == (int)InTaskStatusEnum.InNew, TaskOrderBy);
+            #region MyRegion
+            //Dt_Task taskGrade = BaseDal.QueryFirst(x => true, TaskOrderBy);
+            //if (taskGrade != null)
+            //{
+            //    return taskGrade;
+            //}
+            //else
+            //{
+            //    Dt_Task task = BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
+            //    Dt_Task tasks = BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
+            //    if (task != null && tasks == null)
+            //    {
+            //        if (string.IsNullOrEmpty(currentAddress))
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
+            //        else
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew && x.CurrentAddress == currentAddress, TaskOrderBy);
+            //    }
+            //    else if (task == null && tasks != null)
+            //    {
+            //        if (string.IsNullOrEmpty(currentAddress))
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
+            //        else
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew && x.CurrentAddress == currentAddress, TaskOrderBy);
+            //    }
+            //    else
+            //    {
+            //        if (string.IsNullOrEmpty(currentAddress))
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
+            //        else
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew && x.CurrentAddress == currentAddress, TaskOrderBy);
+            //    }
+            //} 
+            #endregion
         }
         /// <summary>
         /// 鏍规嵁璁惧缂栧彿銆佸綋鍓嶅湴鍧�鎸夌収浼樺厛绾т互鍙婂垱寤烘椂闂存帓搴忔煡璇换鍔℃睜鍑哄簱绫诲瀷鐨勬柊澧炵殑浠诲姟
@@ -252,38 +256,41 @@
         /// <returns>杩斿洖浠诲姟瀹炰綋瀵硅薄锛屽彲鑳戒负null</returns>
         public Dt_Task QueryStackerCraneOutTask(string deviceNo, string currentAddress = "")
         {
-            Dt_Task taskGrade = BaseDal.QueryFirst(x => true, TaskOrderBy);
-            if (taskGrade != null)
-            {
-                return taskGrade;
-            }
-            else
-            {
-                Dt_Task task = BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
-                Dt_Task tasks = BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
-                if (task != null && tasks == null)
-                {
-                    if (string.IsNullOrEmpty(currentAddress))
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
-                    else
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew && x.CurrentAddress == currentAddress, TaskOrderBy);
-                }
-                else if (task == null && tasks != null)
-                {
-                    if (string.IsNullOrEmpty(currentAddress))
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
-                    else
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew && x.CurrentAddress == currentAddress, TaskOrderBy);
-                }
-                else
-                {
-                    if (string.IsNullOrEmpty(currentAddress))
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
-                    else
-                        return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew && x.CurrentAddress == currentAddress, TaskOrderBy);
-                }
+            return BaseDal.QueryFirst(x => x.Roadway.Contains(deviceNo) && x.TaskStatus == (int)OutTaskStatusEnum.OutNew, TaskOrderBy);
+            #region MyRegion
+            //Dt_Task taskGrade = BaseDal.QueryFirst(x => true, TaskOrderBy);
+            //if (taskGrade != null)
+            //{
+            //    return taskGrade;
+            //}
+            //else
+            //{
+            //    Dt_Task task = BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
+            //    Dt_Task tasks = BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
+            //    if (task != null && tasks == null)
+            //    {
+            //        if (string.IsNullOrEmpty(currentAddress))
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
+            //        else
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew && x.CurrentAddress == currentAddress, TaskOrderBy);
+            //    }
+            //    else if (task == null && tasks != null)
+            //    {
+            //        if (string.IsNullOrEmpty(currentAddress))
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew, TaskOrderBy);
+            //        else
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskInStatusEnum.InNew && x.CurrentAddress == currentAddress, TaskOrderBy);
+            //    }
+            //    else
+            //    {
+            //        if (string.IsNullOrEmpty(currentAddress))
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew, TaskOrderBy);
+            //        else
+            //            return BaseDal.QueryFirst(x => x.Roadway == deviceNo && TaskTypeEnums.Contains(x.TaskType) && x.TaskStatus == (int)TaskOutStatusEnum.OutNew && x.CurrentAddress == currentAddress, TaskOrderBy);
+            //    } 
 
-            }
+            //}
+            #endregion
         }
 
         /// <summary>
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/CommonStackerCraneJob.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/CommonStackerCraneJob.cs"
index 45bb9a3..b727fc4 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/CommonStackerCraneJob.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/CommonStackerCraneJob.cs"
@@ -56,7 +56,7 @@
                             //    //鍚慦MS鐢宠鍑哄叆搴撳彛鏄惁鏈夌┖鎵樼洏
                             //    sendFlag = false;
                             //}
-                            if(sendFlag)
+                            if (sendFlag)
                             {
                                 StackerCraneTaskCommand? stackerCraneTaskCommand = ConvertToStackerCraneTaskCommand(task);
                                 if (stackerCraneTaskCommand != null)
@@ -107,12 +107,18 @@
         private Dt_Task? GetTask(SpeStackerCrane speStackerCrane)
         {
             Dt_Task? task;
+            string DeviceCode = speStackerCrane.DeviceCode.Contains("CP") ? "CP" : "FL";
             if (speStackerCrane.LastTaskType == null)
             {
-                task = _taskService.QueryStackerCraneTask(speStackerCrane.DeviceCode);
+                task = _taskService.QueryStackerCraneTask(DeviceCode);
             }
             else
             {
+                if (speStackerCrane.LastTaskType == TaskTypeEnum.Relocation.ObjToInt())
+                {
+                    task = _taskService.QueryStackerCraneTask(DeviceCode);
+                    if (task != null) return task;
+                }
                 bool flag = speStackerCrane.LastTaskType == TaskTypeEnum.Inbound.ObjToInt() || speStackerCrane.LastTaskType == TaskTypeEnum.PalletInbound.ObjToInt();
                 if (flag == false)
                 {
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/views/Home.vue" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/views/Home.vue"
index 820437a..e94242b 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/views/Home.vue"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/views/Home.vue"
@@ -1,24 +1,373 @@
 <template>
-  <div class="title"></div>
+  <div class="container">
+    <div class="header">
+      <h2 class="title">璐т綅鎺掑浘</h2>
+    </div>
+
+    <div class="content-wrapper">
+      <!-- 鎺у埗闈㈡澘鍖哄煙 -->
+      <div class="control-panel">
+        <div class="form-group">
+          <label>鍖哄煙锛�</label>
+          <el-select
+            size="mini"
+            filterable
+            v-model="Area.shelf_code"
+            placeholder="璇烽�夋嫨"
+            class="full-width"
+          >
+            <el-option
+              v-for="item in slectData"
+              :value="item.shelf_code"
+              :label="item.house_name"
+              :key="item.house_name"
+            ></el-option>
+          </el-select>
+        </div>
+
+        <div class="form-group">
+          <label>鎺掞細</label>
+          <el-select
+            size="mini"
+            clearable
+            filterable
+            @change="SCChange"
+            v-model="Area.tunnel"
+            placeholder="璇烽�夋嫨"
+            class="full-width"
+          >
+            <el-option
+              v-for="item in scList"
+              :value="item"
+              :label="item"
+              :key="item"
+            ></el-option>
+          </el-select>
+        </div>
+
+        <el-button type="success" class="refresh-btn" @click="GetViewData">
+          鍒锋柊
+        </el-button>
+
+        <div class="legend-section">
+          <h4>璇存槑</h4>
+          <div class="legend-grid">
+            <div
+              class="legend-item"
+              v-for="item in infoMsg"
+              :key="item.bgcolor"
+            >
+              <span
+                class="color-box"
+                :style="{ 'background-color': item.bgcolor }"
+              ></span>
+              <span class="legend-label">{{ item.msg }}</span>
+            </div>
+          </div>
+        </div>
+      </div>
+
+      <!-- 璐т綅灞曠ず鍖哄煙 -->
+      <div class="location-view">
+        <div
+          class="layer-container"
+          v-for="layer in locationData"
+          :key="layer.index"
+        >
+          <h3 class="layer-title">绗瑊{ layer.index }}灞�</h3>
+          <div class="row" v-for="row in layer.rows" :key="row.index">
+            <div
+              class="location-cell"
+              :style="{ 'background-color': GetBgColor(col) }"
+              v-for="col in row.cols"
+              :key="col.index"
+              @mouseenter="showTooltip(col, $event)"
+              @mouseleave="hideTooltip"
+            >
+              {{ row.index }}-{{ col.index }}-{{ layer.index }}
+            </div>
+          </div>
+        </div>
+      </div>
+      <!-- 鎮诞鎻愮ず妗� -->
+      <div
+        v-if="showTooltipFlag"
+        class="location-tooltip"
+        :style="{
+          left: tooltipPosition.x + 'px',
+          top: tooltipPosition.y + 'px',
+        }"
+      >
+        <div v-if="currentLocation">
+          <p><strong>璐т綅鍙�:</strong>{{ currentLocation.locationCode }}</p>
+          <p>
+            <strong>璐т綅鎺掑垪灞�:</strong> {{ currentLocation.row }}鎺抺{
+              currentLocation.layer
+            }}鍒梴{ currentLocation.index }}灞�
+          </p>
+          <p><strong>鐘舵��:</strong> {{ getStatusText(currentLocation) }}</p>
+          <p>
+            <strong>绂佺敤:</strong>
+            {{ currentLocation.location_lock == 3 ? "鏄�" : "鍚�" }}
+          </p>
+        </div>
+      </div>
+    </div>
+  </div>
 </template>
 
 <script>
-import { ref, reactive } from 'vue'
+import { ElButton } from "element-plus";
 
 export default {
-  setup() {
+  data() {
     return {
+      slectData: [],
+      scList: [],
+      Area: { house_name: "", tunnel: "", shelf_code: "" },
+      mian_height: "",
+      infoMsg: [
+        { bgcolor: "orange", msg: "绌鸿揣浣�", state: 0 },
+        { bgcolor: "lightgreen", msg: "鏈夎揣", state: 2 },
+        { bgcolor: "#2BB3D5", msg: "閿佸畾", state: "InAssigned" },
+        { bgcolor: "#ccc", msg: "绂佺敤", state: 3 },
+        { bgcolor: "#b7ba6b", msg: "鍏跺畠", state: "else" },
+      ],
+      locationData: [],
+      showTooltipFlag: false,
+      currentLocation: null,
+      tooltipPosition: { x: 0, y: 0 },
+    };
+  },
+  computed: {
+    GetBgColor() {
+      return (col) => {
+        var bgColor = "#b7ba6b";
+        //浼樺厛鏄剧ず绂佺敤鐘舵��
+        if (col.location_lock == 3) {
+          this.infoMsg.forEach((el) => {
+            if (el.state == col.location_lock) {
+              bgColor = el.bgcolor;
+            }
+          });
+        } else {
+          this.infoMsg.forEach((el) => {
+            if (col.location_state == 1 || col.location_state == 98) {
+              if (el.state == "InAssigned") {
+                bgColor = el.bgcolor;
+              }
+            } else if (el.state == col.location_state) {
+              bgColor = el.bgcolor;
+            }
+          });
+        }
+        return bgColor;
+      };
+    },
+  },
+  watch: {
+    //鍒囨崲搴撳尯
+    "Area.shelf_code"(newValue, oldValue) {
+      this.scList = [];
+      this.slectData.forEach((e) => {
+        if (e.shelf_code == newValue) {
+          this.Area.tunnel = e.tunnel[0];
+          this.scList = e.tunnel;
+        }
+      });
+      this.GetViewData();
+    },
+  },
+  methods: {
+    GetViewData() {
+      var _this = this;
+      this.http
+        .post("/api/LocationInfoRow/GetLocationStatu", _this.Area, "鏌ヨ涓�")
+        .then((x) => {
+          _this.locationData = x;
+          console.log("鍚庣杩斿洖:", x);
+        });
+    },
+    // 鍒囨崲鎺�
+    SCChange() {
+      this.GetViewData();
+    },
+    showTooltip(location, event) {
+      this.currentLocation = location;
+      this.showTooltipFlag = true;
 
-    }
-  }
-}
+      // 璁剧疆鎻愮ず妗嗕綅缃紝绋嶅井鍋忕Щ閬垮厤閬尅榧犳爣
+      this.tooltipPosition = {
+        x: event.clientX + 10,
+        y: event.clientY + 10,
+      };
+    },
+
+    hideTooltip() {
+      this.showTooltipFlag = false;
+      this.currentLocation = null;
+    },
+
+    getStatusText(location) {
+      if (location.location_state === 0) return "绌鸿揣浣�";
+      if (location.location_state === 1) return "閿佸畾";
+      if (location.location_state === 2) return "鏈夎揣";
+      if (location.location_state === 98) return "绌烘墭閿佸畾";
+      if (location.location_state === 99) return "绌烘墭鐩�";
+      return "鍏朵粬";
+    },
+  },
+  mounted() {
+    var mainHeight = document.getElementById("vol-main");
+    this.mian_height = mainHeight.offsetHeight - 40 + "px";
+    var _this = this;
+    //鍔犺浇涓嬫媺閫夐」
+    this.http.get("/api/LocationInfoRow/GetArea", {}, "鏌ヨ涓�").then((x) => {
+      _this.slectData = x;
+      //鍔犺浇绗竴涓尯鍩燂紝绗竴鎺�
+      _this.Area.shelf_code = _this.slectData[0].shelf_code;
+      _this.scList = _this.slectData[0].tunnel;
+    });
+  },
+  components: { ElButton },
+};
 </script>
 
 <style scoped>
-.title {
-  line-height: 70vh;
+.container {
+  display: flex;
+  flex-direction: column;
+  height: 100%;
+  padding: 10px;
+}
+
+.header {
   text-align: center;
-  font-size: 28px;
-  color: orange;
+  margin-bottom: 20px;
+}
+
+.title {
+  font-size: 20px;
+  font-weight: bold;
+  margin: 0;
+}
+
+.content-wrapper {
+  display: flex;
+  flex: 1;
+  min-height: 0;
+}
+
+.control-panel {
+  width: 220px;
+  padding: 15px;
+  background-color: #f5f7fa;
+  border-radius: 4px;
+  margin-right: 15px;
+  display: flex;
+  flex-direction: column;
+}
+
+.form-group {
+  margin-bottom: 15px;
+}
+
+.full-width {
+  width: 100%;
+}
+
+.refresh-btn {
+  margin-top: 10px;
+  width: 100%;
+}
+
+.legend-section {
+  margin-top: 30px;
+}
+
+.legend-section h4 {
+  margin-bottom: 10px;
+}
+
+.legend-grid {
+  display: grid;
+  grid-template-columns: 1fr;
+  gap: 8px;
+}
+
+.legend-item {
+  display: flex;
+  align-items: center;
+}
+
+.color-box {
+  display: inline-block;
+  width: 20px;
+  height: 20px;
+  margin-right: 8px;
+  border-radius: 3px;
+}
+
+.legend-label {
+  font-size: 13px;
+}
+
+.location-view {
+  flex: 1;
+  overflow: auto;
+  padding: 10px;
+  background-color: white;
+  border-radius: 4px;
+}
+
+.layer-container {
+  margin-bottom: 25px;
+}
+
+.layer-title {
+  margin: 0 0 10px 0;
+  font-size: 16px;
+  color: #333;
+}
+
+.row {
+  display: flex;
+  flex-wrap: wrap;
+  margin-bottom: 8px;
+}
+
+.location-cell {
+  width: 66px;
+  height: 38px;
+  margin: 3px;
+  text-align: center;
+  font-size: 14px;
+  border-radius: 3px;
+  line-height: 38px;
+  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
+}
+
+.location-tooltip {
+  position: fixed;
+  z-index: 9999;
+  background-color: white;
+  border: 1px solid #ddd;
+  border-radius: 4px;
+  padding: 10px;
+  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
+  pointer-events: none;
+  max-width: 250px;
+}
+
+.location-tooltip p {
+  margin: 5px 0;
+  font-size: 13px;
+  line-height: 1.4;
+}
+
+.location-tooltip strong {
+  display: inline-block;
+  width: 70px;
+  color: #666;
 }
 </style>
\ No newline at end of file
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/views/basic/materielInfo.vue" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/views/basic/materielInfo.vue"
index 0e18099..fbc63ba 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/views/basic/materielInfo.vue"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/views/basic/materielInfo.vue"
@@ -33,6 +33,7 @@
       materielDes: "",
       isMixBatch: "",
       isMixMateriel: "",
+      unit:""
     });
     const editFormOptions = ref([
       [
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/060c68c1-8229-4582-8d09-21f436f63adf.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/060c68c1-8229-4582-8d09-21f436f63adf.vsidx"
deleted file mode 100644
index 3370229..0000000
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/060c68c1-8229-4582-8d09-21f436f63adf.vsidx"
+++ /dev/null
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/0a5d4cfb-1461-4c61-96e9-484d536b0fb2.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/0a5d4cfb-1461-4c61-96e9-484d536b0fb2.vsidx"
new file mode 100644
index 0000000..e90cee8
--- /dev/null
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/0a5d4cfb-1461-4c61-96e9-484d536b0fb2.vsidx"
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/0b22719c-a0d4-4fe6-9ae9-4eb7a870198d.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/0b22719c-a0d4-4fe6-9ae9-4eb7a870198d.vsidx"
deleted file mode 100644
index a819e62..0000000
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/0b22719c-a0d4-4fe6-9ae9-4eb7a870198d.vsidx"
+++ /dev/null
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/12584657-ebd1-4698-830a-6e4c8ce29c77.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/12584657-ebd1-4698-830a-6e4c8ce29c77.vsidx"
new file mode 100644
index 0000000..01ca95c
--- /dev/null
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/12584657-ebd1-4698-830a-6e4c8ce29c77.vsidx"
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/af454f43-a2e0-43b7-b5ea-099c1370dd5d.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/af454f43-a2e0-43b7-b5ea-099c1370dd5d.vsidx"
new file mode 100644
index 0000000..f4d1b97
--- /dev/null
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/af454f43-a2e0-43b7-b5ea-099c1370dd5d.vsidx"
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/bb78fc9b-06de-44ce-9686-fc2d98a53e1b.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/bb78fc9b-06de-44ce-9686-fc2d98a53e1b.vsidx"
deleted file mode 100644
index 7544cad..0000000
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/bb78fc9b-06de-44ce-9686-fc2d98a53e1b.vsidx"
+++ /dev/null
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/bf268493-a788-4833-aa05-92fb21936af2.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/bf268493-a788-4833-aa05-92fb21936af2.vsidx"
new file mode 100644
index 0000000..bed1b2b
--- /dev/null
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/bf268493-a788-4833-aa05-92fb21936af2.vsidx"
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/dd95cbb2-97f5-4145-b96e-1575d7826b96.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/dd95cbb2-97f5-4145-b96e-1575d7826b96.vsidx"
deleted file mode 100644
index 9443bd7..0000000
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/dd95cbb2-97f5-4145-b96e-1575d7826b96.vsidx"
+++ /dev/null
Binary files differ
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_DTO/Basic/LocationArea.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_DTO/Basic/LocationArea.cs"
new file mode 100644
index 0000000..ee5e1a0
--- /dev/null
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_DTO/Basic/LocationArea.cs"
@@ -0,0 +1,60 @@
+锘縰sing System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace WIDESEA_DTO.Basic
+{
+    public class LocationArea
+    {
+        /// <summary>
+        /// 搴撳尯鍚嶇О
+        /// </summary>
+        public string house_name { get; set; }
+
+        /// <summary>
+        /// 搴撳尯缂栧彿
+        /// </summary>
+        public int shelf_code { get; set; }
+
+        /// <summary>
+        /// 
+        /// </summary>
+        public int tunnel { get; set; }
+    }
+
+
+    public class LocationLayer
+    {
+        public int index { get; set; }
+        public List<LocationRow> rows { get; set; }
+    }
+    public class LocationRow
+    {
+        public int index { get; set; }
+        public List<LocationCol> cols { get; set; }
+    }
+
+    public class LocationCol
+    {
+        public string locationCode { get; set; }
+        public int row { get; set; }
+        public int layer { get; set; }
+
+        public int index { get; set; }
+        /// <summary>
+        /// 妫�娴嬫煖鐘舵��
+        /// </summary>
+        public string remark { get; set; }
+        /// <summary>
+        /// 璐т綅鐘舵��
+        /// </summary>
+        public int location_state { get; set; }
+        /// <summary>
+        /// 閿佸畾鐘舵��
+        /// </summary>
+        public int location_lock { get; set; }
+    }
+
+}
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/LocationInfoRowController.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/LocationInfoRowController.cs"
new file mode 100644
index 0000000..2ac72a3
--- /dev/null
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/LocationInfoRowController.cs"
@@ -0,0 +1,106 @@
+锘縰sing Microsoft.AspNetCore.Authorization;
+using Microsoft.AspNetCore.Http;
+using Microsoft.AspNetCore.Mvc;
+using System.Collections.Generic;
+using WIDESEA_Core;
+using WIDESEA_Core.BaseController;
+using WIDESEA_Core.Enums;
+using WIDESEA_DTO.Basic;
+using WIDESEA_IBasicRepository;
+using WIDESEA_IBasicService;
+using WIDESEA_ISystemRepository;
+using WIDESEA_Model.Models;
+
+namespace WIDESEA_WMSServer.Controllers.Basic
+{
+    /// <summary>
+    /// 璐т綅
+    /// </summary>
+    [Route("api/LocationInfoRow")]
+    [ApiController]
+    public class LocationInfoRowController : ApiBaseController<ILocationInfoService, Dt_LocationInfo>
+    {
+        private readonly ILocationInfoRepository _repository;
+        private readonly IAreaInfoRepository _areaInfoRepository;
+        private readonly ILocationInfoRepository _locationInfoRepository;
+        public LocationInfoRowController(ILocationInfoService service, ILocationInfoRepository repository, IAreaInfoRepository areaInfoRepository, ILocationInfoRepository locationInfoRepository) : base(service)
+        {
+            _repository = repository;
+            _areaInfoRepository = areaInfoRepository;
+            _locationInfoRepository = locationInfoRepository;
+        }
+        /// <summary>
+        /// 鑾峰彇搴撳尯鏉冮檺
+        /// </summary>
+        /// <returns></returns>
+        [HttpGet, HttpPost, Route("GetArea"), AllowAnonymous]
+        public object GetArea()
+        {
+            List<object> list = new List<object>();
+            List<Dt_LocationInfo>? locations = _locationInfoRepository.QueryData();
+            List<Dt_AreaInfo> areaInfos = _areaInfoRepository.QueryData(x => locations.Select(x => x.AreaId).ToList().Contains(x.Id));
+            foreach (var areaInfo in areaInfos)
+            {
+                var Rows = locations.Where(x => x.AreaId == areaInfo.Id).GroupBy(x => x.Row).Select(x => x.Key).OrderBy(x => x).ToList();
+                var obj = new
+                {
+                    house_name = areaInfo.AreaName,
+                    shelf_code = areaInfo.Id,
+                    tunnel = Rows
+                };
+                list.Add(obj);
+            }
+            return list;
+        }
+        /// <summary>
+        /// 鑾峰彇璐т綅淇℃伅
+        /// </summary>
+        /// <param name="area"></param>
+        /// <returns></returns>
+        [HttpPost, Route("GetLocationStatu"), AllowAnonymous]
+        public object GetLocationStatu([FromBody] LocationArea area)
+        {
+            List<LocationLayer> layers = new List<LocationLayer>();
+            var data = _locationInfoRepository.QueryData(x => x.AreaId == area.shelf_code && x.Row == area.tunnel);
+            foreach (var layer in data.GroupBy(t => t.Layer))
+            {
+                var rows = new List<LocationRow>();
+                var data_rows = layer.GroupBy(t => t.Row);
+                foreach (var data_row in data_rows)
+                {
+                    var cols = new List<LocationCol>();
+                    foreach (var data_col in data_row)
+                    {
+                        cols.Add(new LocationCol()
+                        {
+                            //鍒�
+                            row = data_col.Row,
+                            layer = data_col.Layer,
+                            index = data_col.Column,
+                            locationCode = data_col.LocationCode,
+                            location_state = data_col.LocationStatus,
+                            location_lock = data_col.EnableStatus,
+                            remark = data_col.Remark
+                        });
+                    }
+                    cols = cols.OrderBy(t => t.index).ToList();
+                    rows.Add(new LocationRow()
+                    {
+                        //琛�
+                        index = data_row.Key,
+                        cols = cols
+                    });
+                }
+                rows = rows.OrderBy(t => t.index).ToList();
+                layers.Add(new LocationLayer()
+                {
+                    //灞�
+                    index = layer.Key,
+                    rows = rows
+                });
+            }
+            layers = layers.OrderBy(t => t.index).ToList();
+            return layers;
+        }
+    }
+}

--
Gitblit v1.9.3