From 5dba0daf423f5b4e45b3bcdb55c7de51950dc277 Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期四, 13 三月 2025 10:21:22 +0800
Subject: [PATCH] #

---
 src/main/webapp/views/console.html |   32 +++++++++++++++++++-------------
 1 files changed, 19 insertions(+), 13 deletions(-)

diff --git a/src/main/webapp/views/console.html b/src/main/webapp/views/console.html
index 7f5fb5d..1da3dbe 100644
--- a/src/main/webapp/views/console.html
+++ b/src/main/webapp/views/console.html
@@ -334,7 +334,7 @@
 					map: [],//鍦板浘鏁版嵁
 					currentLev: 1,//鍦板浘褰撳墠妤煎眰
 					siteWindow: false, //绔欑偣寮圭獥鏄剧ず榛樿涓嶆樉绀�
-					floorList: [1, 2, 3, 4], //褰撳墠椤圭洰妤煎眰
+					floorList: [], //褰撳墠椤圭洰妤煎眰
 					shuttleList: [], //鍥涘悜绌挎杞﹂泦鍚�
 					currentLevShuttleList: [],//褰撳墠妤煎眰鍥涘悜绌挎杞﹂泦鍚�
 					shuttleColorList: [],//鍥涘悜绌挎杞﹂鑹查泦鍚�
@@ -361,6 +361,7 @@
 
 						this.getMap(this.currentLev)
 						this.getSystemRunningStatus() //鑾峰彇绯荤粺杩愯鐘舵��
+						this.initLev()//鍒濆鍖栨ゼ灞備俊鎭�
 
 						this.consoleInterval = setInterval(() => {
 							this.getShuttleStateInfo() //鑾峰彇鍥涘悜绌挎杞︿俊鎭�
@@ -663,23 +664,28 @@
 							}
 						})
 					},
-					initLoc() {
-						//鍒濆鍖栧簱浣�
+					initLev(){
 						let that = this
 						$.ajax({
-							url:baseUrl+"/locMast/init",
-							headers:{
+							url: baseUrl + "/console/map/lev/list",
+							headers: {
 								'token': localStorage.getItem('token')
 							},
-							data:{},
-							method:'post',
-							success:function (res) {
-								that.$message({
-									message: '鍒濆鍖栧畬鎴�',
-									type: 'success'
-								});
+							data: {},
+							method: 'get',
+							success: function(res) {
+								if (res.code === 200) {
+									that.floorList = res.data;
+								} else if (res.code === 403) {
+									parent.location.href = baseUrl + "/login";
+								} else {
+									that.$message({
+										message: res.msg,
+										type: 'error'
+									});
+								}
 							}
-						})
+						});
 					},
 					getCodeData(){
 						this.sendWs(JSON.stringify({

--
Gitblit v1.9.1