From 8c054f492fbced3b81295838f88525094196c629 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Wed, 25 Nov 2020 13:31:36 +0800 Subject: [PATCH 1/5] =?UTF-8?q?=E5=AE=9E=E8=AE=AD=E5=B9=B3=E5=8F=B0=20?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/App.vue | 8 +-- src/views/demonstration/deomonList/index.vue | 37 +---------- src/views/demonstration/deomonTopic/index.vue | 14 +--- src/views/newMap/jlmapNew/index.vue | 65 +++++++++---------- src/views/trainingPlatform/demonList.vue | 12 +--- src/views/trainingPlatform/index.vue | 17 ++--- 6 files changed, 48 insertions(+), 105 deletions(-) diff --git a/src/App.vue b/src/App.vue index 48b7c900a..d02130dfe 100644 --- a/src/App.vue +++ b/src/App.vue @@ -28,11 +28,6 @@ export default { loading: false }; }, - computed: { - path() { - return window.location.pathname; - } - }, watch: { '$store.state.socket.simulationInvite': function (val) { if (val.creator) { @@ -101,7 +96,8 @@ export default { }, subscribe() { const token = getToken(); - if (token && this.$route.path != '/404' && !this.path.endsWith('login')) { + const path = window.location.pathname; + if (token && this.$route.path != '/404' && !path.endsWith('login')) { const header = { group: '', 'X-Token': token }; this.$store.dispatch('subscribe', {header, type: getSessionStorage('project')}); } diff --git a/src/views/demonstration/deomonList/index.vue b/src/views/demonstration/deomonList/index.vue index 11307b1fb..b3b1b9815 100644 --- a/src/views/demonstration/deomonList/index.vue +++ b/src/views/demonstration/deomonList/index.vue @@ -2,8 +2,8 @@ @@ -44,8 +44,6 @@