From 5bf2b51ec743cd422a0eb3277b9c93a08c700315 Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期一, 10 二月 2025 08:46:30 +0800
Subject: [PATCH] #

---
 src/main/webapp/views/console4.html |   27 +++++++++++++++++++++++++--
 1 files changed, 25 insertions(+), 2 deletions(-)

diff --git a/src/main/webapp/views/console4.html b/src/main/webapp/views/console4.html
index cb3dc96..d974358 100644
--- a/src/main/webapp/views/console4.html
+++ b/src/main/webapp/views/console4.html
@@ -150,7 +150,7 @@
     data: {
       map: [],
       currentLev: 1,
-      floorList: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10], //褰撳墠椤圭洰妤煎眰
+      floorList: [1, 2, 3], //褰撳墠椤圭洰妤煎眰
       currentLevShuttleList: [],//褰撳墠妤煎眰鍥涘悜绌挎杞﹂泦鍚�
       shuttleColorList: [],//鍥涘悜绌挎杞﹂鑹查泦鍚�
       drawer: false,
@@ -184,7 +184,7 @@
         deep: true,
         handler(val) {
           if (!val) {
-            var sprite = pixiStageList[this.drawerLocNoData.x][this.drawerLocNoData.y];
+            var sprite = pixiStageList[this.drawerLocNoData.x - 1][this.drawerLocNoData.y];
             updateColor(sprite, 0xFFFFFF);//鎭㈠棰滆壊
           }
         }
@@ -512,6 +512,11 @@
               pixiStageList[index][idx] = sprite
             }
           });
+
+          //瑙嗚灞呬腑
+          let containerWidth = (pixiApp.view.width - objectsContainer.width) / 2;
+          let containerHeight = (pixiApp.view.height - objectsContainer.height) / 2;
+          pixiApp.stage.position.set(containerWidth, containerHeight);
         }else {
           let diff = this.findDiffList(this.map, map);
           diff.forEach((item, index) => {
@@ -927,6 +932,24 @@
           })
         }
       },
+      resetMap() {
+        //閲嶇疆鍦板浘
+        let that = this
+        $.ajax({
+          url:baseUrl+"/console/map/resetMap/" + this.currentLev,
+          headers:{
+            'token': localStorage.getItem('token')
+          },
+          data:{},
+          method:'get',
+          success:function (res) {
+            that.$message({
+              message: that.currentLev + '灞傚湴鍥鹃噸缃畬鎴�',
+              type: 'success'
+            });
+          }
+        })
+      },
     }
   })
 

--
Gitblit v1.9.1