From f0610f8a0a64ad8db88d66dfd5897b5aae2a4ff7 Mon Sep 17 00:00:00 2001 From: zyy <1787816799@qq.com> Date: Fri, 17 Apr 2020 16:41:59 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=BB=A3=E7=A0=81=EF=BC=8C?= =?UTF-8?q?=E5=A4=84=E7=90=86=E7=BA=BF=E8=B7=AF=E7=9A=AE=E8=82=A4=E9=BB=98?= =?UTF-8?q?=E8=AE=A4=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/jmapNew/config/skinCode/foshan_01.js | 4 +- src/jmapNew/config/skinCode/fuzhou_01.js | 4 +- src/jmapNew/config/skinCode/xian_02.js | 4 +- src/permission.js | 1 + src/views/publish/publishMap/index.vue | 64 +++++++++++++----------- 5 files changed, 41 insertions(+), 36 deletions(-) diff --git a/src/jmapNew/config/skinCode/foshan_01.js b/src/jmapNew/config/skinCode/foshan_01.js index da21c50c2..10e0b1a37 100644 --- a/src/jmapNew/config/skinCode/foshan_01.js +++ b/src/jmapNew/config/skinCode/foshan_01.js @@ -128,8 +128,8 @@ class SkinCode extends defaultStyle { }, text: { show: true, // 信号机名称显示 - distance: 0, // 文字和灯杆的距离 - isAlignCenter: true, // 信号字体对其方式 + distance: 3, // 文字和灯杆的距离 + isAlignCenter: false, // 信号字体对其方式 fontSize: 11, // 信号机名称字体大小 fontWeight: 'bold', // 信号机名称字体粗细 defaultColor: '#FFFFFF', // 信号灯字体默认色 diff --git a/src/jmapNew/config/skinCode/fuzhou_01.js b/src/jmapNew/config/skinCode/fuzhou_01.js index 1e943d647..2fbccb2fd 100644 --- a/src/jmapNew/config/skinCode/fuzhou_01.js +++ b/src/jmapNew/config/skinCode/fuzhou_01.js @@ -128,8 +128,8 @@ class SkinCode extends defaultStyle { }, text: { show: true, // 信号机名称显示 - distance: 0, // 文字和灯杆的距离 - isAlignCenter: true, // 信号字体对其方式 + distance: 3, // 文字和灯杆的距离 + isAlignCenter: false, // 信号字体对其方式 fontSize: 11, // 信号机名称字体大小 fontWeight: 'bold', // 信号机名称字体粗细 defaultColor: '#FFFFFF', // 信号灯字体默认色 diff --git a/src/jmapNew/config/skinCode/xian_02.js b/src/jmapNew/config/skinCode/xian_02.js index 2cea4f0fb..20bfa2da3 100644 --- a/src/jmapNew/config/skinCode/xian_02.js +++ b/src/jmapNew/config/skinCode/xian_02.js @@ -146,8 +146,8 @@ class SkinCode extends defaultStyle { }, text: { show: true, // 信号机名称显示 - distance: 0, // 文字和灯杆的距离 - isAlignCenter: true, // 信号字体对其方式 + distance: 3, // 文字和灯杆的距离 + isAlignCenter: false, // 信号字体对其方式 fontSize: 11, // 信号机名称字体大小 fontWeight: 'bold', // 信号机名称字体粗细 defaultColor: 'white', // 信号灯字体默认色 diff --git a/src/permission.js b/src/permission.js index 3d3c9b496..949a5a037 100644 --- a/src/permission.js +++ b/src/permission.js @@ -3,6 +3,7 @@ import store from '@/store/index_APP_TARGET'; import router from './router/index_APP_TARGET'; import {PermissionParam} from '@/scripts/ProjectConfig'; import NProgress from 'nprogress'; +import 'nprogress/nprogress.css'; import { admin} from './router/index_APP_TARGET'; import { getToken, removeToken} from '@/utils/auth'; import { LoginParams } from '@/utils/login'; diff --git a/src/views/publish/publishMap/index.vue b/src/views/publish/publishMap/index.vue index 1b232a9f1..3a6510c99 100644 --- a/src/views/publish/publishMap/index.vue +++ b/src/views/publish/publishMap/index.vue @@ -117,11 +117,11 @@ export default { name: this.$t('global.exportMap'), handleClick: this.handleExportMap }, - { - name: this.$t('global.export'), - handleClick: this.handleExportMapSame, - showControl: () => { return process.env.NODE_ENV === 'development'; } - }, + // { + // name: this.$t('global.export'), + // handleClick: this.handleExportMapSame, + // showControl: () => { return process.env.NODE_ENV === 'development'; } + // }, { name: this.$t('publish.setTheProject'), handleClick: this.handleSetProject @@ -263,34 +263,38 @@ export default { }).catch(() => { }); }, - // 导出地图 + // 导出地图 json async handleExportMap(index, row) { - const res = await getPublishMapExport(row.id); - const resultData = res.data; - if (resultData === false) { - return; - } - - // const self = this; - // import('@/utils/Export2Excel').then(excel => { - // self.queryExportData(resultData).then(data => { - // excel.export_json_excel(data, resultData.name); - // }).catch(error => { - // self.$message.error(`${this.$t('error.exportException')}:${error.message}`); - // }); - // }); - - const content = new Blob([JSON.stringify(resultData)]); - const urlObject = window.URL || window.webkitURL || window; - const url = urlObject.createObjectURL(content); - const el = document.createElement('a'); - el.href = url; - el.download = `${resultData.name}.json`; - el.click(); - urlObject.revokeObjectURL(url); + this.$confirm('您是否导出地图数据?', this.$t('global.tips'), { + confirmButtonText: this.$t('global.confirm'), + cancelButtonText: this.$t('global.cancel'), + type: 'warning' + }).then(async () => { + const res = await getPublishMapExport(row.id); + const resultData = res.data; + if (resultData === false) { + return; + } + // const self = this; + // import('@/utils/Export2Excel').then(excel => { + // self.queryExportData(resultData).then(data => { + // excel.export_json_excel(data, resultData.name); + // }).catch(error => { + // self.$message.error(`${this.$t('error.exportException')}:${error.message}`); + // }); + // }); + const content = new Blob([JSON.stringify(resultData)]); + const urlObject = window.URL || window.webkitURL || window; + const url = urlObject.createObjectURL(content); + const el = document.createElement('a'); + el.href = url; + el.download = `${resultData.name}.json`; + el.click(); + urlObject.revokeObjectURL(url); + }).catch(() => { }); }, - // 部分导出 + // 导出地图 exls async handleExportMapSame(index, row) { const res = await getPublishMapExport(row.id); const resultData = res.data;