From 4dbcd896a44e617369c0265d98fcdbb3c1129dfd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=9C=E7=AC=99=E6=AD=8C?= <2277317060@qq.com> Date: Mon, 4 Nov 2024 18:05:16 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=97=A0=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E5=8C=B9=E9=85=8D=E5=B7=A5=E4=BD=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hw-ui/package.json | 1 + hw-ui/src/views/login.vue | 5 +++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hw-ui/package.json b/hw-ui/package.json index f1d82ef..c0906e4 100644 --- a/hw-ui/package.json +++ b/hw-ui/package.json @@ -42,6 +42,7 @@ "clipboard": "2.0.8", "core-js": "3.25.3", "echarts": "5.5.0", + "echarts-liquidfill": "^3.1.0", "element-ui": "2.15.14", "file-saver": "2.0.5", "fuse.js": "6.4.3", diff --git a/hw-ui/src/views/login.vue b/hw-ui/src/views/login.vue index 0a38ce9..d8792a4 100644 --- a/hw-ui/src/views/login.vue +++ b/hw-ui/src/views/login.vue @@ -224,7 +224,7 @@ export default { } this.$store.dispatch('Login', this.loginForm).then(() => { let data = this.options.find(v => v.processId === this.loginForm.processId) || {} - let routeData = this.floorData.find(v => v.floor === data.processFloor && v.processId === data.processId) || null + let routeData = this.floorData.find(v => v.floor === data.processFloor && v.processId === data.processId) || {} if(this.$route?.query?.isStationId === 'true' && !routeData){ routeData = { floor: 4, @@ -234,9 +234,10 @@ export default { } let query = { processName: this.loginForm.processName } routeData.query = query - if (routeData.route) { + if (routeData?.route) { sessionStorage.setItem('FLOORDATA', JSON.stringify(routeData)) } + console.log(routeData) // this.$router.push({path: this.redirect || "/"}).catch(() => { // }); this.$router.push({ path: routeData.route || this.redirect || '/' }).catch(() => {