diff --git a/dist.zip b/dist.zip new file mode 100644 index 0000000..8e9ac24 --- /dev/null +++ b/dist.zip Binary files differ diff --git a/dist.zip b/dist.zip new file mode 100644 index 0000000..8e9ac24 --- /dev/null +++ b/dist.zip Binary files differ diff --git a/public/config/project.config.json b/public/config/project.config.json index d34ef9b..cbb09d1 100644 --- a/public/config/project.config.json +++ b/public/config/project.config.json @@ -5,8 +5,8 @@ "baseUrl": "http://111.198.10.15:11638/", "wsUrl": "ws://111.198.10.15:11638/websocket/", "mainPage": "http://111.198.10.15:11404/dcms/#", - "amapSecurityCode": "182a2c5889f7fe6d90546d9b8f4781ad", - "amapKey": "1733551f35b56f6d8e9c0a9d4c2523b", + "amapSecurityCode": "56bf9671d4b3517d294caec4751889a1", + "amapKey": "40849e82b4e33f5255b17372520c954d", "mapType": "gaode", "alarmSound": true, "refreshTime": 60, diff --git a/dist.zip b/dist.zip new file mode 100644 index 0000000..8e9ac24 --- /dev/null +++ b/dist.zip Binary files differ diff --git a/public/config/project.config.json b/public/config/project.config.json index d34ef9b..cbb09d1 100644 --- a/public/config/project.config.json +++ b/public/config/project.config.json @@ -5,8 +5,8 @@ "baseUrl": "http://111.198.10.15:11638/", "wsUrl": "ws://111.198.10.15:11638/websocket/", "mainPage": "http://111.198.10.15:11404/dcms/#", - "amapSecurityCode": "182a2c5889f7fe6d90546d9b8f4781ad", - "amapKey": "1733551f35b56f6d8e9c0a9d4c2523b", + "amapSecurityCode": "56bf9671d4b3517d294caec4751889a1", + "amapKey": "40849e82b4e33f5255b17372520c954d", "mapType": "gaode", "alarmSound": true, "refreshTime": 60, diff --git a/src/App.vue b/src/App.vue index dca0151..1ca9454 100644 --- a/src/App.vue +++ b/src/App.vue @@ -12,6 +12,8 @@ name: 'App', mounted() { this.windowResize(window.innerHeight, window.innerWidth) + store.dispatch('settings/setCode', localStorage.getItem('Code')) + store.dispatch('settings/setKey', localStorage.getItem('Key')) }, methods: { // 窗口变化 diff --git a/dist.zip b/dist.zip new file mode 100644 index 0000000..8e9ac24 --- /dev/null +++ b/dist.zip Binary files differ diff --git a/public/config/project.config.json b/public/config/project.config.json index d34ef9b..cbb09d1 100644 --- a/public/config/project.config.json +++ b/public/config/project.config.json @@ -5,8 +5,8 @@ "baseUrl": "http://111.198.10.15:11638/", "wsUrl": "ws://111.198.10.15:11638/websocket/", "mainPage": "http://111.198.10.15:11404/dcms/#", - "amapSecurityCode": "182a2c5889f7fe6d90546d9b8f4781ad", - "amapKey": "1733551f35b56f6d8e9c0a9d4c2523b", + "amapSecurityCode": "56bf9671d4b3517d294caec4751889a1", + "amapKey": "40849e82b4e33f5255b17372520c954d", "mapType": "gaode", "alarmSound": true, "refreshTime": 60, diff --git a/src/App.vue b/src/App.vue index dca0151..1ca9454 100644 --- a/src/App.vue +++ b/src/App.vue @@ -12,6 +12,8 @@ name: 'App', mounted() { this.windowResize(window.innerHeight, window.innerWidth) + store.dispatch('settings/setCode', localStorage.getItem('Code')) + store.dispatch('settings/setKey', localStorage.getItem('Key')) }, methods: { // 窗口变化 diff --git a/src/main.js b/src/main.js index eb0b815..6423dab 100644 --- a/src/main.js +++ b/src/main.js @@ -113,6 +113,9 @@ // } setWsUrl(result.data.wsUrl) console.log(getWsUrl()) + + window.localStorage.setItem('Code', result.data.amapSecurityCode) + window.localStorage.setItem('Key', result.data.amapKey) new Vue({ router, store, diff --git a/dist.zip b/dist.zip new file mode 100644 index 0000000..8e9ac24 --- /dev/null +++ b/dist.zip Binary files differ diff --git a/public/config/project.config.json b/public/config/project.config.json index d34ef9b..cbb09d1 100644 --- a/public/config/project.config.json +++ b/public/config/project.config.json @@ -5,8 +5,8 @@ "baseUrl": "http://111.198.10.15:11638/", "wsUrl": "ws://111.198.10.15:11638/websocket/", "mainPage": "http://111.198.10.15:11404/dcms/#", - "amapSecurityCode": "182a2c5889f7fe6d90546d9b8f4781ad", - "amapKey": "1733551f35b56f6d8e9c0a9d4c2523b", + "amapSecurityCode": "56bf9671d4b3517d294caec4751889a1", + "amapKey": "40849e82b4e33f5255b17372520c954d", "mapType": "gaode", "alarmSound": true, "refreshTime": 60, diff --git a/src/App.vue b/src/App.vue index dca0151..1ca9454 100644 --- a/src/App.vue +++ b/src/App.vue @@ -12,6 +12,8 @@ name: 'App', mounted() { this.windowResize(window.innerHeight, window.innerWidth) + store.dispatch('settings/setCode', localStorage.getItem('Code')) + store.dispatch('settings/setKey', localStorage.getItem('Key')) }, methods: { // 窗口变化 diff --git a/src/main.js b/src/main.js index eb0b815..6423dab 100644 --- a/src/main.js +++ b/src/main.js @@ -113,6 +113,9 @@ // } setWsUrl(result.data.wsUrl) console.log(getWsUrl()) + + window.localStorage.setItem('Code', result.data.amapSecurityCode) + window.localStorage.setItem('Key', result.data.amapKey) new Vue({ router, store, diff --git a/src/store/modules/settings.js b/src/store/modules/settings.js index 67ceed8..46d3df5 100644 --- a/src/store/modules/settings.js +++ b/src/store/modules/settings.js @@ -13,8 +13,10 @@ fixedHeader: fixedHeader, // 是否固定面包屑 sidebarLogo: sidebarLogo, // 是否显示logo bodyHeight: 400, // 内容高度 - amapSecurityCode: 'bbafbe327f95d1a7a93435baa22d0db1', // 安全密钥 - amapKey: '993b8eb999cf15b53f302d9986649674' // 高德地图key + // amapSecurityCode: 'bbafbe327f95d1a7a93435baa22d0db1', // 安全密钥 + // amapKey: '993b8eb999cf15b53f302d9986649674' // 高德地图key + amapSecurityCode: localStorage.getItem('Code'), // 安全密钥 + amapKey: localStorage.getItem('Key') // 高德地图key } const mutations = { @@ -25,7 +27,13 @@ }, SET_BODY_HEIGHT: (state, height) => { state.bodyHeight = height - } + }, + SET_CODE: (state, code) => { + state.amapSecurityCode = code + }, + SET_KEY: (state, key) => { + state.amapKey = key + }, } const actions = { @@ -34,6 +42,12 @@ }, ChangeHeight({ commit }, height) { commit('SET_BODY_HEIGHT', height) + }, + setCode({ commit }, code) { + commit('SET_CODE', code) + }, + setKey({ commit }, key) { + commit('SET_KEY', key) } }