From c40fae43ada40c69742868cb0999595be6f9aff8 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Wed, 24 Feb 2021 14:57:23 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E5=AE=81=E6=B3=A2=E4=B8=89=E5=8F=B7?= =?UTF-8?q?=E7=BA=BF=20=E6=8E=A7=E5=88=B6=E6=9D=83=E8=BD=AC=E7=A7=BB=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/jmapNew/shape/Station/index.js | 1 - src/jmapNew/theme/ningbo_03/menus/menuBar.vue | 6 ++- .../menus/menuDialog/stationDevolution.vue | 18 +++++++- .../menus/menuDialog/stationReclaim.vue | 18 +++++++- .../menus/menuDialog/stationRequest.vue | 18 +++++++- .../menus/menuDialog/stationTransfer.vue | 45 +++++++++++++++++-- src/utils/baseUrl.js | 4 +- 7 files changed, 98 insertions(+), 12 deletions(-) diff --git a/src/jmapNew/shape/Station/index.js b/src/jmapNew/shape/Station/index.js index 0df2402d5..114c81f6a 100644 --- a/src/jmapNew/shape/Station/index.js +++ b/src/jmapNew/shape/Station/index.js @@ -563,7 +563,6 @@ export default class Station extends Group { } handleControlApplicant(model) { - // const controlApplicant = model.controlApplicant; if (this.style.Station.stationText.isSpecialType) { const memberData = store.state.training.memberData; if (memberData[model.controller].userId == store.state.user.id ) { diff --git a/src/jmapNew/theme/ningbo_03/menus/menuBar.vue b/src/jmapNew/theme/ningbo_03/menus/menuBar.vue index 3caf01371..243888f2a 100644 --- a/src/jmapNew/theme/ningbo_03/menus/menuBar.vue +++ b/src/jmapNew/theme/ningbo_03/menus/menuBar.vue @@ -1347,7 +1347,7 @@ export default { this.checkRoleChange(oldval, newval); // } }, - '$store.state.menuOperation.selectedCount': function (val) { + '$store.state.menuOperation.leftClickCount': function (val) { this.selectedChange(); } @@ -1366,7 +1366,9 @@ export default { methods: { selectedChange() { const model = this.$store.state.menuOperation.selected; - if (model && model._type && model._type == 'Station' && model.controlApplicant) { + const memberData = this.$store.state.training.memberData; + if (model && model._type && model._type == 'Station' && model.controlApplicant && + model.controller && memberData[model.controller].userId == this.$store.state.user.id) { const item = {operate: OperationEvent.Command.commandNingBo3.line_stand_transfer}; this.authorizeTransfer(item); } diff --git a/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationDevolution.vue b/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationDevolution.vue index 5bd2ad11b..c4f8abf2a 100644 --- a/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationDevolution.vue +++ b/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationDevolution.vue @@ -14,7 +14,11 @@ - + + +
{{ message }}
@@ -131,6 +135,18 @@ export default { this.$store.dispatch('training/emitTipFresh'); }); }, + getControllUserId(controller) { + if (controller) { + const member = this.$store.state.training.memberData[controller]; + if (member && member.labelName) { + return member.labelName; + } else { + return ''; + } + } else { + return ''; + } + }, doClose() { this.dialogShow = false; this.status = true; diff --git a/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationReclaim.vue b/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationReclaim.vue index f8dfa5a7c..5d61741bc 100644 --- a/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationReclaim.vue +++ b/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationReclaim.vue @@ -21,7 +21,11 @@ @current-change="handleCurrentChange" > - + + + 所有站台(F) @@ -146,6 +150,18 @@ export default { this.$store.dispatch('training/emitTipFresh'); }); }, + getControllUserId(controller) { + if (controller) { + const member = this.$store.state.training.memberData[controller]; + if (member && member.labelName) { + return member.labelName; + } else { + return ''; + } + } else { + return ''; + } + }, doClose() { this.dialogShow = false; this.status = true; diff --git a/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationRequest.vue b/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationRequest.vue index f2f4d9858..7d79392fd 100644 --- a/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationRequest.vue +++ b/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationRequest.vue @@ -14,7 +14,11 @@ - + + + 所有站台(F) @@ -145,6 +149,18 @@ export default { this.$store.dispatch('training/emitTipFresh'); }); }, + getControllUserId(controller) { + if (controller) { + const member = this.$store.state.training.memberData[controller]; + if (member && member.labelName) { + return member.labelName; + } else { + return ''; + } + } else { + return ''; + } + }, isCurrentStation(stationEle) { if (this.$store.state.map.showCentralizedStationCode == stationEle.code) { this.status = false; diff --git a/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationTransfer.vue b/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationTransfer.vue index 533d41f02..f477ae503 100644 --- a/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationTransfer.vue +++ b/src/jmapNew/theme/ningbo_03/menus/menuDialog/stationTransfer.vue @@ -13,11 +13,24 @@ > - + - + + + + @@ -123,23 +136,47 @@ export default { 'selected': function(val) { if (val && val.code) { const stationEle = this.$store.getters['map/getDeviceByCode'](val.code); - if (stationEle.controlApplicant) { + const memberData = this.$store.state.training.memberData; + if (stationEle.controller && memberData[stationEle.controller].userId == this.$store.state.user.id) { this.status = false; } else { this.status = true; } + } else { + this.status = true; } } }, methods: { doShow() { this.message = ''; + this.$store.dispatch('menuOperation/setSelected', {device: {}}); this.dialogShow = true; this.$nextTick(e => { this.$refs.table.setCurrentRow(); this.$store.dispatch('training/emitTipFresh'); }); }, + getControlApplUserId(controller, controlApplicant) { + const memberData = this.$store.state.training.memberData; + if (controller && memberData[controller] && memberData[controller].userId == this.$store.state.user.id ) { + return this.getControllUserId(controlApplicant); + } else { + return ''; + } + }, + getControllUserId(controller) { + if (controller) { + const member = this.$store.state.training.memberData[controller]; + if (member && member.labelName) { + return member.labelName; + } else { + return ''; + } + } else { + return ''; + } + }, doClose() { this.dialogShow = false; this.status = true; diff --git a/src/utils/baseUrl.js b/src/utils/baseUrl.js index 51ddbe296..1310fdfc7 100644 --- a/src/utils/baseUrl.js +++ b/src/utils/baseUrl.js @@ -2,11 +2,11 @@ export function getBaseUrl() { let BASE_API; if (process.env.NODE_ENV === 'development') { // BASE_API = 'https://api.joylink.club/jlcloud'; - BASE_API = 'https://test.joylink.club/jlcloud'; + // BASE_API = 'https://test.joylink.club/jlcloud'; // BASE_API = 'http://192.168.8.107:9000'; // 袁琪 // BASE_API = 'http://192.168.8.129:9000'; // 旭强 // BASE_API = 'http://192.168.8.119:9000'; // 张赛 - // BASE_API = 'http://192.168.8.140:9000'; // 杜康 + BASE_API = 'http://192.168.8.140:9000'; // 杜康 // BASE_API = 'http://b29z135112.zicp.vip'; // BASE_API = 'http://2925963m2a.zicp.vip'; // 杜康 // BASE_API = 'http://2i38984j47.qicp.vip'; // 张赛 From 06a87aaaeac69b68e5734448f61d13aa20e34ce0 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Wed, 24 Feb 2021 15:16:55 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E5=AE=81=E6=B3=A2=E4=B8=89=E5=8F=B7?= =?UTF-8?q?=E7=BA=BF=20=E5=88=A0=E9=99=A4=E4=B8=8D=E9=9C=80=E8=A6=81?= =?UTF-8?q?=E7=9A=84=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ningbo_03/menus/dialog/routeSelection.vue | 244 ------------------ .../theme/ningbo_03/menus/menuSignal.vue | 177 ------------- 2 files changed, 421 deletions(-) delete mode 100644 src/jmapNew/theme/ningbo_03/menus/dialog/routeSelection.vue diff --git a/src/jmapNew/theme/ningbo_03/menus/dialog/routeSelection.vue b/src/jmapNew/theme/ningbo_03/menus/dialog/routeSelection.vue deleted file mode 100644 index f7d093e7d..000000000 --- a/src/jmapNew/theme/ningbo_03/menus/dialog/routeSelection.vue +++ /dev/null @@ -1,244 +0,0 @@ - - - diff --git a/src/jmapNew/theme/ningbo_03/menus/menuSignal.vue b/src/jmapNew/theme/ningbo_03/menus/menuSignal.vue index 87299c3fa..e84e170ce 100644 --- a/src/jmapNew/theme/ningbo_03/menus/menuSignal.vue +++ b/src/jmapNew/theme/ningbo_03/menus/menuSignal.vue @@ -1,11 +1,8 @@ + + + + + diff --git a/src/views/jlmap3d/stationmanager/component/manager.vue b/src/views/jlmap3d/stationmanager/component/manager.vue new file mode 100644 index 000000000..d75a23888 --- /dev/null +++ b/src/views/jlmap3d/stationmanager/component/manager.vue @@ -0,0 +1,74 @@ + + + diff --git a/src/views/jlmap3d/stationmanager/component/property.vue b/src/views/jlmap3d/stationmanager/component/property.vue new file mode 100644 index 000000000..9848e3076 --- /dev/null +++ b/src/views/jlmap3d/stationmanager/component/property.vue @@ -0,0 +1,115 @@ + + + + + + diff --git a/src/views/jlmap3d/stationmanager/jl3dstationmanager.vue b/src/views/jlmap3d/stationmanager/jl3dstationmanager.vue index c4c81de37..667ce42b5 100644 --- a/src/views/jlmap3d/stationmanager/jl3dstationmanager.vue +++ b/src/views/jlmap3d/stationmanager/jl3dstationmanager.vue @@ -1,6 +1,23 @@ @@ -10,14 +27,20 @@ import { Jl3dStationManager } from '@/jlmap3d/jl3dstationmanager/jl3dstationmanager.js'; + import DrawType from '@/views/jlmap3d/stationmanager/component/drawtype'; + import ProPerty from '@/views/jlmap3d/stationmanager/component/property'; export default { name: 'jl3devacuation', components: { + DrawType, + ProPerty, }, data() { return { localStatic:JL3D_LOCAL_STATIC, jl3d: null, + switchButtonName:'仿真视角', + viewStatus:false, } }, watch: { @@ -39,13 +62,34 @@ let dom = document.getElementById('jl3d'); this.jl3d = new Jl3dStationManager(dom); }, + changeDrawType(drawTypeName){ + // console.log(drawTypeName); + this.jl3d.changeDrawType(drawTypeName); + }, + switchViews(){ + + if(this.viewStatus == false){ + this.switchButtonName = '绘制视角', + this.viewStatus = true; + this.jl3d.changeControlMode(true); + }else if(this.viewStatus == true){ + this.switchButtonName = '仿真视角 ', + this.viewStatus = false; + this.jl3d.changeControlMode(false); + } + }, } }