diff --git a/package-lock.json b/package-lock.json index db35858..4496d0d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -14,6 +14,7 @@ "core-js": "^3.8.3", "echarts": "^5.4.3", "element-ui": "^2.15.14", + "js-cookie": "^3.0.5", "vue": "^2.6.14", "vue-router": "^3.5.1", "vuex": "^3.6.2" @@ -7364,6 +7365,14 @@ "@sideway/pinpoint": "^2.0.0" } }, + "node_modules/js-cookie": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/js-cookie/-/js-cookie-3.0.5.tgz", + "integrity": "sha512-cEiJEAEoIbWfCZYKWhVwFuvPX1gETRYPw6LlaTKoxD3s2AkXzkCjnp6h0V77ozyqj0jakteJ4YqDJT830+lVGw==", + "engines": { + "node": ">=14" + } + }, "node_modules/js-message": { "version": "1.0.7", "resolved": "https://registry.npmmirror.com/js-message/-/js-message-1.0.7.tgz", @@ -17731,6 +17740,11 @@ "@sideway/pinpoint": "^2.0.0" } }, + "js-cookie": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/js-cookie/-/js-cookie-3.0.5.tgz", + "integrity": "sha512-cEiJEAEoIbWfCZYKWhVwFuvPX1gETRYPw6LlaTKoxD3s2AkXzkCjnp6h0V77ozyqj0jakteJ4YqDJT830+lVGw==" + }, "js-message": { "version": "1.0.7", "resolved": "https://registry.npmmirror.com/js-message/-/js-message-1.0.7.tgz", diff --git a/package.json b/package.json index c6fa913..75216c6 100644 --- a/package.json +++ b/package.json @@ -14,6 +14,7 @@ "core-js": "^3.8.3", "echarts": "^5.4.3", "element-ui": "^2.15.14", + "js-cookie": "^3.0.5", "vue": "^2.6.14", "vue-router": "^3.5.1", "vuex": "^3.6.2" diff --git a/public/index.html b/public/index.html index 0ef2ae7..75f227d 100644 --- a/public/index.html +++ b/public/index.html @@ -11,9 +11,9 @@ - - - + + +
diff --git a/src/api/coastalMap/resource/index.js b/src/api/coastalMap/resource/index.js new file mode 100644 index 0000000..f96352d --- /dev/null +++ b/src/api/coastalMap/resource/index.js @@ -0,0 +1,10 @@ +// 资源概况 +import request from '@/utils/request' +// 实有人口查询 +export function get_person_num(params) { + return request({ + url: '/base/metaActualUserInfo', + method: 'get', + params + }) +} \ No newline at end of file diff --git a/src/assets/coastalMap/box_back.png b/src/assets/coastalMap/box_back.png new file mode 100644 index 0000000..81666ef Binary files /dev/null and b/src/assets/coastalMap/box_back.png differ diff --git a/src/assets/coastalMap/box_back02.png b/src/assets/coastalMap/box_back02.png new file mode 100644 index 0000000..a2ffea9 Binary files /dev/null and b/src/assets/coastalMap/box_back02.png differ diff --git a/src/assets/coastalMap/box_title_back.png b/src/assets/coastalMap/box_title_back.png new file mode 100644 index 0000000..cb6e1af Binary files /dev/null and b/src/assets/coastalMap/box_title_back.png differ diff --git a/src/assets/coastalMap/keyPerson/key_all_back.png b/src/assets/coastalMap/keyPerson/key_all_back.png new file mode 100644 index 0000000..497159c Binary files /dev/null and b/src/assets/coastalMap/keyPerson/key_all_back.png differ diff --git a/src/assets/coastalMap/resource_item_back01.png b/src/assets/coastalMap/resource_item_back01.png new file mode 100644 index 0000000..497159c Binary files /dev/null and b/src/assets/coastalMap/resource_item_back01.png differ diff --git a/src/assets/coastalMap/resource_item_back02.png b/src/assets/coastalMap/resource_item_back02.png new file mode 100644 index 0000000..248b2b2 Binary files /dev/null and b/src/assets/coastalMap/resource_item_back02.png differ diff --git a/src/assets/coastalMap/resource_item_back03.png b/src/assets/coastalMap/resource_item_back03.png new file mode 100644 index 0000000..2167332 Binary files /dev/null and b/src/assets/coastalMap/resource_item_back03.png differ diff --git a/src/assets/coastalMap/resource_item_back04.png b/src/assets/coastalMap/resource_item_back04.png new file mode 100644 index 0000000..dfeea56 Binary files /dev/null and b/src/assets/coastalMap/resource_item_back04.png differ diff --git a/src/assets/homepage/police.png b/src/assets/homepage/police.png new file mode 100644 index 0000000..c1012c5 Binary files /dev/null and b/src/assets/homepage/police.png differ diff --git a/src/assets/homepage/title_back.png b/src/assets/homepage/title_back.png new file mode 100644 index 0000000..5e7684d Binary files /dev/null and b/src/assets/homepage/title_back.png differ diff --git a/src/router/index.js b/src/router/index.js index 8e67419..1a9026b 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -24,17 +24,17 @@ const routes = [ path: 'coastalMap', name: 'coastalMap', component: () => import('@/views/coastalMap/index.vue') - }, - { - path: 'videoMonitor', - name: 'videoMonitor', - component: () => import('@/views/videoMonitor/index.vue') - }, - { - path: 'sensingDevice', - name: 'sensingDevice', - component: () => import('@/views/sensingDevice/index.vue') } + // { + // path: 'videoMonitor', + // name: 'videoMonitor', + // component: () => import('@/views/videoMonitor/index.vue') + // }, + // { + // path: 'sensingDevice', + // name: 'sensingDevice', + // component: () => import('@/views/sensingDevice/index.vue') + // } ] } ] diff --git a/src/utils/auth.js b/src/utils/auth.js new file mode 100644 index 0000000..449a98e --- /dev/null +++ b/src/utils/auth.js @@ -0,0 +1,15 @@ +import Cookies from 'js-cookie' + +const syToken = 'url_token' + +export function getToken() { + return Cookies.get(syToken) +} + +export function setToken(token) { + return Cookies.set(syToken, token) +} + +export function removeToken() { + return Cookies.remove(syToken) +} \ No newline at end of file diff --git a/src/utils/esresize.js b/src/utils/esresize.js new file mode 100644 index 0000000..89cab28 --- /dev/null +++ b/src/utils/esresize.js @@ -0,0 +1,105 @@ +var EleResize = { + _handleResize: function (e) { + var ele = e.target || e.srcElement + var trigger = ele.__resizeTrigger__ + if (trigger) { + var handlers = trigger.__z_resizeListeners + if (handlers) { + var size = handlers.length + for (var i = 0; i < size; i++) { + var h = handlers[i] + var handler = h.handler + var context = h.context + handler.apply(context, [e]) + } + } + } + }, + _removeHandler: function (ele, handler, context) { + var handlers = ele.__z_resizeListeners + if (handlers) { + var size = handlers.length + for (var i = 0; i < size; i++) { + var h = handlers[i] + if (h.handler === handler && h.context === context) { + handlers.splice(i, 1) + return + } + } + } + }, + _createResizeTrigger: function (ele) { + var obj = document.createElement('object') + obj.setAttribute('style', + 'display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden;opacity: 0; pointer-events: none; z-index: -1;') + obj.onload = EleResize._handleObjectLoad + obj.type = 'text/html' + ele.appendChild(obj) + obj.data = 'about:blank' + return obj + }, + _handleObjectLoad: function () { + this.contentDocument.defaultView.__resizeTrigger__ = this.__resizeElement__ + this.contentDocument.defaultView.addEventListener('resize', EleResize._handleResize) + } +} +if (document.attachEvent) { // ie9-10 + EleResize.on = function (ele, handler, context) { + var handlers = ele.__z_resizeListeners + if (!handlers) { + handlers = [] + ele.__z_resizeListeners = handlers + ele.__resizeTrigger__ = ele + ele.attachEvent('onresize', EleResize._handleResize) + } + handlers.push({ + handler: handler, + context: context + }) + } + EleResize.off = function (ele, handler, context) { + var handlers = ele.__z_resizeListeners + if (handlers) { + EleResize._removeHandler(ele, handler, context) + if (handlers.length === 0) { + ele.detachEvent('onresize', EleResize._handleResize) + delete ele.__z_resizeListeners + } + } + } +} else { + EleResize.on = function (ele, handler, context) { + var handlers = ele.__z_resizeListeners + if (!handlers) { + handlers = [] + ele.__z_resizeListeners = handlers + + if (getComputedStyle(ele, null).position === 'static') { + ele.style.position = 'relative' + } + var obj = EleResize._createResizeTrigger(ele) + ele.__resizeTrigger__ = obj + obj.__resizeElement__ = ele + } + handlers.push({ + handler: handler, + context: context + }) + } + EleResize.off = function (ele, handler, context) { + var handlers = ele.__z_resizeListeners + if (handlers) { + EleResize._removeHandler(ele, handler, context) + if (handlers.length === 0) { + var trigger = ele.__resizeTrigger__ + if (trigger) { + trigger.contentDocument.defaultView.removeEventListener('resize', EleResize._handleResize) + ele.removeChild(trigger) + delete ele.__resizeTrigger__ + } + delete ele.__z_resizeListeners + } + } + } +} +export default EleResize diff --git a/src/views/coastalMap/components/keyPerson.vue b/src/views/coastalMap/components/keyPerson.vue new file mode 100644 index 0000000..273cf97 --- /dev/null +++ b/src/views/coastalMap/components/keyPerson.vue @@ -0,0 +1,273 @@ + + +