From 6e3424e355186502091ba467aaccf227b6126c54 Mon Sep 17 00:00:00 2001 From: zyy <1787816799@qq.com> Date: Thu, 26 Dec 2019 11:01:54 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=AE=9E=E8=AE=AD=E5=B9=B3?= =?UTF-8?q?=E5=8F=B0=E6=96=B0=E6=97=A7=E5=9C=B0=E5=9B=BE=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/layout/components/Entry.vue | 17 +- src/router/index.js | 9 + src/utils/baseUrl.js | 4 +- src/views/demonstration/detail/index.vue | 10 +- src/views/display/index.vue | 30 +- src/views/display/indexNew.vue | 593 ++++++++++++++++++ .../newMap/mapsystemNew/common/index.vue | 164 +++++ src/views/newMap/mapsystemNew/index.vue | 134 ++++ .../newMap/mapsystemNew/plugin/delayBox.vue | 35 ++ .../newMap/mapsystemNew/plugin/delayInfo.vue | 72 +++ .../newMap/mapsystemNew/plugin/src/poptip.vue | 172 +++++ .../newMap/mapsystemNew/plugin/src/tip.vue | 24 + .../mapsystemNew/plugin/trainingtip.vue | 181 ++++++ .../mapoperate/section/logicBlock.vue | 4 +- src/views/trainingPlatform/demonList.vue | 2 +- 15 files changed, 1413 insertions(+), 38 deletions(-) create mode 100644 src/views/display/indexNew.vue create mode 100644 src/views/newMap/mapsystemNew/common/index.vue create mode 100644 src/views/newMap/mapsystemNew/index.vue create mode 100644 src/views/newMap/mapsystemNew/plugin/delayBox.vue create mode 100644 src/views/newMap/mapsystemNew/plugin/delayInfo.vue create mode 100644 src/views/newMap/mapsystemNew/plugin/src/poptip.vue create mode 100644 src/views/newMap/mapsystemNew/plugin/src/tip.vue create mode 100644 src/views/newMap/mapsystemNew/plugin/trainingtip.vue diff --git a/src/layout/components/Entry.vue b/src/layout/components/Entry.vue index ef4562596..b41f86bcf 100644 --- a/src/layout/components/Entry.vue +++ b/src/layout/components/Entry.vue @@ -22,13 +22,6 @@ - @@ -88,8 +81,7 @@ export default { ], stomp: null, header: null, - lang: 'zh', - switchNewMap: false + lang: 'zh' }; }, computed: { @@ -101,9 +93,6 @@ export default { }, isShown() { return getSessionStorage('project') == 'login' || getSessionStorage('project') == 'design'; - }, - showMapSwitch() { - return process.env.NODE_ENV === 'development' && !getSessionStorage('project').startsWith('design'); } }, watch: { @@ -113,7 +102,6 @@ export default { if (nowLang === 'zh') { this.lang = 'en'; } - this.switchNewMap = this.$store.state.config.switchMap === 'new'; }, methods: { quickEntry() { @@ -163,9 +151,6 @@ export default { break; } return path; - }, - changeSwitch(value) { - this.$store.dispatch('config/changeSwitchMap', value ? 'new' : 'old' ); } } }; diff --git a/src/router/index.js b/src/router/index.js index 35e000956..fd2c2c053 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -14,6 +14,7 @@ const Jlmap3dSandbox = () => import('@/views/jlmap3d/simulation/jl3dsimulation') const Jlmap3dModel = () => import('@/views/jlmap3d/device/jl3ddevice'); const Jlmap3dTrain = () => import('@/views/jlmap3d/devicetrain/jl3ddevicetrain'); const Display = () => import('@/views/display/index'); +const DisplayNew = () => import('@/views/display/indexNew'); const DesignDisplay = () => import('@/views/display/designIndex'); const TrainRoom = () => import('@/views/trainRoom/index'); @@ -149,6 +150,7 @@ export const userTrainingPlatform = '016'; // 实训平台 export const UrlConfig = { display: '/display', + displayNew: '/displayNew', scriptDisplay: '/scriptDisplay', examRuleDraft: '/examRule/draft', examRuleManage: '/examRule/manage', @@ -453,6 +455,13 @@ export const asyncRouter = [ }, hidden: true }, + { + path: '/displayNew/:mode', + component: DisplayNew, + meta: { + }, + hidden: true + }, { path: '/design/display/:mode', component: DesignDisplay, diff --git a/src/utils/baseUrl.js b/src/utils/baseUrl.js index 79d1c6346..1e9afea51 100644 --- a/src/utils/baseUrl.js +++ b/src/utils/baseUrl.js @@ -3,11 +3,11 @@ export function getBaseUrl() { let BASE_API; if (process.env.NODE_ENV === 'development') { // BASE_API = 'https://joylink.club/jlcloud'; - // BASE_API = 'https://test.joylink.club/jlcloud'; + BASE_API = 'https://test.joylink.club/jlcloud'; // BASE_API = 'http://192.168.3.5:9000'; // 袁琪 // BASE_API = 'http://192.168.3.6:9000'; // 旭强 // BASE_API = 'http://192.168.3.41:9000'; // 张赛 - BASE_API = 'http://192.168.3.82:9000'; // 杜康 + // BASE_API = 'http://192.168.3.82:9000'; // 杜康 } else { BASE_API = process.env.VUE_APP_BASE_API; } diff --git a/src/views/demonstration/detail/index.vue b/src/views/demonstration/detail/index.vue index 96e9a6608..0ac655945 100644 --- a/src/views/demonstration/detail/index.vue +++ b/src/views/demonstration/detail/index.vue @@ -61,7 +61,8 @@ export default { }, jointShow: false, jointGroup: '', - lineCode:'' + lineCode:'', + drawWay: false // 是否新版地图 }; }, computed: { @@ -104,6 +105,7 @@ export default { const resp = await getSubSystemDetail(this.$route.params.subSystem); this.tryUser = 0; this.loading = false; + this.drawWay = res.data.drawWay; if (resp.data.mapPrd) { this.courseModel = { id: resp.data.mapPrd.id, @@ -235,7 +237,11 @@ export default { const data = { mapId: this.courseModel.mapId, mapPrdId: this.currentPrdId }; simulationNotify(data).then(resp => { const query = { lineCode: this.courseModel.lineCode, group: resp.data, prdType: this.courseModel.prdType, mapId: this.courseModel.mapId, code: this.currentPrdId, goodsId: this.goodsId, try: this.tryUser }; - this.$router.push({ path: `${UrlConfig.display}/demon`, query: query }); + if (this.drawWay) { // 新版地图 + this.$router.push({ path: `${UrlConfig.displayNew}/demon`, query: query }); + } else { + this.$router.push({ path: `${UrlConfig.display}/demon`, query: query }); + } launchFullscreen(); }).catch(error => { this.$messageBox(this.$t('error.createSimulationFailed') + error.message); diff --git a/src/views/display/index.vue b/src/views/display/index.vue index cc194724a..00cb89468 100644 --- a/src/views/display/index.vue +++ b/src/views/display/index.vue @@ -532,23 +532,23 @@ export default { this.drivingShow = true; this.$refs.Jl3dDrive.show(this.mapId, this.group); } else { - let routeData = this.$router.resolve({ -   path:'/jlmap3d/sandbox', - query:{ - mapid:this.mapId, - group:this.group, - token:getToken(), - } - }); - window.open(routeData.href, '_blank','noopener noreferrer'); + const routeData = this.$router.resolve({ + path:'/jlmap3d/sandbox', + query:{ + mapid:this.mapId, + group:this.group, + token:getToken() + } + }); + window.open(routeData.href, '_blank', 'noopener noreferrer'); } }, - devicemodel(){ - if(this.deviceShow == false){ - this.deviceShow = true; - }else{ - this.deviceShow = false; - } + devicemodel() { + if (this.deviceShow == false) { + this.deviceShow = true; + } else { + this.deviceShow = false; + } }, showScheduling() { diff --git a/src/views/display/indexNew.vue b/src/views/display/indexNew.vue new file mode 100644 index 000000000..1c3a529ae --- /dev/null +++ b/src/views/display/indexNew.vue @@ -0,0 +1,593 @@ + + + + diff --git a/src/views/newMap/mapsystemNew/common/index.vue b/src/views/newMap/mapsystemNew/common/index.vue new file mode 100644 index 000000000..b5537db86 --- /dev/null +++ b/src/views/newMap/mapsystemNew/common/index.vue @@ -0,0 +1,164 @@ + + + + diff --git a/src/views/newMap/mapsystemNew/index.vue b/src/views/newMap/mapsystemNew/index.vue new file mode 100644 index 000000000..719d4ebb6 --- /dev/null +++ b/src/views/newMap/mapsystemNew/index.vue @@ -0,0 +1,134 @@ + + + + diff --git a/src/views/newMap/mapsystemNew/plugin/delayBox.vue b/src/views/newMap/mapsystemNew/plugin/delayBox.vue new file mode 100644 index 000000000..ef36dd91b --- /dev/null +++ b/src/views/newMap/mapsystemNew/plugin/delayBox.vue @@ -0,0 +1,35 @@ + + + + + diff --git a/src/views/newMap/mapsystemNew/plugin/delayInfo.vue b/src/views/newMap/mapsystemNew/plugin/delayInfo.vue new file mode 100644 index 000000000..d6a9bdba2 --- /dev/null +++ b/src/views/newMap/mapsystemNew/plugin/delayInfo.vue @@ -0,0 +1,72 @@ + + + + + diff --git a/src/views/newMap/mapsystemNew/plugin/src/poptip.vue b/src/views/newMap/mapsystemNew/plugin/src/poptip.vue new file mode 100644 index 000000000..0e0ee61ff --- /dev/null +++ b/src/views/newMap/mapsystemNew/plugin/src/poptip.vue @@ -0,0 +1,172 @@ + + + + + diff --git a/src/views/newMap/mapsystemNew/plugin/src/tip.vue b/src/views/newMap/mapsystemNew/plugin/src/tip.vue new file mode 100644 index 000000000..d571475c6 --- /dev/null +++ b/src/views/newMap/mapsystemNew/plugin/src/tip.vue @@ -0,0 +1,24 @@ + + + diff --git a/src/views/newMap/mapsystemNew/plugin/trainingtip.vue b/src/views/newMap/mapsystemNew/plugin/trainingtip.vue new file mode 100644 index 000000000..a1235af78 --- /dev/null +++ b/src/views/newMap/mapsystemNew/plugin/trainingtip.vue @@ -0,0 +1,181 @@ + + + diff --git a/src/views/newMap/newMapdraft/mapoperate/section/logicBlock.vue b/src/views/newMap/newMapdraft/mapoperate/section/logicBlock.vue index d94c8b83f..99d4366e7 100644 --- a/src/views/newMap/newMapdraft/mapoperate/section/logicBlock.vue +++ b/src/views/newMap/newMapdraft/mapoperate/section/logicBlock.vue @@ -88,7 +88,7 @@ export default { logicSectionNumList.push(Number(ele.num)); counts += parseInt(ele.num); }); - if (counts === 0 || allNotZeros) { + if (counts == 0 || allNotZeros) { let logicSectionCodeList = []; models.forEach(item=> { logicSectionCodeList.push(item.code); @@ -98,7 +98,7 @@ export default { models.push(deepAssign(section, {_dispose: true})); } }); - if (counts === 0) { + if (counts == 0) { logicSectionNumList = []; logicSectionCodeList = []; } diff --git a/src/views/trainingPlatform/demonList.vue b/src/views/trainingPlatform/demonList.vue index 0b73c0584..c8469ae2b 100644 --- a/src/views/trainingPlatform/demonList.vue +++ b/src/views/trainingPlatform/demonList.vue @@ -120,7 +120,7 @@ export default { this.mapId = obj.id; this.$router.push({ path: `${UrlConfig.trainingPlatform.permission}/${this.mapId}`}); } else if ( obj.type === 'MapSystem') { - getSubSystemInfo(obj.id).then(resp => { + getSubSystemInfo(obj.id).then(resp => { // 查询子系统信息 let router = ''; switch (resp.data.type) { case 'Exam':