From 0e23e9f6a9a7e1b6005674cca0a6dafdbf3436ba Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Mon, 23 Mar 2020 10:47:16 +0800 Subject: [PATCH 01/14] =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/jmapNew/shape/Automactic/index.js | 12 ++++++------ src/jmapNew/shape/AutomacticRoute/index.js | 12 ++++++------ src/jmapNew/shape/GuideLock/index.js | 12 ++++++------ 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/jmapNew/shape/Automactic/index.js b/src/jmapNew/shape/Automactic/index.js index 06a400eb8..1f53bbaf9 100644 --- a/src/jmapNew/shape/Automactic/index.js +++ b/src/jmapNew/shape/Automactic/index.js @@ -167,28 +167,28 @@ export default class Automactic extends Group { const showMode = this.model.showMode; const showConditions = this.style.AutoTurnBack.visibleConditions; if (!showConditions || showConditions === '01' || showMode === showConditions) { - this.show(); + this.showMode(); } else { - this.hide(); + this.hideMode(); } } setShowStation(stationCode) { if (!stationCode || this.model.stationCode === stationCode) { this.isShowShape = true; - this.show(); + this.showMode(); } else { this.isShowShape = false; - this.hide(); + this.hideMode(); } } - show() { + showMode() { this.control && this.control.show(); this.text && this.text.show(); this.subtitleText && this.subtitleText.show(); this.arcBorder && this.arcBorder.show(); this.setState(this.model); } - hide() { + hideMode() { this.control && this.control.hide(); this.text && this.text.hide(); this.subtitleText && this.subtitleText.hide(); diff --git a/src/jmapNew/shape/AutomacticRoute/index.js b/src/jmapNew/shape/AutomacticRoute/index.js index 17979cb80..6463e7ae4 100644 --- a/src/jmapNew/shape/AutomacticRoute/index.js +++ b/src/jmapNew/shape/AutomacticRoute/index.js @@ -136,27 +136,27 @@ export default class AutomacticRoute extends Group { const showMode = this.model.showMode; const showConditions = this.style.AutomaticRoute.displayCondition; if (!showConditions || showConditions === '01' || showMode === showConditions) { - this.show(); + this.showMode(); } else { - this.hide(); + this.hideMode(); } } setShowStation(stationCode) { if (!stationCode || this.model.stationCode === stationCode) { this.isShowShape = true; - this.show(); + this.showMode(); } else { this.isShowShape = false; - this.hide(); + this.hideMode(); } } - show() { + showMode() { this.control && this.control.show(); this.text && this.text.show(); this.subtitleText && this.subtitleText.show(); this.setState(this.model); } - hide() { + hideMode() { this.control && this.control.hide(); this.text && this.text.hide(); this.subtitleText && this.subtitleText.hide(); diff --git a/src/jmapNew/shape/GuideLock/index.js b/src/jmapNew/shape/GuideLock/index.js index 57e9bed0d..b95937551 100644 --- a/src/jmapNew/shape/GuideLock/index.js +++ b/src/jmapNew/shape/GuideLock/index.js @@ -136,27 +136,27 @@ export default class GuideLock extends Group { const showMode = this.model.showMode; const showConditions = this.style.GuideLock.displayCondition; if (!showConditions || showConditions === '01' || showMode === showConditions) { - this.show(); + this.showMode(); } else { - this.hide(); + this.hideMode(); } } setShowStation(stationCode) { if (!stationCode || this.model.stationCode === stationCode) { this.isShowShape = true; - this.show(); + this.showMode(); } else { this.isShowShape = false; - this.hide(); + this.hideMode(); } } - show() { + showMode() { this.control && this.control.show(); this.text && this.text.show(); this.subtitleText && this.subtitleText.show(); this.setState(this.model); } - hide() { + hideMode() { this.control && this.control.hide(); this.text && this.text.hide(); this.subtitleText && this.subtitleText.hide(); From fd302bbbdd64ffca3e4a4721434294f75abdece7 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Mon, 23 Mar 2020 11:09:40 +0800 Subject: [PATCH 02/14] =?UTF-8?q?=E5=8C=97=E4=BA=AC=E4=B8=80=E5=8F=B7?= =?UTF-8?q?=E7=BA=BF=E6=8E=A7=E5=88=B6=E6=9D=83=E6=93=8D=E4=BD=9C=E4=BB=A3?= =?UTF-8?q?=E7=A0=81=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../childDialog/twoConfirmation.vue | 16 ++++++------- .../menus/menuDialog/stationControl.vue | 24 +++++++++++-------- 2 files changed, 22 insertions(+), 18 deletions(-) diff --git a/src/jmapNew/theme/beijing_01/menus/menuDialog/childDialog/twoConfirmation.vue b/src/jmapNew/theme/beijing_01/menus/menuDialog/childDialog/twoConfirmation.vue index d1560b910..4a70d12b3 100644 --- a/src/jmapNew/theme/beijing_01/menus/menuDialog/childDialog/twoConfirmation.vue +++ b/src/jmapNew/theme/beijing_01/menus/menuDialog/childDialog/twoConfirmation.vue @@ -32,6 +32,7 @@ + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/cancelAllLimit.vue b/src/jmapNew/theme/foshan_01/menus/dialog/cancelAllLimit.vue new file mode 100644 index 000000000..7cd1a50ad --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/cancelAllLimit.vue @@ -0,0 +1,370 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/childDialog/noticeInfo.vue b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/childDialog/noticeInfo.vue new file mode 100644 index 000000000..444a28d5f --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/childDialog/noticeInfo.vue @@ -0,0 +1,77 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmControl.vue new file mode 100644 index 000000000..0569c806c --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmControl.vue @@ -0,0 +1,280 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmControlSpeed.vue b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmControlSpeed.vue new file mode 100644 index 000000000..a73f00076 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmControlSpeed.vue @@ -0,0 +1,153 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmSignalUnlock.vue b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmSignalUnlock.vue new file mode 100644 index 000000000..d192cb895 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmSignalUnlock.vue @@ -0,0 +1,118 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmTip.vue b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmTip.vue new file mode 100644 index 000000000..6f4ea89d7 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/confirmTip.vue @@ -0,0 +1,68 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/popupAlarm.vue b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/popupAlarm.vue new file mode 100644 index 000000000..98cfc9f16 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/popupAlarm.vue @@ -0,0 +1,89 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/routeControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/routeControl.vue new file mode 100644 index 000000000..3a8026e76 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/routeControl.vue @@ -0,0 +1,241 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/routeDetail.vue b/src/jmapNew/theme/foshan_01/menus/dialog/routeDetail.vue new file mode 100644 index 000000000..fa74d117a --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/routeDetail.vue @@ -0,0 +1,168 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/routeHandControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/routeHandControl.vue new file mode 100644 index 000000000..aae0336b8 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/routeHandControl.vue @@ -0,0 +1,341 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/routeLock.vue b/src/jmapNew/theme/foshan_01/menus/dialog/routeLock.vue new file mode 100644 index 000000000..3521fb45a --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/routeLock.vue @@ -0,0 +1,171 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/routeSelection.vue b/src/jmapNew/theme/foshan_01/menus/dialog/routeSelection.vue new file mode 100644 index 000000000..282ff6974 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/routeSelection.vue @@ -0,0 +1,219 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/routeUnLock.vue b/src/jmapNew/theme/foshan_01/menus/dialog/routeUnLock.vue new file mode 100644 index 000000000..fea19772d --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/routeUnLock.vue @@ -0,0 +1,287 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/routerCommand.vue b/src/jmapNew/theme/foshan_01/menus/dialog/routerCommand.vue new file mode 100644 index 000000000..1bdf8dbcd --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/routerCommand.vue @@ -0,0 +1,148 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/sectionAlxeReset.vue b/src/jmapNew/theme/foshan_01/menus/dialog/sectionAlxeReset.vue new file mode 100644 index 000000000..33a16f85a --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/sectionAlxeReset.vue @@ -0,0 +1,157 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/sectionControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/sectionControl.vue new file mode 100644 index 000000000..9e1e4176c --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/sectionControl.vue @@ -0,0 +1,207 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/sectionUnLock.vue b/src/jmapNew/theme/foshan_01/menus/dialog/sectionUnLock.vue new file mode 100644 index 000000000..730534019 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/sectionUnLock.vue @@ -0,0 +1,327 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/speedLimitControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/speedLimitControl.vue new file mode 100644 index 000000000..8c81c5fe0 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/speedLimitControl.vue @@ -0,0 +1,551 @@ + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standBackStrategy.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standBackStrategy.vue new file mode 100644 index 000000000..4b097fd5d --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standBackStrategy.vue @@ -0,0 +1,229 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standBulkBuckleTrain.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standBulkBuckleTrain.vue new file mode 100644 index 000000000..48be045ef --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standBulkBuckleTrain.vue @@ -0,0 +1,279 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standControl.vue new file mode 100644 index 000000000..c190c9c29 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standControl.vue @@ -0,0 +1,438 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standDetail.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standDetail.vue new file mode 100644 index 000000000..b1d6c726b --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standDetail.vue @@ -0,0 +1,278 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standJumpStopControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standJumpStopControl.vue new file mode 100644 index 000000000..e4926cc57 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standJumpStopControl.vue @@ -0,0 +1,355 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standRunLevel.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standRunLevel.vue new file mode 100644 index 000000000..1ba1899b3 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standRunLevel.vue @@ -0,0 +1,333 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standStopTime.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standStopTime.vue new file mode 100644 index 000000000..d0ec86339 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standStopTime.vue @@ -0,0 +1,242 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/stationCmdControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/stationCmdControl.vue new file mode 100644 index 000000000..42f8e9a05 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/stationCmdControl.vue @@ -0,0 +1,388 @@ + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/stationControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/stationControl.vue new file mode 100644 index 000000000..47473fd91 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/stationControl.vue @@ -0,0 +1,253 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/stationHumanControlAll.vue b/src/jmapNew/theme/foshan_01/menus/dialog/stationHumanControlAll.vue new file mode 100644 index 000000000..ab2d6b445 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/stationHumanControlAll.vue @@ -0,0 +1,127 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/stationSetRouteControlAll.vue b/src/jmapNew/theme/foshan_01/menus/dialog/stationSetRouteControlAll.vue new file mode 100644 index 000000000..61ae8dab8 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/stationSetRouteControlAll.vue @@ -0,0 +1,146 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/switchControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/switchControl.vue new file mode 100644 index 000000000..ee131b501 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/switchControl.vue @@ -0,0 +1,279 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/switchUnLock.vue b/src/jmapNew/theme/foshan_01/menus/dialog/switchUnLock.vue new file mode 100644 index 000000000..382f23406 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/switchUnLock.vue @@ -0,0 +1,322 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainAddPlan.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainAddPlan.vue new file mode 100644 index 000000000..340fbf9a9 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainAddPlan.vue @@ -0,0 +1,228 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainDefine.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainDefine.vue new file mode 100644 index 000000000..821001381 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainDefine.vue @@ -0,0 +1,180 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainDelete.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainDelete.vue new file mode 100644 index 000000000..9d969581d --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainDelete.vue @@ -0,0 +1,168 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainDeletePlan.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainDeletePlan.vue new file mode 100644 index 000000000..bcd707893 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainDeletePlan.vue @@ -0,0 +1,165 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainEdit.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainEdit.vue new file mode 100644 index 000000000..3f663a94a --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainEdit.vue @@ -0,0 +1,180 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainFlag.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainFlag.vue new file mode 100644 index 000000000..a0fe79a5e --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainFlag.vue @@ -0,0 +1,159 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainMove.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainMove.vue new file mode 100644 index 000000000..fca33d07b --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainMove.vue @@ -0,0 +1,180 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainMoveEvently.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainMoveEvently.vue new file mode 100644 index 000000000..11083a3d9 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainMoveEvently.vue @@ -0,0 +1,185 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainSetHead.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainSetHead.vue new file mode 100644 index 000000000..35cfbb7b8 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainSetHead.vue @@ -0,0 +1,180 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainSetPlan.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainSetPlan.vue new file mode 100644 index 000000000..8cdce8cf5 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainSetPlan.vue @@ -0,0 +1,173 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainSetWork.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainSetWork.vue new file mode 100644 index 000000000..baafc7f25 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainSetWork.vue @@ -0,0 +1,164 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/trainSetWorkATP.vue b/src/jmapNew/theme/foshan_01/menus/dialog/trainSetWorkATP.vue new file mode 100644 index 000000000..756dc9bc2 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/trainSetWorkATP.vue @@ -0,0 +1,175 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/turnBackControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/turnBackControl.vue new file mode 100644 index 000000000..22e1e6c62 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/turnBackControl.vue @@ -0,0 +1,179 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/index.vue b/src/jmapNew/theme/foshan_01/menus/index.vue new file mode 100644 index 000000000..e80fc73b5 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/index.vue @@ -0,0 +1,391 @@ + + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuAutoTrunRoute.vue b/src/jmapNew/theme/foshan_01/menus/menuAutoTrunRoute.vue new file mode 100644 index 000000000..f117a8d22 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuAutoTrunRoute.vue @@ -0,0 +1,144 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuAxleReset.vue b/src/jmapNew/theme/foshan_01/menus/menuAxleReset.vue new file mode 100644 index 000000000..1237a53ae --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuAxleReset.vue @@ -0,0 +1,108 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuBar.vue b/src/jmapNew/theme/foshan_01/menus/menuBar.vue new file mode 100644 index 000000000..981eb25f5 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuBar.vue @@ -0,0 +1,1132 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuButton.vue b/src/jmapNew/theme/foshan_01/menus/menuButton.vue new file mode 100644 index 000000000..9c58482f7 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuButton.vue @@ -0,0 +1,389 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuCancel.vue b/src/jmapNew/theme/foshan_01/menus/menuCancel.vue new file mode 100644 index 000000000..69031a452 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuCancel.vue @@ -0,0 +1,119 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/twoConfirmation.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/twoConfirmation.vue new file mode 100644 index 000000000..cb364d3a1 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/twoConfirmation.vue @@ -0,0 +1,120 @@ + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userAdd.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userAdd.vue new file mode 100644 index 000000000..eac2e8cea --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userAdd.vue @@ -0,0 +1,162 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userDelete.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userDelete.vue new file mode 100644 index 000000000..243fe7ec2 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userDelete.vue @@ -0,0 +1,134 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userEdit.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userEdit.vue new file mode 100644 index 000000000..33d38059f --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/childDialog/userEdit.vue @@ -0,0 +1,178 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/detainTrainContorl.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/detainTrainContorl.vue new file mode 100644 index 000000000..d1866d269 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/detainTrainContorl.vue @@ -0,0 +1,192 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/detainTrainContorlUpDown.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/detainTrainContorlUpDown.vue new file mode 100644 index 000000000..ab5a392ab --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/detainTrainContorlUpDown.vue @@ -0,0 +1,183 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/helpAbout.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/helpAbout.vue new file mode 100644 index 000000000..0348a0cd8 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/helpAbout.vue @@ -0,0 +1,131 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/manageUser.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/manageUser.vue new file mode 100644 index 000000000..6c22ac606 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/manageUser.vue @@ -0,0 +1,290 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/stationControl.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/stationControl.vue new file mode 100644 index 000000000..a326e4233 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/stationControl.vue @@ -0,0 +1,237 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/trainAdd.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/trainAdd.vue new file mode 100644 index 000000000..d6e7647f4 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/trainAdd.vue @@ -0,0 +1,162 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/trainDelete.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/trainDelete.vue new file mode 100644 index 000000000..529f2df33 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/trainDelete.vue @@ -0,0 +1,149 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/trainTranstalet.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/trainTranstalet.vue new file mode 100644 index 000000000..0dc10a6f7 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/trainTranstalet.vue @@ -0,0 +1,152 @@ + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/menuLimit.vue b/src/jmapNew/theme/foshan_01/menus/menuLimit.vue new file mode 100644 index 000000000..c1e1b60d1 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuLimit.vue @@ -0,0 +1,119 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuSection.vue b/src/jmapNew/theme/foshan_01/menus/menuSection.vue new file mode 100644 index 000000000..8a2e150b6 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuSection.vue @@ -0,0 +1,295 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuSignal.vue b/src/jmapNew/theme/foshan_01/menus/menuSignal.vue new file mode 100644 index 000000000..23a018b2d --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuSignal.vue @@ -0,0 +1,531 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuStation.vue b/src/jmapNew/theme/foshan_01/menus/menuStation.vue new file mode 100644 index 000000000..81b2a52f3 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuStation.vue @@ -0,0 +1,306 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuStationControl.vue b/src/jmapNew/theme/foshan_01/menus/menuStationControl.vue new file mode 100644 index 000000000..72b195cce --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuStationControl.vue @@ -0,0 +1,142 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue b/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue new file mode 100644 index 000000000..a104fb3b6 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue @@ -0,0 +1,463 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuSwitch.vue b/src/jmapNew/theme/foshan_01/menus/menuSwitch.vue new file mode 100644 index 000000000..6a2b247a9 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuSwitch.vue @@ -0,0 +1,410 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuTool.vue b/src/jmapNew/theme/foshan_01/menus/menuTool.vue new file mode 100644 index 000000000..266a43165 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuTool.vue @@ -0,0 +1,202 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuTrain.vue b/src/jmapNew/theme/foshan_01/menus/menuTrain.vue new file mode 100644 index 000000000..7d7fff421 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/menuTrain.vue @@ -0,0 +1,511 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/passiveDialog/alarm.vue b/src/jmapNew/theme/foshan_01/menus/passiveDialog/alarm.vue new file mode 100644 index 000000000..3fb293056 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/passiveDialog/alarm.vue @@ -0,0 +1,213 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/passiveDialog/control.vue b/src/jmapNew/theme/foshan_01/menus/passiveDialog/control.vue new file mode 100644 index 000000000..8beb7267a --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/passiveDialog/control.vue @@ -0,0 +1,285 @@ + + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/passiveDialog/timeout.vue b/src/jmapNew/theme/foshan_01/menus/passiveDialog/timeout.vue new file mode 100644 index 000000000..448e6b232 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/passiveDialog/timeout.vue @@ -0,0 +1,106 @@ + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/utils/menuItemStatus.js b/src/jmapNew/theme/foshan_01/menus/utils/menuItemStatus.js new file mode 100644 index 000000000..dada7aa32 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/utils/menuItemStatus.js @@ -0,0 +1,570 @@ +import Vue from 'vue'; +import store from '@/store'; +import deviceState from '@/jmap/constant/deviceState'; +import { OperateMode } from '@/scripts/ConstDic'; + +export function getCurrentStateObject() { + return store.getters['menuOperation/selected']; +} + +/** 系统类型 */ +export const SystemType = { + '01': 'local', // 现地工作站 + '02': 'central' // 中心调度工作站 +}; + +export const StationControlType = { + '01': 'center', // 中控 + '02': 'station' // 站控 +}; + +// 控制禁用 +export const MenuDisabledState = { + Section: { + // 故障解锁 + fault() { + }, + // 切除 + split() { + const device = getCurrentStateObject(); + if (device && device.cutOff != deviceState.Section.cutOff.Default) { + return true; + } + }, + // 激活 + active() { + const device = getCurrentStateObject(); + if (device && device.cutOff == deviceState.Section.cutOff.Default) { + return true; + } + }, + // 区段封锁 + lock() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.Section.status.State06) { + return true; + } + }, + // 区段解禁 + unlock() { + const device = getCurrentStateObject(); + if (device && device.status != deviceState.Section.status.State06) { + return true; + } + }, + // 区段设置限速 + setSpeed() { + }, + // 区段取消限速 + cancelSpeed() { + const device = getCurrentStateObject(); + if (device && device.speedUpperLimit == deviceState.Section.speedUpperLimit.Default) { + return true; + } + }, + // 新建列车 + newTrain() { + }, + // 计轴预复位 + axlePreReset() { + }, + // 设置计轴有效 + alxeEffective() { + }, + // 设置计轴失效 + alxeFailure() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.Section.status.State13) { + return true; + } + } + }, + Signal: { + // 进路选排 + arrangementRoute() { + + }, + // 进路取消 + cancelTrainRoute() { + }, + // 信号封闭 + lock() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.Signal.status.State05) { + return true; + } + }, + // 信号解封 + unlock() { + const device = getCurrentStateObject(); + if (device && device.status != deviceState.Signal.status.State05) { + return true; + } + }, + // 信号重开 + reopenSignal() { + }, + // 进路引导 + guide() { + }, + // 设置联锁自动进路 + setAutoInterlock() { + }, + // 取消联锁自动进路 + cancelAutoInterlock() { + }, + // 设置联锁自动触发 + setAutoTrigger() { + }, + // 取消联锁自动触发 + cancelAutoTrigger() { + }, + // 关灯 + signalClose() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.Signal.status.State01) { + return true; + } + }, + // 人工控 + humanControl() { + }, + // ats自动控 + atsAutoControl() { + }, + // 查询进路状态 + detail() { + }, + // 设置故障 + setStoppage() { + const device = getCurrentStateObject(); + if (device && device.fault) { + return true; + } + }, + // 取消故障 + cancelStoppage() { + const device = getCurrentStateObject(); + if (device && !device.fault) { + return true; + } + } + }, + Station: { + // 全站设置联锁自动触发 + setAutoTrigger() { + }, + // 全站取消联锁自动触发 + cancelAutoTrigger() { + }, + // 上电解锁 + powerUnLock() { + }, + // 执行关键操作测试 + execKeyOperationTest() { + }, + // 所有进路自排开 + atsAutoControlALL() { + }, + // 所有进路自排关 + humanControlALL() { + }, + // 设置ZC故障 + setStoppage() { + const device = getCurrentStateObject(); + if (device && device.fault) { + return true; + } + }, + // 取消ZC故障 + cancelStoppage() { + const device = getCurrentStateObject(); + if (device && !device.fault) { + return true; + } + } + }, + StationControl: { + // 紧急站控 + emergencyStationControl() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.StationControl.status.State03) { + return true; + } + }, + // 请求站控 + requestStationControl() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.StationControl.status.State02) { + return true; + } + }, + // 强行站控 + forcedStationControl() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.StationControl.status.State02) { + return true; + } + }, + // 请求中控 + requestCentralControl() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.StationControl.status.State01) { + return true; + } + }, + // 设置故障 + setStoppage() { + const device = getCurrentStateObject(); + if (device && device.fault) { + return true; + } + }, + // 取消故障 + cancelStoppage() { + const device = getCurrentStateObject(); + if (device && !device.fault) { + return true; + } + } + }, + StationStand: { + // 设置扣车 + setDetainTrain() { + const device = getCurrentStateObject(); + if (device && device.holdStatus != deviceState.StationStand.holdStatus.State01) { + return true; + } + }, + // 取消扣车 + cancelDetainTrain() { + const device = getCurrentStateObject(); + if (device && device.holdStatus == deviceState.StationStand.holdStatus.State01) { + return true; + } + }, + // 强制取消扣车 + cancelDetainTrainForce() { + const device = getCurrentStateObject(); + if (device && device.holdStatus == deviceState.StationStand.holdStatus.State01) { + return true; + } + }, + // 设置全站扣车 + cancelDetainTrainAll() { + }, + // 设置运行等级 + setRunLevel() { + }, + // 设置停站时间 + setStopTime() { + }, + // 设置跳停 + setJumpStop() { + const device = getCurrentStateObject(); + if (device && device.jumpStopStatus != deviceState.StationStand.jumpStopStatus.State01) { + return true; + } + }, + // 取消跳停 + cancelJumpStop() { + const device = getCurrentStateObject(); + if (device && device.jumpStopStatus == deviceState.StationStand.jumpStopStatus.State01) { + return true; + } + }, + // 提前发车 + earlyDeparture() { + }, + // 站台详细信息 + detail() { + }, + // 设置折返策略 + setBackStrategy() { + }, + // 设置故障 + setStoppage() { + const device = getCurrentStateObject(); + if (device && device.fault) { + return true; + } + }, + // 取消故障 + cancelStoppage() { + const device = getCurrentStateObject(); + if (device && !device.fault) { + return true; + } + } + }, + Switch: { + // 单锁 + lock() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.Switch.status.State10) { + return true; + } + }, + // 解锁 + unlock() { + const device = getCurrentStateObject(); + if (device && device.status != deviceState.Switch.status.State10) { + return true; + } + }, + // 封锁 + block() { + const device = getCurrentStateObject(); + if (device && device.status == deviceState.Switch.status.State14) { + return true; + } + }, + // 解封 + unblock() { + const device = getCurrentStateObject(); + if (device && device.status != deviceState.Switch.status.State14) { + return true; + } + }, + // 强扳 + switchTurnoutForce() { + }, + // 转动 + switchTurnout() { + }, + // 道岔故障解锁 + fault() { + }, + // 计轴预复位 + axlePreReset() { + }, + // 道岔切除 + split() { + }, + // 道岔激活 + active() { + }, + // 道岔设置速度 + setSpeed() { + // const device = getCurrentStateObject(); + }, + // 设置计轴有效 + alxeEffective() { + }, + // 道岔取消速度 + cancelSpeed() { + }, + // 设置故障 + setStoppage() { + const device = getCurrentStateObject(); + if (device && device.fault) { + return true; + } + }, + // 取消故障 + cancelStoppage() { + const device = getCurrentStateObject(); + if (device && !device.fault) { + return true; + } + } + }, + Train: { + // 添加列车识别号 + addTrainId() { + }, + // 删除列车识别号 + delTrainId() { + }, + // 修改列车识别号 + editTrainId() { + }, + // 修改车组号 + editTrainNo() { + }, + // 移动列车识别号 + moveTrainId() { + }, + // 交换列车识别号 + switchTrainId() { + }, + // 设置限速 + limitSpeed() { + }, + // 设置通信故障 + setStoppage() { + const device = getCurrentStateObject(); + if (device && device.fault) { + return true; + } + }, + // 取消通信故障 + cancelStoppage() { + const device = getCurrentStateObject(); + if (device && !device.fault) { + return true; + } + }, + // 添加计划车 + addPlanTrain() { + }, + // 设置计划车 + setPlanTrain() { + }, + // 设置头码车 + setHeadTrain() { + }, + // 设置人工车 + setWorkTrain() { + }, + // 标记重点车 + trainToFlag() { + }, + // 取消标记重点车 + trainUnFlag() { + } + } +}; + +/** + * 将menu的disabled属性使用disabledCallback计算并返回 + * @param {Array} menu + */ +export function menuConvert(menu) { + if (menu.constructor === Array) { + menu.forEach(elem => { + if (elem.type === 'separator') { + elem.show = true; + return; + } + if (elem.disabledCallback.constructor === Function) { + if (!elem.defaultDisabled) { + elem.disabled = elem.disabledCallback(); + } + } + }); + } + return menu; +} + +/** + * 根据产品类型,返回对应的menuBar + * @param {*} menuObj + */ +export function menuBarConvert(menu, mode) { + if (menu) { + if (mode === OperateMode.NORMAL) { + menu.forEach(item => { + if (item.type === 'separator') { + item.show = true; + return; + } + + item.show = false; + if (!item.click) { + item.click = () => { }; + } + + if (!item.froce) { + item.show = true; + if (item.children && item.children.length > 0) { + menuBarConvert(item.children, mode); + } + } + }); + } else if (mode === OperateMode.ADMIN) { + menu.forEach(item => { + item.show = true; + if (!item.click) { + item.click = () => { }; + } + if (item.children && item.children.length > 0) { + menuBarConvert(item.children, mode); + } + }); + } + } + return menu || []; +} + +/** + * 将menu的show属性过滤返回 + * @param {Array} menu + */ +export function menuFiltration(menuObj) { + var selected = getCurrentStateObject(); + var control; + var menu = []; + + if (selected._type == 'StationStand') { + control = store.getters['map/getStationControlByStationCode'](selected.deviceStationCode); + } else if (selected._type == 'Station') { + control = store.getters['map/getStationControlByStationCode'](selected.code); + } else { + control = store.getters['map/getStationControlByStationCode'](selected.stationCode); + } + + if (control) { + if (store.state.training.prdType != '') { + const type = SystemType[store.state.training.prdType]; + const status = StationControlType[control.status]; + menu = [...menuObj[type]]; + if (menu.constructor === Array) { + menu.forEach(elem => { + if (elem.type === 'separator') { + elem.show = true; + return; + } + + if (elem.auth.constructor === Object) { + elem.show = true; + if (!elem.auth['station'] && !elem.auth['center']) { // 控制不显示 + elem.show = false; + } + elem.defaultDisabled = !elem.auth[status]; + } + }); + } + } + } + return menu; +} + +/** + * 将train menu的show属性过滤返回 + */ +export function trainMenuFiltration(menuObj) { + var menu = []; + if (store.state.training.prdType != '') { + const type = SystemType[store.state.training.prdType]; + menu = [...menuObj[type]]; + if (menu.constructor === Array) { + menu.forEach(elem => { + if (elem.type === 'separator') { + elem.show = true; + return; + } + + if (elem.auth.constructor === Object) { + elem.show = true; + if (!elem.auth['station'] && !elem.auth['center']) { // 控制不显示 + elem.show = false; + } + } + }); + } + } + return menu; +} + +/** + * 离开菜单以及执行完菜单取消选中状态 + */ +export function mouseCancelState(selected) { + const device = Vue.prototype.$jlmap.getDeviceByCode(selected.code); + const instance = (device || {}).instance; + if (instance && instance.mouseEvent && instance.mouseEvent.mouseout) { + device['down'] = false; + instance.mouseEvent.mouseout(Vue.prototype.$jlmap.$zr.curEvent); + } +} diff --git a/src/jmapNew/theme/foshan_01/menusPlan/addTask.vue b/src/jmapNew/theme/foshan_01/menusPlan/addTask.vue new file mode 100644 index 000000000..cf092b0ca --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/addTask.vue @@ -0,0 +1,175 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/chooseTemplatePlan.vue b/src/jmapNew/theme/foshan_01/menusPlan/chooseTemplatePlan.vue new file mode 100644 index 000000000..f9ea0760d --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/chooseTemplatePlan.vue @@ -0,0 +1,115 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/components/dataTable.vue b/src/jmapNew/theme/foshan_01/menusPlan/components/dataTable.vue new file mode 100644 index 000000000..fa98a48e7 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/components/dataTable.vue @@ -0,0 +1,206 @@ + + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/createTodayPlan.vue b/src/jmapNew/theme/foshan_01/menusPlan/createTodayPlan.vue new file mode 100644 index 000000000..27e3513d2 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/createTodayPlan.vue @@ -0,0 +1,134 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/createWeekPlan.vue b/src/jmapNew/theme/foshan_01/menusPlan/createWeekPlan.vue new file mode 100644 index 000000000..48f65d60f --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/createWeekPlan.vue @@ -0,0 +1,137 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/deleteTask.vue b/src/jmapNew/theme/foshan_01/menusPlan/deleteTask.vue new file mode 100644 index 000000000..035f23fca --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/deleteTask.vue @@ -0,0 +1,73 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/deleteTodayPlan.vue b/src/jmapNew/theme/foshan_01/menusPlan/deleteTodayPlan.vue new file mode 100644 index 000000000..3110e2858 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/deleteTodayPlan.vue @@ -0,0 +1,62 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/managePlanList.vue b/src/jmapNew/theme/foshan_01/menusPlan/managePlanList.vue new file mode 100644 index 000000000..034b461b6 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/managePlanList.vue @@ -0,0 +1,143 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/modifyingPlan.vue b/src/jmapNew/theme/foshan_01/menusPlan/modifyingPlan.vue new file mode 100644 index 000000000..a9d25ea80 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/modifyingPlan.vue @@ -0,0 +1,177 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/menusPlan/modifyingTask.vue b/src/jmapNew/theme/foshan_01/menusPlan/modifyingTask.vue new file mode 100644 index 000000000..194534120 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menusPlan/modifyingTask.vue @@ -0,0 +1,327 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/model.js b/src/jmapNew/theme/foshan_01/model.js new file mode 100644 index 000000000..62440bda8 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/model.js @@ -0,0 +1,63 @@ +import deviceType from '../../constant/deviceType'; + +class Model { + constructor() { + // 公共字段部分默认初始值 + this['public'] = {}; + this['public'][deviceType.Signal] = { + lampPositionType: '02', + lampPostType: '02' + }; + + // 私有字段部分默认初始值 + this['private'] = {}; + this['private'][deviceType.StationControl] = { + indicatorShow: true // 标识灯名称显示 + }; + this['private'][deviceType.Section] = { + borderBorderShow: true, // 区段边界显示 + standTrackNameShow: true, // 站台轨名称显示 + reentryTrackNameShow: true, // 折返轨名称显示 + transferTrackNameShow: true // 转换轨名称显示 + }; + this['private'][deviceType.Signal] = { + linkageAutoRouteShow: true, // 联锁自动进路表示灯显示 + atsAutoTriggerShow: true // ATS自动触发表示灯显示 + }; + this['private'][deviceType.Train] = { + nameFormat: 'targetCode:serviceNumber:tripNumber', // 字体格式 + nameFontSize: 10 // 字体大小 + }; + this['private'][deviceType.TrainWindow] = { + trainWindowShow: true + }; + } + + initPublicProps(model) { + if (model) { + var modelInitial = this.public[model._type]; + if (modelInitial) { + for (var prop in modelInitial) { + model[prop] = modelInitial[prop]; + } + } + } + + return model; + } + + initPrivateProps(model) { + if (model) { + var modelInitial = this.private[model._type]; + if (modelInitial) { + for (var prop in modelInitial) { + model[prop] = modelInitial[prop]; + } + } + } + + return model; + } +} + +export default new Model(); diff --git a/src/jmapNew/theme/foshan_01/planConvert.js b/src/jmapNew/theme/foshan_01/planConvert.js new file mode 100644 index 000000000..8f2fc6dc3 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/planConvert.js @@ -0,0 +1,334 @@ +import { createMartPoint, createSeriesModel, createMarkLineModels, hexColor, convertSheetToList, prefixTime } from '@/utils/runPlan'; + +export default { + /** 边缘高度*/ + EdgeHeight: 600, + + /** 间隔高度*/ + CoordMultiple: 1, + + /** 偏移时间*/ + TranslationTime: 60 * 60 * 2, + + /** excel解析配置*/ + ExcelConfig: { + beginRow: 1, + beginCol: 0, + fieldNum: 10, + sepField: '行车间隔', + trainId: 'TrainID', + columns: ['折返线', 'TrainID', '行车间隔'] + }, + + /** 解析exal数据转换为Json后台数据*/ + importData(Sheet, JsonData) { + var dataList = convertSheetToList(Sheet, true); + if (dataList && dataList.length) { + if (dataList && dataList.length && dataList[1] && dataList[0]) { + // const tIndex = dataList.findIndex(it => { return it[0]; }); // 设置不用过滤行数 + const tIndex = 9; // 设置不用过滤行数 + + /** 解析二维数组为json对象*/ + const reg3 = /^(\d+:\d+:\d+|)/; // 06:12:00 + dataList.forEach((elem, i) => { + var begin = -1; + /** 跳过名称所在的行*/ + if (i != tIndex && elem && elem.length > 0) { + let flag = false; + let count = 0; + let param = { begTime: '', endTime: '' }; + if (i > tIndex) { elem.reverse(); } + elem.forEach((item, j) => { + /** 过滤空值*/ + if (item) { + let title = ''; + var value = `${item}`.trim(); + if (i > tIndex) { // 上行线 + title = `${dataList[tIndex][dataList[tIndex].length - j - 1]}`.replace(/\s*/g, ''); + if (title == 'undefined') { + title = `${dataList[tIndex][dataList[tIndex].length - j - 2]}`.replace(/\s*/g, ''); + } + } else { // 下行线 + title = `${dataList[tIndex][j]}`.replace(/\s*/g, ''); + if (title == 'undefined') { + title = `${dataList[tIndex][j - 1]}`.replace(/\s*/g, ''); + } + } + + /** 匹配到开始位置或者结束位置*/ + if (title == this.ExcelConfig.trainId) { + if (begin == -1) { + flag = true; + begin = value; // 设置初始索引 + JsonData.push({ + code: value, + destinationCode: '', + arrivalList: [] + }); + } else if (flag) { + begin = -1; // 清空初始索引 + JsonData[JsonData.length - 1].destinationCode = value; + flag = false; + } + } else if (begin !== -1) { + /** 匹配到中间位置*/ + var stationName = title.replace(/\s/, ''); + if (this.ExcelConfig.columns.indexOf(stationName) == -1 && reg3.test(value)) { + let need = false; + if (value.split(':')[0] == '24') { // 24:XX:XX 类似这种数据 变24为00 + const arr = value.split(':'); + arr[0] = '00'; + value = arr.join(':'); + } + if (count == 1) { + count = 0; + param.endTime = value; + } + if (count == 0) { + count = 1; + param.begTime = param.begTime || value; + } + + if (param.begTime && param.endTime) { + need = true; + } + + /** 添加json数据*/ + if (need) { // 储存非空 数据 + var stationObj = { + stationName: stationName + }; + stationObj['arriveTime'] = prefixTime(param.begTime); + stationObj['departureTime'] = prefixTime(param.endTime); + JsonData[JsonData.length - 1].arrivalList.push(stationObj); + param = { begTime: '', endTime: '' }; + count = 0; + } + } + } + } + }); + } + }); + } + } + return JsonData; + }, + + /** 将后台数据解析成图表*/ + convertDataToModels(data, stations, kmRangeCoordMap, lineStyle) { + var models = []; + if (data && data.serviceNumberDataList && data.serviceNumberDataList.length) { + /** 按服务遍历数据*/ + data.serviceNumberDataList.forEach((service) => { + /** 按车次遍历数据*/ + var opt = { name: '', markPointData: [], data: [] }; + if (service.tripNumberDataList && service.tripNumberDataList.length) { + service.tripNumberDataList.forEach((train, j) => { + var pointdata = {}; + var idx = 0; + var num = 0; + var lastPoint = null; + var nextPoint = null; + + /** 如果车次号为空,不显示名称*/ + if (train.tripNumber) { + /** 创建标记点名称和坐标*/ + pointdata.name = `${service.serviceNumber}${train.directionCode}${train.tripNumber}`; + pointdata.color = '#000' || lineStyle.color; + pointdata.directionCode = train.directionCode; + pointdata.coord = [train.stationTimeList[1].secondTime, this.getCoordYByElem(stations, kmRangeCoordMap, train.stationTimeList[1], train.directionCode, false)]; + + /** 给服务对象添加服务名称和标记点*/ + opt.markPointData.push(createMartPoint(pointdata)); + /** 创建服务号名称*/ + opt.name = `${service.serviceNumber}`; + } + + /** 计算非折返点车次点坐标集合*/ + train.stationTimeList.forEach((elem, index) => { + idx = index; + if (index == 0 && train.stationTimeList[index].stationCode != train.stationTimeList[index + 1].stationCode || + index == train.stationTimeList.length - 2 && train.stationTimeList[index].secondTime != train.stationTimeList[index + 1].secondTime || + index > 0 && index < train.stationTimeList.length - 1) { + const aa = `${train.directionCode}${train.tripNumber}`; + opt.data.push([elem.secondTime, this.getCoordYByElem(stations, kmRangeCoordMap, elem, elem.directionCode, false), elem.stationCode, aa]); + } + }); + + /** 计算折返点车次坐标点集合*/ + if (!train.backup && train.reentry && service.tripNumberDataList[j + 1] && service.tripNumberDataList[j + 1].stationTimeList) { + lastPoint = train.stationTimeList[idx - 1]; + nextPoint = service.tripNumberDataList[j + 1].stationTimeList[1]; + num = this.computedReentryNumber(train.tripNumber); + opt.data.push([lastPoint.secondTime, this.getCoordYByElem(stations, kmRangeCoordMap, lastPoint, train.directionCode, true, num), lastPoint.stationCode]); + opt.data.push([nextPoint.secondTime, this.getCoordYByElem(stations, kmRangeCoordMap, nextPoint, train.directionCode, true, num), nextPoint.stationCode]); + } + + /** 如果是备用车,按车次添加线*/ + if (train.backup) { + /** 创建一条完成的服务数据*/ + opt.name += j; + var model = createSeriesModel(opt, Object.assign({ color: hexColor.toCreate() }, lineStyle)); + if (model) { + models.push(model); + opt = { name: '', markPointData: [], data: [] }; + } + } + }); + + // 不是备用车,按服务添加线 + if (!service.backup) { + /** 创建一条完成的服务数据*/ + var model = createSeriesModel(opt, Object.assign({ color: hexColor.toCreate() }, lineStyle)); + if (model) { + models.push(model); + } + } + } + }); + return models; + } else { + return []; + } + }, + + /** 更新数据并解析成图表*/ + updateDataToModels(data, stations, kmRangeCoordMap, runPlanData, series, lineStyle) { + if (data && data.length) { + data.forEach(elem => { + /** 判断此条记录的服务号是否存在*/ + if (!runPlanData[elem.serviceNumber]) { + /** 创建一个新服务号标记*/ + runPlanData[elem.serviceNumber] = {}; + /** 不存在此服务号,则需要创建一条新的line*/ + series.push(createSeriesModel({ + zlevel: 1, + name: `run${elem.serviceNumber}`, + data: [], + markPointData: [] + }, Object.assign({ color: hexColor.toCreate() }, lineStyle))); + } + + /** 添加数据*/ + series.forEach(serie => { + /** 找到服务号所在图数据的位置*/ + if (serie.name == `run${elem.serviceNumber}`) { + /** 添加车组号记录标记*/ + if (!runPlanData[elem.serviceNumber][elem.tripNumber]) { + runPlanData[elem.serviceNumber][elem.tripNumber] = []; + } + + runPlanData[elem.serviceNumber][elem.tripNumber].push(elem); + runPlanData[elem.serviceNumber][elem.tripNumber].sort((a, b) => { + return parseInt(a.secondTime) - parseInt(b.secondTime); + }); + + /** 如果此记录车组号的数据为第一条时,则打上标签*/ + if (runPlanData[elem.serviceNumber][elem.tripNumber].length <= 1) { + serie.markPoint.data.push(createMartPoint({ + directionCode: elem.directionCode, + coord: [parseInt(elem.secondTime), this.getCoordYByElem(stations, kmRangeCoordMap, elem, false)], + name: `(${elem.groupNumber})${elem.serviceNumber}${elem.directionCode}${elem.tripNumber}`, + color: lineStyle.color || '#000' + })); + } + + /** 计算折返点*/ + var nextPoint = [parseInt(elem.secondTime), this.getCoordYByElem(stations, kmRangeCoordMap, elem, false), elem.directionCode]; + if (serie.data.length > 0) { + var lastPoint = serie.data[serie.data.length - 1]; + if (lastPoint[2] !== nextPoint[2]) { + var num = this.computedReentryNumber(elem.tripNumber); + serie.data.push([lastPoint[0], this.getYvalueByDirectionCode(lastPoint[1], lastPoint[2], num), lastPoint[2]]); + serie.data.push([nextPoint[0], this.getYvalueByDirectionCode(nextPoint[1], lastPoint[2], num), lastPoint[2]]); + } + } + + /** 添加车组号数据到对应的服务图数据中*/ + serie.data.push(nextPoint); + + /** 保证原始数据排序*/ + serie.data.sort((a, b) => { + return parseInt(a[0]) - parseInt(b[0]); + }); + } + }); + }); + } + + return series; + }, + + /** 初始化Y轴*/ + initializeYaxis(stations) { + return createMarkLineModels(stations, (elem) => { + return this.EdgeHeight + elem.kmRange * this.CoordMultiple; + }); + }, + + /** 将后台数据转换为试图序列模型*/ + convertStationsToMap(stations) { + var map = {}; + if (stations && stations.length) { + stations.forEach((elem) => { + map[`${elem.kmRange}`] = this.EdgeHeight + elem.kmRange * this.CoordMultiple; + }); + } + + return map; + }, + + /** 计算y轴最小值*/ + computedYaxisMinValue(stations) { + return stations[0].kmRange * this.CoordMultiple; + }, + + /** 计算y轴最大值*/ + computedYaxisMaxValue(stations) { + return stations[stations.length - 1].kmRange * this.CoordMultiple + this.EdgeHeight * 2; + }, + + /** 格式化y轴数据*/ + computedFormatYAxis(stations, params) { + var yText = '0m'; + + stations.forEach(elem => { + if (elem.kmRange < parseInt(params.value) / this.CoordMultiple - this.EdgeHeight) { + yText = Math.floor(elem.kmRange) + 'm'; + } + }); + + return yText; + }, + + /** 根据是否和上一个车次是否相交,计算下一个车次的折返的高度*/ + computedReentryNumber(code) { + return parseInt(code || 1) % 2 ? 1 : 2; + }, + + /** 根据方向计算y折返偏移量*/ + getYvalueByDirectionCode(defaultVlue, directionCode, num) { + if (directionCode === '1') { + defaultVlue -= this.EdgeHeight / 2 * num; + } else if (directionCode === '2') { + defaultVlue += this.EdgeHeight / 2 * num; + } + + return defaultVlue; + }, + + /** 根据elem计算y值*/ + getCoordYByElem(stations, kmRangeCoordMap, elem, directionCode, isSpecial, num) { + var defaultVlue = 0; + var station = stations.find(it => { return it.code == elem.stationCode; }); + if (station) { + defaultVlue = kmRangeCoordMap[`${station.kmRange}`]; + if (isSpecial) { + defaultVlue = this.getYvalueByDirectionCode(defaultVlue, directionCode, num); + } + } + + return defaultVlue; + } +}; diff --git a/src/jmapNew/theme/foshan_01/planSchedule/index.vue b/src/jmapNew/theme/foshan_01/planSchedule/index.vue new file mode 100644 index 000000000..332007bb7 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/planSchedule/index.vue @@ -0,0 +1,403 @@ + + + + + diff --git a/src/jmapNew/theme/foshan_01/planSchedule/menuBar.vue b/src/jmapNew/theme/foshan_01/planSchedule/menuBar.vue new file mode 100644 index 000000000..e64ae3063 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/planSchedule/menuBar.vue @@ -0,0 +1,514 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/planSchedule/menuTool.vue b/src/jmapNew/theme/foshan_01/planSchedule/menuTool.vue new file mode 100644 index 000000000..d3ecde016 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/planSchedule/menuTool.vue @@ -0,0 +1,172 @@ + + + + \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/planSchedule/schedule.vue b/src/jmapNew/theme/foshan_01/planSchedule/schedule.vue new file mode 100644 index 000000000..82a3c9ed3 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/planSchedule/schedule.vue @@ -0,0 +1,468 @@ + + + + diff --git a/src/jmapNew/theme/foshan_01/planSchedule/statusBar.vue b/src/jmapNew/theme/foshan_01/planSchedule/statusBar.vue new file mode 100644 index 000000000..4c1418fb3 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/planSchedule/statusBar.vue @@ -0,0 +1,107 @@ + + + + + diff --git a/src/jmapNew/theme/foshan_01/planSchedule/titleBar.vue b/src/jmapNew/theme/foshan_01/planSchedule/titleBar.vue new file mode 100644 index 000000000..689c3486a --- /dev/null +++ b/src/jmapNew/theme/foshan_01/planSchedule/titleBar.vue @@ -0,0 +1,75 @@ + + + + \ No newline at end of file From 0412a6b1a35123970d3a086a198a566b84572346 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Mon, 23 Mar 2020 14:48:26 +0800 Subject: [PATCH 07/14] =?UTF-8?q?=E5=AE=81=E6=B3=A2=E4=B8=80=E5=8F=B7?= =?UTF-8?q?=E7=BA=BF=20=E7=AB=99=E5=8F=B0=E4=BF=A1=E5=8F=B7=E6=9C=BA?= =?UTF-8?q?=E5=8C=BA=E6=AE=B5=E6=93=8D=E4=BD=9C=E4=BB=A3=E7=A0=81=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../theme/ningbo_01/menus/menuSection.vue | 128 ++------ .../theme/ningbo_01/menus/menuSignal.vue | 240 +++------------ .../ningbo_01/menus/menuStationStand.vue | 194 ++----------- .../ningbo_01/menus/utils/menuOperate.js | 274 ++++++++++++++++++ 4 files changed, 355 insertions(+), 481 deletions(-) create mode 100644 src/jmapNew/theme/ningbo_01/menus/utils/menuOperate.js diff --git a/src/jmapNew/theme/ningbo_01/menus/menuSection.vue b/src/jmapNew/theme/ningbo_01/menus/menuSection.vue index 8a2e150b6..da8eaf525 100644 --- a/src/jmapNew/theme/ningbo_01/menus/menuSection.vue +++ b/src/jmapNew/theme/ningbo_01/menus/menuSection.vue @@ -18,9 +18,9 @@ import AlxeEffective from './dialog/alxeEffective'; import NoticeInfo from './dialog/childDialog/childDialog/noticeInfo'; import { mapGetters } from 'vuex'; import CMD from '@/scripts/cmdPlugin/CommandEnum'; -import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import { DeviceMenu, OperateMode } from '@/scripts/ConstDic'; import MenuContextHandler from '@/scripts/cmdPlugin/MenuContextHandler'; +import {menuOperate, commitOperate} from './utils/menuOperate'; export default { name: 'SectionMenu', @@ -150,144 +150,52 @@ export default { }, // 设置计轴失效 alxeFailure() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.alxeFailure.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.mouseCancelState(this.selected); - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - } else { - this.$refs.noticeInfo.doShow(operate); - } - }).catch(() => { - this.$refs.noticeInfo.doShow(operate); + commitOperate(menuOperate.Section.alxeFailure, {sectionCode:this.selected.code}, 3).then((data)=>{ + }).catch((error)=>{ + this.$refs.noticeInfo.doShow({}, error.message); }); }, // 故障解锁 fault() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.fault.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.sectionUnLock.doShow(operate, this.selected); - } + commitOperate(menuOperate.Section.fault, {sectionCode:this.selected.code}, 0).then((data)=>{ + this.$refs.sectionUnLock.doShow(data.operate, this.selected); }); }, // 切除 split() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.split.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.sectionControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Section.split, {sectionCode:this.selected.code}, 0).then((data)=>{ + this.$refs.sectionControl.doShow(data.operate, this.selected); }); }, // 确认计轴有效 alxeEffective() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.alxeEffective.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.alxeEffective.doShow(operate, this.selected); - } + commitOperate(menuOperate.Section.alxeEffective, {sectionCode:this.selected.code}, 0).then((data)=>{ + this.$refs.alxeEffective.doShow(data.operate, this.selected); }); }, // 区段激活 active() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.active.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.sectionControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Section.active, {sectionCode:this.selected.code}, 0).then((data)=>{ + this.$refs.sectionControl.doShow(data.operate, this.selected); }); }, // 区段封锁 lock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.lock.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.sectionControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Section.lock, {sectionCode:this.selected.code}, 0).then((data)=>{ + this.$refs.sectionControl.doShow(data.operate, this.selected); }); }, // 区段解锁 unlock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.unlock.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.sectionUnLock.doShow(operate, this.selected); - } + commitOperate(menuOperate.Section.unlock, {sectionCode:this.selected.code}, 0).then((data)=>{ + this.$refs.sectionUnLock.doShow(data.operate, this.selected); }); }, // 设置速度 setSpeed() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.setSpeed.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.speedLimitControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Section.setSpeed, {sectionCode:this.selected.code}, 0).then((data)=>{ + this.$refs.speedLimitControl.doShow(data.operate, this.selected); }); } } diff --git a/src/jmapNew/theme/ningbo_01/menus/menuSignal.vue b/src/jmapNew/theme/ningbo_01/menus/menuSignal.vue index 23a018b2d..8d0d83edd 100644 --- a/src/jmapNew/theme/ningbo_01/menus/menuSignal.vue +++ b/src/jmapNew/theme/ningbo_01/menus/menuSignal.vue @@ -22,7 +22,7 @@ import RouteHandControl from './dialog/routeHandControl'; import RouterCommand from './dialog/routerCommand'; import RouteDetail from './dialog/routeDetail'; import NoticeInfo from './dialog/childDialog/childDialog/noticeInfo'; - +import {menuOperate, commitOperate} from './utils/menuOperate'; import CMD from '@/scripts/cmdPlugin/CommandEnum'; import MenuContextHandler from '@/scripts/cmdPlugin/MenuContextHandler'; import { mapGetters } from 'vuex'; @@ -274,256 +274,92 @@ export default { this.$refs.noticeInfo.doShow(step); }); }, + // 获取进路列表 + getRouteList(selectType) { + const routes = []; + this.routeList.forEach(elem => { + if (elem.startSignalCode === selectType.code) { + routes.push(elem); + } + }); + return routes; + }, // 排列进路 arrangementRoute() { - const step = { - start: true, - code: `${this.selected.code}`, - operation: OperationEvent.Signal.arrangementRoute.menu.operation, - param: { - signalCode: this.selected.code - } - }; - - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - if (valid) { - const routes = []; - this.routeList.forEach(elem => { - if (elem.startSignalCode === this.selected.code) { - routes.push(elem); - } - }); - this.$refs.routeSelection.doShow(step.operation, this.selected, routes); - } - }).catch(() => { - this.$refs.noticeInfo.doShow(step); + commitOperate(menuOperate.Signal.arrangementRoute, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeSelection.doShow(data.operate, this.selected, this.getRouteList(this.selected)); }); }, // 取消进路 cancelTrainRoute() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Signal.cancelTrainRoute.menu.operation, - param: { - signalCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - if (valid) { - this.$refs.routeControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Signal.cancelTrainRoute, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeControl.doShow(data.operate, this.selected); }); }, // 信号封锁 lock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Signal.lock.menu.operation, - param: { - signalCode: this.selected.code - } - }; - - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.routeLock.doShow(operate.operation, this.selected); - } - }).catch((error) => { - console.log(error); - this.$refs.noticeInfo.doShow(operate); + commitOperate(menuOperate.Signal.lock, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeLock.doShow(data.operate, this.selected); }); }, - // 信号解封 + // unlock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Signal.unlock.menu.operation, - param: { - signalCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.routeUnLock.doShow(operate, this.selected); - } + commitOperate(menuOperate.Signal.unlock, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeUnLock.doShow(data.operate, this.selected); }); }, // 信号重开 reopenSignal() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Signal.reopenSignal.menu.operation, - param: { - signalCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.routeControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Signal.reopenSignal, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeControl.doShow(data.operate, this.selected); }); }, // 信号关灯 signalClose() { - const operate = { - start: true, - code: `${this.selected.code}`, - operation: OperationEvent.Signal.signalClose.menu.operation, - param: { - signalCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.routeControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Signal.signalClose, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeControl.doShow(data.operate, this.selected); }); }, // 进路交人工控 humanControl() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Signal.humanControl.menu.operation, - param: { - signalCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - const routes = []; - this.routeList.forEach(elem => { - if (elem.startSignalCode === this.selected.code) { - routes.push(elem); - } - }); - this.$refs.routeHandControl.doShow(operate, this.selected, routes); - } + commitOperate(menuOperate.Signal.humanControl, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeHandControl.doShow(data.operate, this.selected, this.getRouteList(this.selected)); }); }, // 进路交自动控 atsAutoControl() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Signal.atsAutoControl.menu.operation, - param: { - signalCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - const routes = []; - this.routeList.forEach(elem => { - if (elem.startSignalCode === this.selected.code) { - routes.push(elem); - } - }); - this.$refs.routeHandControl.doShow(operate, this.selected, routes); - } + commitOperate(menuOperate.Signal.atsAutoControl, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeHandControl.doShow(data.operate, this.selected, this.getRouteList(this.selected)); }); }, // 设置通过模式 singalPassModel() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Signal.setAutoInterlock.menu.operation, - param: { - signalCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.routeControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Signal.setAutoInterlock, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeControl.doShow(data.operate, this.selected); }); }, // 取消通过模式 singalCancelPassModel() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Signal.cancelAutoInterlock.menu.operation, - param: { - signalCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.routeControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Signal.cancelAutoInterlock, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeControl.doShow(data.operate, this.selected); }); }, // 查询进路状态 detail() { - const step = { - start: true, - code: `${this.selected.code}`, - operation: OperationEvent.Signal.detail.menu.operation, - param: { - signalCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - const routes = []; - this.routeList.forEach(elem => { - if (elem.startSignalCode === this.selected.code) { - routes.push(elem); - } - }); - this.$refs.routeDetail.doShow(step, this.selected, routes); - } + commitOperate(menuOperate.Signal.detail, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routeDetail.doShow(data.operate, this.selected, this.getRouteList(this.selected)); }); }, // 人工解锁进路(信号机取消引导) humanTrainRoute() { - const step = { - start: true, - code: `${this.selected.code}`, - operation: OperationEvent.Signal.cancelGuide.menu.operation, - param: { - signalCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.routerCommand.doShow(step, this.selected, '是否执行人解列车进路命令?'); - } + commitOperate(menuOperate.Signal.cancelGuide, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routerCommand.doShow(data.operate, this.selected, '是否执行人解列车进路命令?'); }); }, // 进路引导 guide() { - const step = { - start: true, - code: `${this.selected.code}`, - operation: OperationEvent.Signal.guide.menu.operation, - param: { - signalCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid, response }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.routerCommand.doShow(step, this.selected, '是否执行引导命令'); - } + commitOperate(menuOperate.Signal.guide, {signalCode:this.selected.code}, 0).then((data)=>{ + this.$refs.routerCommand.doShow(data.operate, this.selected, '是否执行引导命令?'); }); } } diff --git a/src/jmapNew/theme/ningbo_01/menus/menuStationStand.vue b/src/jmapNew/theme/ningbo_01/menus/menuStationStand.vue index a104fb3b6..a1be973ac 100644 --- a/src/jmapNew/theme/ningbo_01/menus/menuStationStand.vue +++ b/src/jmapNew/theme/ningbo_01/menus/menuStationStand.vue @@ -22,7 +22,7 @@ import StandRunLevel from './dialog/standRunLevel'; import StandStopTime from './dialog/standStopTime'; import StandBulkBuckleTrain from './dialog/standBulkBuckleTrain'; import NoticeInfo from './dialog/childDialog/childDialog/noticeInfo'; - +import {menuOperate, commitOperate} from './utils/menuOperate'; // import Handler from '@/scripts/cmdPlugin/Handler'; import { mapGetters } from 'vuex'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; @@ -244,218 +244,74 @@ export default { }, // 设置扣车 setDetainTrain() { - const step = { - start: true, - code: `${this.selected.code}`, - operation: OperationEvent.StationStand.setDetainTrain.menu.operation, - param: { - standCode: `${this.selected.code}` - } - }; - - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standControl.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.setDetainTrain, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standControl.doShow(data.operate, this.selected); }); }, // 取消扣车 cancelDetainTrain() { - const step = { - start: true, - code: `${this.selected.code}`, - operation: OperationEvent.StationStand.cancelDetainTrain.menu.operation, - param: { - standCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standControl.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.cancelDetainTrain, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standControl.doShow(data.operate, this.selected); }); }, // 区间列车数量限制 setDetainTrainAll() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.setDetainTrainAuto.menu.operation, - param: { - standCode: `${this.selected.code}` - } - }; - - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standControl.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.setDetainTrainAuto, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standControl.doShow(data.operate, this.selected); }); }, // 取消区间列车数量限制 cancelDetainTrainAll() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.cancelDetainTrainAuto.menu.operation, - param: { - standCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standControl.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.cancelDetainTrainAuto, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standControl.doShow(data.operate, this.selected); }); }, // 批量扣车 setBulkBuckleTrain() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.setBulkBuckleTrain.menu.operation - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standBulkBuckleTrain.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.setBulkBuckleTrain, {}, 0).then((data)=>{ + this.$refs.standBulkBuckleTrain.doShow(data.operate, this.selected); }); }, // 批量取消扣车 cancelBulkBuckleTrain() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.cancelBulkBuckleTrain.menu.operation - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standBulkBuckleTrain.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.cancelBulkBuckleTrain, {}, 0).then((data)=>{ + this.$refs.standBulkBuckleTrain.doShow(data.operate, this.selected); }); }, // 设置跳停 setJumpStop() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.setJumpStop.menu.operation, - param: { - standCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standJumpStopControl.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.setJumpStop, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standJumpStopControl.doShow(data.operate, this.selected); }); }, // 取消跳停 cancelJumpStop() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.cancelJumpStop.menu.operation, - param: { - standCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standJumpStopControl.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.cancelJumpStop, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standJumpStopControl.doShow(data.operate, this.selected); }); }, // 设置停站时间 setStopTime() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.setStopTime.menu.operation, - param: { - standCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid, response }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - // Handler.execute(CMD.Stand.CMD_STAND_VIEW_STATUS, {standCode: `${this.selected.code}`}).then(resp => { - // const tempData = resp.data; - const tempData = []; - this.$refs.standStopTime.doShow(step, this.selected, tempData); - // }); - } - }).catch(() => { - this.$refs.noticeInfo.doShow(step); + commitOperate(menuOperate.StationStand.setStopTime, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standStopTime.doShow(data.operate, this.selected, []); }); }, // 设置运行等级 setRunLevel() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.setRunLevel.menu.operation, - param: { - standCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid, response }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - // Handler.execute(CMD.Stand.CMD_STAND_VIEW_STATUS, {standCode: `${this.selected.code}`}).then(resp => { - // const tempData = resp.data; - const tempData = []; - this.$refs.standRunLevel.doShow(step, this.selected, tempData); - // }); - } - }).catch(() => { - this.$refs.noticeInfo.doShow(step); + commitOperate(menuOperate.StationStand.setRunLevel, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standRunLevel.doShow(data.operate, this.selected, []); }); }, // 设置提前发车 earlyDeparture() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.earlyDeparture.menu.operation, - param: { - standCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standControl.doShow(step, this.selected); - } + commitOperate(menuOperate.StationStand.earlyDeparture, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standControl.doShow(data.operate, this.selected, []); }); }, // 查询站台状态 detail() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.detail.menu.operation, - param: {} - }; - this.$store.dispatch('training/nextNew', step).then(({ valid, response }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - // Handler.execute(CMD.Stand.CMD_STAND_VIEW_STATUS, {standCode: `${this.selected.code}`}).then(resp => { - // const tempData = resp.data; - const tempData = []; - this.$refs.standDetail.doShow(step, this.selected, tempData); - // }); - } - }).catch(() => { - this.$refs.noticeInfo.doShow(step); + commitOperate(menuOperate.StationStand.detail, {standCode:this.selected.code}, 0).then((data)=>{ + this.$refs.standDetail.doShow(data.operate, this.selected, []); }); } } diff --git a/src/jmapNew/theme/ningbo_01/menus/utils/menuOperate.js b/src/jmapNew/theme/ningbo_01/menus/utils/menuOperate.js new file mode 100644 index 000000000..c4b1ed2b2 --- /dev/null +++ b/src/jmapNew/theme/ningbo_01/menus/utils/menuOperate.js @@ -0,0 +1,274 @@ +import store from '@/store'; +import CMD from '@/scripts/cmdPlugin/CommandEnum'; +import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; + +// 操作 +export const menuOperate = { + Section:{ + alxeFailure:{ + // 设置计轴失效 + operation: OperationEvent.Section.alxeFailure.menu.operation, + // cmdType 值有问题 + cmdType: CMD.Section.CMD_SECTION_ADD_FAULT + }, + active:{ + // 区段激活 + operation: OperationEvent.Section.active.menu.operation, + cmdType: CMD.Section.CMD_SECTION_ACTIVE + }, + alxeEffective:{ + // 确认计轴有效 + operation: OperationEvent.Section.alxeEffective.menu.operation, + cmdType: CMD.Section.CMD_SECTION_COMFIRMATION_AXLE + }, + split:{ + // 区段切除 + operation: OperationEvent.Section.split.menu.operation, + cmdType: CMD.Section.CMD_SECTION_CUT_OFF + }, + lock:{ + // 区段封锁 + operation: OperationEvent.Section.lock.menu.operation, + cmdType: CMD.Section.CMD_SECTION_BLOCK + }, + unlock:{ + // 区段解锁 + operation: OperationEvent.Section.unlock.menu.operation, + cmdType: CMD.Section.CMD_SECTION_UNBLOCK + }, + setSpeed:{ + // 设置速度 + operation: OperationEvent.Section.setSpeed.menu.operation, + cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED + }, + fault:{ + // 区段故障解锁 + operation: OperationEvent.Section.fault.menu.operation, + cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK + } + }, + Signal:{ + arrangementRoute:{ + // 排列进路 + operation: OperationEvent.Signal.arrangementRoute.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_SET_ROUTE + }, + cancelTrainRoute:{ + // 取消进路 + operation: OperationEvent.Signal.cancelTrainRoute.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_ROUTE + }, + lock:{ + // 信号封锁 + operation:OperationEvent.Signal.lock.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_BLOCK + }, + unlock:{ + // 信号解封 + operation: OperationEvent.Signal.unlock.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_UNBLOCK + }, + guide:{ + // 进路引导 + operation: OperationEvent.Signal.guide.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_ROUTE_GUIDE + }, + reopenSignal:{ + // 信号重开 + operation: OperationEvent.Signal.reopenSignal.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_REOPEN_SIGNAL + }, + signalClose:{ + // 信号关灯 + operation: OperationEvent.Signal.signalClose.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_CLOSE_SIGNAL + }, + humanControl:{ + // 进路交人工控 + operation: OperationEvent.Signal.humanControl.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_CLOSE_AUTO_SETTING + }, + atsAutoControl:{ + // 进路交自动控 + operation: OperationEvent.Signal.atsAutoControl.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING + }, + setAutoInterlock:{ + // 设置通过模式 + operation: OperationEvent.Signal.setAutoInterlock.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_SET_CI_AUTO + }, + cancelAutoInterlock:{ + // 取消通过模式 + operation: OperationEvent.Signal.cancelAutoInterlock.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_CI_AUTO + }, + detail:{ + // 查询进路状态 + operation: OperationEvent.Signal.detail.menu.operation + }, + cancelGuide:{ + // 人工解锁进路(信号机取消引导) + operation: OperationEvent.Signal.cancelGuide.menu.operation, + cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_GUIDE + } + }, + // Switch:{ + // lock:{ + // // 道岔单锁 + // operation: OperationEvent.Switch.lock.menu.operation, + // cmdType: CMD.Switch.CMD_SWITCH_SINGLE_LOCK + // }, + // unlock:{ + // // 道岔解锁 + // operation: OperationEvent.Switch.unlock.menu.operation, + // cmdType: CMD.Switch.CMD_SWITCH_SINGLE_UNLOCK + // }, + // turnoutForce:{ + // // 道岔强扳 + // operation: OperationEvent.Switch.turnoutForce.menu.operation + // }, + // locate:{ + // // 单操到定位 + // operation: OperationEvent.Switch.locate.menu.operation, + // cmdType: CMD.Switch.CMD_SWITCH_NORMAL_POSITION + // }, + // reverse:{ + // // 单操到反位 + // operation: OperationEvent.Switch.reverse.menu.operation, + // cmdType: CMD.Switch.CMD_SWITCH_REVERSE_POSITION + // }, + // split:{ + // // 区段切除 + // operation: OperationEvent.Switch.split.menu.operation, + // cmdType: CMD.Switch.CMD_SWITCH_CUT_OFF + // }, + // active:{ + // // 区段激活 + // operation: OperationEvent.Switch.active.menu.operation, + // cmdType: CMD.Switch.CMD_SWITCH_ACTIVE + // }, + // setSpeed:{ + // // 设置临时限速 + // operation: OperationEvent.Switch.setSpeed.menu.operation, + // cmdType:CMD.Switch.CMD_SWITCH_SET_LIMIT_SPEED + // }, + // alxeEffective:{ + // // 确认计轴有效 + // operation: OperationEvent.Switch.alxeEffective.menu.operation, + // cmdType: CMD.Switch.CMD_SWITCH_COMFIRMATION_AXLE + // } + + // }, + StationStand:{ + setDetainTrain:{ + // 设置扣车 + operation: OperationEvent.StationStand.setDetainTrain.menu.operation, + cmdType: CMD.Stand.CMD_STAND_SET_HOLD_TRAIN + }, + cancelDetainTrain:{ + // 取消扣车 + operation: OperationEvent.StationStand.cancelDetainTrain.menu.operation, + cmdType: CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN + }, + setDetainTrainAuto:{ + // 区间列车数量限制 + operation: OperationEvent.StationStand.setDetainTrainAuto.menu.operation, + cmdType:CMD.Stand.CMD_STAND_SET_HOLD_TRAIN_AUTO + }, + cancelDetainTrainAuto:{ + // 取消区间列车数量限制 + operation: OperationEvent.StationStand.cancelDetainTrainAuto.menu.operation, + cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN_AUTO + }, + setBulkBuckleTrain:{ + // 批量扣车 + operation: OperationEvent.StationStand.setBulkBuckleTrain.menu.operation, + cmdType:CMD.Stand.CMD_STAND_SET_HOLD_TRAIN_ALL + }, + cancelBulkBuckleTrain:{ + // 批量取消扣车 + operation: OperationEvent.StationStand.cancelBulkBuckleTrain.menu.operation, + cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN_ALL + }, + setJumpStop:{ + // 设置跳停 + operation: OperationEvent.StationStand.setJumpStop.menu.operation, + cmdType: CMD.Stand.CMD_STAND_SET_JUMP_STOP + }, + cancelJumpStop:{ + // 取消跳停 + operation: OperationEvent.StationStand.cancelJumpStop.menu.operation, + cmdType: CMD.Stand.CMD_STAND_CANCEL_JUMP_STOP + }, + setStopTime:{ + // 停站时间控制 + operation: OperationEvent.StationStand.setStopTime.menu.operation, + cmdType: CMD.Stand.CMD_STAND_SET_PARK_TIME + }, + setRunLevel:{ + // 运行时间控制 + operation: OperationEvent.StationStand.setRunLevel.menu.operation, + cmdType: CMD.Stand.CMD_STAND_SET_RUN_TIME + }, + earlyDeparture:{ + // 设置提前发车 + operation: OperationEvent.StationStand.earlyDeparture.menu.operation, + cmdType: CMD.Stand.CMD_STAND_EARLY_DEPART + }, + setBackStrategy:{ + // 设置折返策略 + operation: OperationEvent.StationStand.setBackStrategy.menu.operation, + cmdType: CMD.Stand.CMD_STAND_SET_REENTRY_STRATEGY + }, + detail:{ + // 查询站台状态 + operation: OperationEvent.StationStand.detail.menu.operation + } + } + // StationControl:{ + // requestCentralControl:{ + // // 请求中控(遥控) + // operation: OperationEvent.StationControl.requestCentralControl.menu.operation, + // cmdType: CMD.ControlConvertMenu.CMD_CM_APPLY_FOR_CENTER_CONTROL + // }, + // requestStationControl:{ + // // 请求站控 + // operation: OperationEvent.StationControl.requestStationControl.menu.operation, + // cmdType:CMD.ControlConvertMenu.CMD_CM_APPLY_FOR_STATION_CONTROL + // }, + // emergencyStationControl:{ + // // 紧急站控 + // operation: OperationEvent.StationControl.emergencyStationControl.menu.operation, + // cmdType:CMD.ControlConvertMenu.CMD_CM_EMERGENCY_STATION_CONTROL + // } + + // } +}; + +export function commitOperate(operate, paramList, over) { + const step = { + start: true, + operation: operate.operation, + param:{} + }; + step.param = paramList; + // over 0为首次操作,1为中间操作,2为最后操作,3为直接一次性操作 + if (over != 0 && over != 3) { + delete step.start; + } + if (over == 2 || over == 3) { + step.over = true; + step.cmdType = operate.cmdType; + } + return new Promise(function(resolve, reject) { + store.dispatch('training/nextNew', step).then(({ valid }) => { + if (valid) { + store.dispatch('menuOperation/handleBreakFlag', { break: true }); + resolve({operate:step}); + } + }).catch(error=>{ + reject(error); + }); + }); +} From 2501a1a70a08a9340b829834a26785d0ea1acdbe Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Mon, 23 Mar 2020 16:00:28 +0800 Subject: [PATCH 08/14] =?UTF-8?q?=E7=BB=BC=E5=90=88=E6=BC=94=E7=BB=83?= =?UTF-8?q?=E9=97=AE=E9=A2=98=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/i18n/langs/en/tip.js | 3 ++- src/i18n/langs/zh/tip.js | 3 ++- .../chengdu_03/menusPlan/createTodayPlan.vue | 9 +-------- src/views/demonstration/deomonTopic/index.vue | 17 ++++++++++------- src/views/newMap/jointTrainingNew/menuDemon.vue | 4 ++-- 5 files changed, 17 insertions(+), 19 deletions(-) diff --git a/src/i18n/langs/en/tip.js b/src/i18n/langs/en/tip.js index d24ff3622..2a9a6daac 100644 --- a/src/i18n/langs/en/tip.js +++ b/src/i18n/langs/en/tip.js @@ -232,5 +232,6 @@ export default { deviceCodeRepeatTip: 'The device code already exists, please modify the device code and created!', stopPointOffsetTip: 'Set block stop offset in bulk successfully!', mapSortSuccessfully: 'Map sort successfully!', - mapSortFailed: 'Map sort failed' + mapSortFailed: 'Map sort failed', + enterTrainingRoomFailed: 'Failed to enter the comprehensive drill, please consult the administrator is still in the room!' }; diff --git a/src/i18n/langs/zh/tip.js b/src/i18n/langs/zh/tip.js index feb92e0b1..d33ed76a3 100644 --- a/src/i18n/langs/zh/tip.js +++ b/src/i18n/langs/zh/tip.js @@ -232,5 +232,6 @@ export default { deviceCodeRepeatTip: '已存在该设备编号,请修改设备编号后创建!', stopPointOffsetTip: '批量设置区段停车点偏移量成功!', mapSortSuccessfully: '地图排序成功!', - mapSortFailed: '地图排序失败!' + mapSortFailed: '地图排序失败!', + enterTrainingRoomFailed: '进入综合演练失败,请咨询管理员是否还在房间内!' }; diff --git a/src/jmapNew/theme/chengdu_03/menusPlan/createTodayPlan.vue b/src/jmapNew/theme/chengdu_03/menusPlan/createTodayPlan.vue index 8397b4505..7b6159a5d 100644 --- a/src/jmapNew/theme/chengdu_03/menusPlan/createTodayPlan.vue +++ b/src/jmapNew/theme/chengdu_03/menusPlan/createTodayPlan.vue @@ -20,7 +20,7 @@ - diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/popupAlarm.vue b/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/popupAlarm.vue deleted file mode 100644 index 98cfc9f16..000000000 --- a/src/jmapNew/theme/foshan_01/menus/dialog/childDialog/popupAlarm.vue +++ /dev/null @@ -1,89 +0,0 @@ - - - - \ No newline at end of file diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/sectionControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/sectionControl.vue index 9e1e4176c..751dc54b7 100644 --- a/src/jmapNew/theme/foshan_01/menus/dialog/sectionControl.vue +++ b/src/jmapNew/theme/foshan_01/menus/dialog/sectionControl.vue @@ -22,7 +22,7 @@ - + 激活 @@ -61,7 +61,6 @@ export default { loading: false, selected: null, operation: '', - isShow: false, stationName: '', sectionName: '', radio: '' @@ -78,9 +77,7 @@ export default { return this.dialogShow ? OperationHandler.getDomIdByOperation(this.operation) : ''; }, title() { - if (this.operation == OperationEvent.Section.lock.menu.operation) { - return '区段封锁'; - } else if (this.operation == OperationEvent.Section.split.menu.operation) { + if (this.operation == OperationEvent.Section.split.menu.operation) { return '区段控制'; } else if (this.operation == OperationEvent.Section.active.menu.operation) { return '区段控制'; @@ -114,13 +111,10 @@ export default { } } this.operation = operate.operation || ''; - this.isShow = false; if (this.operation == OperationEvent.Section.split.menu.operation) { this.radio = '2'; - this.isShow = true; } else if (this.operation == OperationEvent.Section.active.menu.operation) { this.radio = '1'; - this.isShow = true; } } this.dialogShow = true; @@ -135,27 +129,14 @@ export default { this.mouseCancelState(this.selected); }, commit() { - if (this.operation == OperationEvent.Section.lock.menu.operation) { - /** 区段封锁*/ - this.lock(); - } else if (this.operation == OperationEvent.Section.split.menu.operation) { - /** 轨道区段切除*/ + if (this.operation == OperationEvent.Section.split.menu.operation) { + /** 轨道区段切除*/ this.split(); } else if (this.operation == OperationEvent.Section.active.menu.operation) { - /** 轨道区段激活*/ + /** 轨道区段激活*/ this.active(); } }, - // 区段封锁 - lock() { - const operate = { - over: true, - operation: this.operation, - cmdType: CMD.Section.CMD_SECTION_BLOCK - }; - - this.sendCommand(operate); - }, // 轨道区段切除 split() { const operate = { diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/sectionUnLock.vue b/src/jmapNew/theme/foshan_01/menus/dialog/sectionUnLock.vue index 730534019..f2771ff5b 100644 --- a/src/jmapNew/theme/foshan_01/menus/dialog/sectionUnLock.vue +++ b/src/jmapNew/theme/foshan_01/menus/dialog/sectionUnLock.vue @@ -101,9 +101,7 @@ export default { return this.dialogShow ? OperationEvent.Section.unlock.confirm.domId : ''; }, title() { - if (this.operation == OperationEvent.Section.unlock.menu.operation) { - return '解除封锁'; - } else if (this.operation == OperationEvent.Section.fault.menu.operation) { + if (this.operation == OperationEvent.Section.fault.menu.operation) { return '区故解'; } return ''; @@ -156,9 +154,7 @@ export default { val: this.messageText2 }; - if (this.operation == OperationEvent.Section.unlock.menu.operation) { - operate.operation = OperationEvent.Section.unlock.choose.operation; - } else if (this.operation == OperationEvent.Section.fault.menu.operation) { + if (this.operation == OperationEvent.Section.fault.menu.operation) { operate.operation = OperationEvent.Section.fault.choose.operation; } @@ -176,9 +172,7 @@ export default { operation: '' }; - if (this.operation == OperationEvent.Section.unlock.menu.operation) { - operate.operation = OperationEvent.Section.unlock.confirm1.operation; - } else if (this.operation == OperationEvent.Section.fault.menu.operation) { + if (this.operation == OperationEvent.Section.fault.menu.operation) { operate.operation = OperationEvent.Section.fault.confirm1.operation; } @@ -201,10 +195,7 @@ export default { cmdType: '' }; - if (this.operation == OperationEvent.Section.unlock.menu.operation) { - operate.operation = OperationEvent.Section.unlock.confirm2.operation; - operate.cmdType = CMD.Section.CMD_SECTION_UNBLOCK; - } else if (this.operation == OperationEvent.Section.fault.menu.operation) { + if (this.operation == OperationEvent.Section.fault.menu.operation) { operate.operation = OperationEvent.Section.fault.confirm2.operation; operate.cmdType = CMD.Section.CMD_SECTION_FAULT_UNLOCK; } @@ -226,9 +217,7 @@ export default { operation: '' }; - if (this.operation == OperationEvent.Section.unlock.menu.operation) { - operate.operation = OperationEvent.Section.unlock.confirm.operation; - } else if (this.operation == OperationEvent.Section.fault.menu.operation) { + if (this.operation == OperationEvent.Section.fault.menu.operation) { operate.operation = OperationEvent.Section.fault.confirm.operation; } diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/switchControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/switchControl.vue index ee131b501..58e3f3af1 100644 --- a/src/jmapNew/theme/foshan_01/menus/dialog/switchControl.vue +++ b/src/jmapNew/theme/foshan_01/menus/dialog/switchControl.vue @@ -22,16 +22,6 @@ - - - - 激活 - - - - 切除 - - @@ -86,7 +76,6 @@ export default { switchName: '', isLock: false, isTurnBlock: false, - isActive: false, turnRadio: '1', lockRadio: '1', activeRadio: '1' @@ -140,7 +129,6 @@ export default { this.operation = operate.operation; this.isLock = false; this.isTurnBlock = false; - this.isActive = false; if (this.operation == OperationEvent.Switch.locate.menu.operation) { this.isTurnBlock = true; this.turnRadio = '1'; @@ -149,12 +137,6 @@ export default { this.turnRadio = '2'; } else if (this.operation == OperationEvent.Switch.lock.menu.operation) { this.isLock = true; - } else if (this.operation == OperationEvent.Switch.split.menu.operation) { - this.isActive = true; - this.activeRadio = '2'; - } else if (this.operation == OperationEvent.Switch.active.menu.operation) { - this.isActive = true; - this.activeRadio = '1'; } } this.dialogShow = true; @@ -181,12 +163,6 @@ export default { } else if (this.operation == OperationEvent.Switch.reverse.menu.operation) { /** 道岔反位*/ this.reverse(); - } else if (this.operation == OperationEvent.Switch.split.menu.operation) { - /** 区段切除*/ - this.split(); - } else if (this.operation == OperationEvent.Switch.active.menu.operation) { - /** 区段激活*/ - this.active(); } }, // 道岔单锁 @@ -229,24 +205,6 @@ export default { this.sendCommand(operate); }, - // 区段切除 - split() { - const operate = { - over: true, - operation: OperationEvent.Switch.split.menu.operation, - cmdType: CMD.Switch.CMD_SWITCH_CUT_OFF - }; - this.sendCommand(operate); - }, - // 区段激活 - active() { - const operate = { - over: true, - operation: OperationEvent.Switch.active.menu.operation, - cmdType: CMD.Switch.CMD_SWITCH_ACTIVE - }; - this.sendCommand(operate); - }, cancel() { const operate = { operation: OperationEvent.Command.cancel.menu.operation diff --git a/src/jmapNew/theme/foshan_01/menus/menuSection.vue b/src/jmapNew/theme/foshan_01/menus/menuSection.vue index 8a2e150b6..d04589eec 100644 --- a/src/jmapNew/theme/foshan_01/menus/menuSection.vue +++ b/src/jmapNew/theme/foshan_01/menus/menuSection.vue @@ -4,7 +4,6 @@ - @@ -14,7 +13,6 @@ import PopMenu from '@/components/PopMenu'; import SectionControl from './dialog/sectionControl'; import SectionUnLock from './dialog/sectionUnLock'; import SpeedLimitControl from './dialog/speedLimitControl'; -import AlxeEffective from './dialog/alxeEffective'; import NoticeInfo from './dialog/childDialog/childDialog/noticeInfo'; import { mapGetters } from 'vuex'; import CMD from '@/scripts/cmdPlugin/CommandEnum'; @@ -29,7 +27,6 @@ export default { SectionControl, SectionUnLock, SpeedLimitControl, - AlxeEffective, NoticeInfo }, props: { @@ -59,16 +56,6 @@ export default { label: '区段切除跟踪', handler: this.split, cmdType: CMD.Section.CMD_SECTION_CUT_OFF - }, - { - label: '区段封锁', - handler: this.lock, - cmdType: CMD.Section.CMD_SECTION_BLOCK - }, - { - label: '区段解封', - handler: this.unlock, - cmdType: CMD.Section.CMD_SECTION_UNBLOCK } ], Center: [ @@ -81,17 +68,12 @@ export default { label: '区段跟踪切除', handler: this.split, cmdType: CMD.Section.CMD_SECTION_CUT_OFF - }, - { - label: '确认计轴有效', - handler: this.alxeEffective, - cmdType: CMD.Section.CMD_SECTION_COMFIRMATION_AXLE - }, - { - label: '设置临时限速', - handler: this.setSpeed, - cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED } + // { + // label: '设置临时限速', + // handler: this.setSpeed, + // cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED + // } ] }, menuForce: [ @@ -205,23 +187,6 @@ export default { } }); }, - // 确认计轴有效 - alxeEffective() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.alxeEffective.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.alxeEffective.doShow(operate, this.selected); - } - }); - }, // 区段激活 active() { const operate = { @@ -238,58 +203,24 @@ export default { this.$refs.sectionControl.doShow(operate, this.selected); } }); - }, - // 区段封锁 - lock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.lock.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.sectionControl.doShow(operate, this.selected); - } - }); - }, - // 区段解锁 - unlock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.unlock.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.sectionUnLock.doShow(operate, this.selected); - } - }); - }, - // 设置速度 - setSpeed() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Section.setSpeed.menu.operation, - param: { - sectionCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.speedLimitControl.doShow(operate, this.selected); - } - }); } + // // 设置速度 + // setSpeed() { + // const operate = { + // start: true, + // code: this.selected.code, + // operation: OperationEvent.Section.setSpeed.menu.operation, + // param: { + // sectionCode: this.selected.code + // } + // }; + // this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { + // if (valid) { + // this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); + // this.$refs.speedLimitControl.doShow(operate, this.selected); + // } + // }); + // } } }; diff --git a/src/jmapNew/theme/foshan_01/menus/menuSwitch.vue b/src/jmapNew/theme/foshan_01/menus/menuSwitch.vue index 6a2b247a9..e9c1801f0 100644 --- a/src/jmapNew/theme/foshan_01/menus/menuSwitch.vue +++ b/src/jmapNew/theme/foshan_01/menus/menuSwitch.vue @@ -4,7 +4,6 @@ - @@ -14,7 +13,6 @@ import PopMenu from '@/components/PopMenu'; import SwitchControl from './dialog/switchControl'; import SwitchUnLock from './dialog/switchUnLock'; import SpeedLimitControl from './dialog/speedLimitControl'; -import AlxeEffective from './dialog/alxeEffective'; import NoticeInfo from './dialog/childDialog/childDialog/noticeInfo'; import { mapGetters } from 'vuex'; @@ -30,7 +28,6 @@ export default { SwitchControl, SwitchUnLock, SpeedLimitControl, - AlxeEffective, NoticeInfo }, props: { @@ -47,12 +44,12 @@ export default { menuNormal: { Local: [ { - label: '定操', + label: '道岔总定', handler: this.locate, cmdType: CMD.Switch.CMD_SWITCH_TURN_NP_CHAIN }, { - label: '反操', + label: '道岔总反', handler: this.reverse, cmdType: CMD.Switch.CMD_SWITCH_TURN_RP_CHAIN }, @@ -67,7 +64,7 @@ export default { cmdType: CMD.Switch.CMD_SWITCH_SINGLE_UNLOCK }, { - label: '道岔封锁', + label: '道岔封闭', handler: this.block, cmdType: CMD.Switch.CMD_SWITCH_BLOCK }, @@ -76,52 +73,14 @@ export default { handler: this.unblock, cmdType: CMD.Switch.CMD_SWITCH_UNBLOCK } + // 道岔强板 ], Center: [ - { - label: '定操', - handler: this.locate, - cmdType: CMD.Switch.CMD_SWITCH_TURN_NP_CHAIN - }, - { - label: '反操', - handler: this.reverse, - cmdType: CMD.Switch.CMD_SWITCH_TURN_RP_CHAIN - }, - { - type: 'separator' - }, - { - label: '区段激活', - handler: this.active, - cmdType: CMD.Switch.CMD_SWITCH_ACTIVE - }, - { - label: '区段切除', - handler: this.split, - cmdType: CMD.Switch.CMD_SWITCH_CUT_OFF - }, - { - type: 'separator' - }, - { - label: '确认计轴有效', - handler: this.alxeEffective, - cmdType: CMD.Switch.CMD_SWITCH_COMFIRMATION_AXLE - }, - { - label: '设置临时限速', - handler: this.setSpeed, - cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED - }, - { - type: 'separator' - }, - { - label: '查看公里标', - handler: this.undeveloped, - cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED - } + // { + // label: '设置临时限速', + // handler: this.setSpeed, + // cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED + // }, ] }, menuForce: [ @@ -329,74 +288,23 @@ export default { } }); }, - // 区段切除 - split() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.split.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchControl.doShow(operate, this.selected); - } - }); - }, - // 区段激活 - active() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.active.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchControl.doShow(operate, this.selected); - } - }); - }, // 设置临时限速 - setSpeed() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.setSpeed.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.speedLimitControl.doShow(operate, this.selected); - } - }); - }, - // 确认计轴有效 - alxeEffective() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.alxeEffective.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.alxeEffective.doShow(operate, this.selected); - } - }); - }, + // setSpeed() { + // const operate = { + // start: true, + // code: this.selected.code, + // operation: OperationEvent.Switch.setSpeed.menu.operation, + // param: { + // switchCode: this.selected.code + // } + // }; + // this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { + // if (valid) { + // this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); + // this.$refs.speedLimitControl.doShow(operate, this.selected); + // } + // }); + // }, undeveloped() { this.doClose(); this.$alert('实现中......', '提示', { diff --git a/src/jmapNew/theme/ningbo_01/menus/menuSwitch.vue b/src/jmapNew/theme/ningbo_01/menus/menuSwitch.vue index 6a2b247a9..61a60cf34 100644 --- a/src/jmapNew/theme/ningbo_01/menus/menuSwitch.vue +++ b/src/jmapNew/theme/ningbo_01/menus/menuSwitch.vue @@ -22,6 +22,7 @@ import CMD from '@/scripts/cmdPlugin/CommandEnum'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import { DeviceMenu, OperateMode } from '@/scripts/ConstDic'; import MenuContextHandler from '@/scripts/cmdPlugin/MenuContextHandler'; +import {menuOperate, commitOperate} from './utils/menuOperate'; export default { name: 'SwitchMenu', @@ -89,7 +90,7 @@ export default { cmdType: CMD.Switch.CMD_SWITCH_TURN_RP_CHAIN }, { - type: 'separator' + type: 'separator' }, { label: '区段激活', @@ -102,8 +103,8 @@ export default { cmdType: CMD.Switch.CMD_SWITCH_CUT_OFF }, { - type: 'separator' - }, + type: 'separator' + }, { label: '确认计轴有效', handler: this.alxeEffective, @@ -115,7 +116,7 @@ export default { cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED }, { - type: 'separator' + type: 'separator' }, { label: '查看公里标', @@ -229,172 +230,62 @@ export default { }, // 单操到定位 locate() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.locate.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.locate, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.switchControl.doShow(data.operate, this.selected); }); }, // 单操到反位 reverse() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.reverse.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.reverse, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.switchControl.doShow(data.operate, this.selected); }); }, // 道岔单锁 lock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.lock.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.lock, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.switchControl.doShow(data.operate, this.selected); }); }, // 道岔解锁 unlock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.unlock.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchUnLock.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.unlock, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.switchUnLock.doShow(data.operate, this.selected); }); }, // 道岔封锁 block() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.block.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.block, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.switchControl.doShow(data.operate, this.selected); }); }, // 道岔解封 unblock() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.unblock.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchUnLock.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.unblock, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.switchUnLock.doShow(data.operate, this.selected); }); }, // 区段切除 split() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.split.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.split, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.switchControl.doShow(data.operate, this.selected); }); }, // 区段激活 active() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.active.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.switchControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.active, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.switchControl.doShow(data.operate, this.selected); }); }, // 设置临时限速 setSpeed() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.setSpeed.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.speedLimitControl.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.setSpeed, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.speedLimitControl.doShow(data.operate, this.selected); }); }, // 确认计轴有效 alxeEffective() { - const operate = { - start: true, - code: this.selected.code, - operation: OperationEvent.Switch.alxeEffective.menu.operation, - param: { - switchCode: this.selected.code - } - }; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.alxeEffective.doShow(operate, this.selected); - } + commitOperate(menuOperate.Switch.alxeEffective, {switchCode:this.selected.code}, 0).then((data)=>{ + this.$refs.alxeEffective.doShow(data.operate, this.selected); }); }, undeveloped() { diff --git a/src/jmapNew/theme/ningbo_01/menus/utils/menuOperate.js b/src/jmapNew/theme/ningbo_01/menus/utils/menuOperate.js index c4b1ed2b2..b7c73bb05 100644 --- a/src/jmapNew/theme/ningbo_01/menus/utils/menuOperate.js +++ b/src/jmapNew/theme/ningbo_01/menus/utils/menuOperate.js @@ -113,53 +113,58 @@ export const menuOperate = { cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_GUIDE } }, - // Switch:{ - // lock:{ - // // 道岔单锁 - // operation: OperationEvent.Switch.lock.menu.operation, - // cmdType: CMD.Switch.CMD_SWITCH_SINGLE_LOCK - // }, - // unlock:{ - // // 道岔解锁 - // operation: OperationEvent.Switch.unlock.menu.operation, - // cmdType: CMD.Switch.CMD_SWITCH_SINGLE_UNLOCK - // }, - // turnoutForce:{ - // // 道岔强扳 - // operation: OperationEvent.Switch.turnoutForce.menu.operation - // }, - // locate:{ - // // 单操到定位 - // operation: OperationEvent.Switch.locate.menu.operation, - // cmdType: CMD.Switch.CMD_SWITCH_NORMAL_POSITION - // }, - // reverse:{ - // // 单操到反位 - // operation: OperationEvent.Switch.reverse.menu.operation, - // cmdType: CMD.Switch.CMD_SWITCH_REVERSE_POSITION - // }, - // split:{ - // // 区段切除 - // operation: OperationEvent.Switch.split.menu.operation, - // cmdType: CMD.Switch.CMD_SWITCH_CUT_OFF - // }, - // active:{ - // // 区段激活 - // operation: OperationEvent.Switch.active.menu.operation, - // cmdType: CMD.Switch.CMD_SWITCH_ACTIVE - // }, - // setSpeed:{ - // // 设置临时限速 - // operation: OperationEvent.Switch.setSpeed.menu.operation, - // cmdType:CMD.Switch.CMD_SWITCH_SET_LIMIT_SPEED - // }, - // alxeEffective:{ - // // 确认计轴有效 - // operation: OperationEvent.Switch.alxeEffective.menu.operation, - // cmdType: CMD.Switch.CMD_SWITCH_COMFIRMATION_AXLE - // } - - // }, + Switch:{ + lock:{ + // 道岔单锁 + operation: OperationEvent.Switch.lock.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_SINGLE_LOCK + }, + unlock:{ + // 道岔解锁 + operation: OperationEvent.Switch.unlock.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_SINGLE_UNLOCK + }, + block:{ + // 道岔封锁 + operation: OperationEvent.Switch.block.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_BLOCK + }, + unblock:{ + // 道岔解封 + operation: OperationEvent.Switch.unblock.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_UNBLOCK + }, + locate:{ + // 单操到定位 + operation: OperationEvent.Switch.locate.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_NORMAL_POSITION + }, + reverse:{ + // 单操到反位 + operation: OperationEvent.Switch.reverse.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_REVERSE_POSITION + }, + split:{ + // 区段切除 + operation: OperationEvent.Switch.split.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_CUT_OFF + }, + active:{ + // 区段激活 + operation: OperationEvent.Switch.active.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_ACTIVE + }, + setSpeed:{ + // 设置临时限速 + operation: OperationEvent.Switch.setSpeed.menu.operation, + cmdType:CMD.Switch.CMD_SWITCH_SET_LIMIT_SPEED + }, + alxeEffective:{ + // 确认计轴有效 + operation: OperationEvent.Switch.alxeEffective.menu.operation, + cmdType: CMD.Switch.CMD_SWITCH_COMFIRMATION_AXLE + } + }, StationStand:{ setDetainTrain:{ // 设置扣车 From 93fd139b6ee5eb5945b7cd80202a3390f98b82b2 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Mon, 23 Mar 2020 17:43:37 +0800 Subject: [PATCH 11/14] =?UTF-8?q?=E4=BD=9B=E5=B1=B1=E6=9C=89=E8=BD=A8?= =?UTF-8?q?=E7=94=B5=E8=BD=A6=20=E4=BF=A1=E5=8F=B7=E6=9C=BA=E7=AB=99?= =?UTF-8?q?=E5=8F=B0=E6=93=8D=E4=BD=9C=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 --- .../menus/dialog/standBulkBuckleTrain.vue | 279 ------------------ .../foshan_01/menus/dialog/standControl.vue | 72 ----- .../theme/foshan_01/menus/menuSignal.vue | 16 +- .../foshan_01/menus/menuStationStand.vue | 101 +------ 4 files changed, 12 insertions(+), 456 deletions(-) delete mode 100644 src/jmapNew/theme/foshan_01/menus/dialog/standBulkBuckleTrain.vue diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standBulkBuckleTrain.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standBulkBuckleTrain.vue deleted file mode 100644 index 48be045ef..000000000 --- a/src/jmapNew/theme/foshan_01/menus/dialog/standBulkBuckleTrain.vue +++ /dev/null @@ -1,279 +0,0 @@ - - - - diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standControl.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standControl.vue index c190c9c29..a2414dc5e 100644 --- a/src/jmapNew/theme/foshan_01/menus/dialog/standControl.vue +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standControl.vue @@ -177,10 +177,6 @@ export default { return '取消扣车'; } else if (this.operation == OperationEvent.StationStand.earlyDeparture.menu.operation) { return '提前发车'; - } else if (this.operation == OperationEvent.StationStand.setDetainTrainAuto.menu.operation) { - return '区间自动扣车'; - } else if (this.operation == OperationEvent.StationStand.cancelDetainTrainAuto.menu.operation) { - return '区间自动扣车'; } return ''; } @@ -236,20 +232,6 @@ export default { } else { this.radio2 = '1'; } - } else if (this.operation == OperationEvent.StationStand.setDetainTrainAuto.menu.operation) { - this.AutomaticBuckle = true; - this.autoRadio1 = '1'; - this.autoRadio = '1'; - if (!this.selected.right) { - this.autoRadio = '2'; - } - } else if (this.operation == OperationEvent.StationStand.cancelDetainTrainAuto.menu.operation) { - this.AutomaticBuckle = true; - this.autoRadio1 = '2'; - this.autoRadio = '1'; - if (!this.selected.right) { - this.autoRadio = '2'; - } } }, doClose() { @@ -288,62 +270,8 @@ export default { } else if (this.operation == OperationEvent.StationStand.earlyDeparture.menu.operation) { /** 提前发车*/ this.earlyDeparture(); - } else if (this.operation == OperationEvent.StationStand.setDetainTrainAuto.menu.operation) { - /** 区间自动扣车*/ - this.setDetainTrainAuto(); - } else if (this.operation == OperationEvent.StationStand.cancelDetainTrainAuto.menu.operation) { - /** 取消区间自动扣车*/ - this.cancelDetainTrainAuto(); } }, - setDetainTrainAuto() { // 区间自动扣车 - const operate = { - over: true, - operation: OperationEvent.StationStand.setDetainTrainAuto.menu.operation, - cmdType: CMD.Stand.CMD_STAND_SET_HOLD_TRAIN_AUTO, - param: { - leftDirection: this.autoRadio == '2', // 1 上行 2 下行 - rightDirection: this.autoRadio == '1' - } - }; - - this.loading = true; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - this.loading = false; - this.doClose(); - if (!valid) { - this.$refs.noticeInfo.doShow(operate); - } - }).catch((error) => { - this.loading = false; - this.doClose(); - this.$refs.noticeInfo.doShow(operate, [error.message]); - }); - }, - cancelDetainTrainAuto() { // 取消区间自动扣车 - const operate = { - over: true, - operation: OperationEvent.StationStand.cancelDetainTrainAuto.menu.operation, - cmdType: CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN_AUTO, - param: { - leftDirection: this.autoRadio == '2', // 1 上行 2 下行 - rightDirection: this.autoRadio == '1' - } - }; - - this.loading = true; - this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { - this.loading = false; - this.doClose(); - if (!valid) { - this.$refs.noticeInfo.doShow(operate); - } - }).catch((error) => { - this.loading = false; - this.doClose(); - this.$refs.noticeInfo.doShow(operate, [error.message]); - }); - }, // 设置扣车 setDetainTrain() { const operate = { diff --git a/src/jmapNew/theme/foshan_01/menus/menuSignal.vue b/src/jmapNew/theme/foshan_01/menus/menuSignal.vue index 23a018b2d..cc548ffd6 100644 --- a/src/jmapNew/theme/foshan_01/menus/menuSignal.vue +++ b/src/jmapNew/theme/foshan_01/menus/menuSignal.vue @@ -72,7 +72,7 @@ export default { cmdType: CMD.Signal.CMD_SIGNAL_REOPEN_SIGNAL }, { - label: '信号机引导办理', + label: '进路引导', handler: this.guide, cmdType: CMD.Signal.CMD_SIGNAL_ROUTE_GUIDE }, @@ -92,12 +92,12 @@ export default { cmdType: CMD.Signal.CMD_SIGNAL_UNBLOCK }, { - label: 'Fleet进路办理', + label: '设置自动进路', handler: this.singalPassModel, cmdType: CMD.Signal.CMD_SIGNAL_SET_CI_AUTO }, { - label: 'Fleet进路取消', + label: '取消自动进路', handler: this.singalCancelPassModel, cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_CI_AUTO }, @@ -143,16 +143,6 @@ export default { handler: this.atsAutoControl, cmdType: CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING }, - { - label: '设置通过模式', - handler: this.singalPassModel, - cmdType: CMD.Signal.CMD_SIGNAL_SET_CI_AUTO - }, - { - label: '取消通过模式', - handler: this.singalCancelPassModel, - cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_CI_AUTO - }, { label: '查询进路控制状态', handler: this.detail, diff --git a/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue b/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue index a104fb3b6..301782c75 100644 --- a/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue +++ b/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue @@ -7,7 +7,6 @@ - @@ -20,7 +19,6 @@ import StandBackStrategy from './dialog/standBackStrategy'; import StandDetail from './dialog/standDetail'; import StandRunLevel from './dialog/standRunLevel'; import StandStopTime from './dialog/standStopTime'; -import StandBulkBuckleTrain from './dialog/standBulkBuckleTrain'; import NoticeInfo from './dialog/childDialog/childDialog/noticeInfo'; // import Handler from '@/scripts/cmdPlugin/Handler'; @@ -36,7 +34,6 @@ export default { PopMenu, StandControl, StandJumpStopControl, - StandBulkBuckleTrain, StandDetail, StandRunLevel, NoticeInfo, @@ -57,7 +54,7 @@ export default { menuNormal: { Local: [ { - label: '扣车', + label: '设置扣车', handler: this.setDetainTrain, cmdType:CMD.Stand.CMD_STAND_SET_HOLD_TRAIN }, @@ -67,19 +64,20 @@ export default { cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN }, { - label: '提前发车', + label: '设置提前发车', handler: this.earlyDeparture, cmdType:CMD.Stand.CMD_STAND_EARLY_DEPART }, { - label: '站台详细信息', + label: '查询站台状态', handler: this.detail, cmdType:CMD.Stand.CMD_STAND_VIEW_STATUS } + // 全线取消扣车 ], Center: [ { - label: '扣车', + label: '设置扣车', handler: this.setDetainTrain, cmdType:CMD.Stand.CMD_STAND_SET_HOLD_TRAIN }, @@ -89,17 +87,7 @@ export default { cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN }, { - label: '批量扣车', - handler: this.setBulkBuckleTrain, - cmdType:CMD.Stand.CMD_STAND_SET_HOLD_TRAIN_ALL - }, - { - label: '批量取消扣车', - handler: this.cancelBulkBuckleTrain, - cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN_ALL - }, - { - label: '提前发车', + label: '设置提前发车', handler: this.earlyDeparture, cmdType:CMD.Stand.CMD_STAND_EARLY_DEPART }, @@ -124,20 +112,12 @@ export default { cmdType:CMD.Stand.CMD_STAND_SET_RUN_TIME }, { - label: '区间列车数量限制', - handler: this.setDetainTrainAll, - cmdType:CMD.Stand.CMD_STAND_SET_HOLD_TRAIN_AUTO - }, - { - label: '取消区间列车数量限制', - handler: this.cancelDetainTrainAll, - cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN_AUTO - }, - { - label: '查看站台信息', + label: '查询站台状态', handler: this.detail, cmdType:CMD.Stand.CMD_STAND_VIEW_STATUS } + // 全线取消跳停 + // 全线取消扣车 ] }, menuForce: [ @@ -277,69 +257,6 @@ export default { } }); }, - // 区间列车数量限制 - setDetainTrainAll() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.setDetainTrainAuto.menu.operation, - param: { - standCode: `${this.selected.code}` - } - }; - - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standControl.doShow(step, this.selected); - } - }); - }, - // 取消区间列车数量限制 - cancelDetainTrainAll() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.cancelDetainTrainAuto.menu.operation, - param: { - standCode: `${this.selected.code}` - } - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standControl.doShow(step, this.selected); - } - }); - }, - // 批量扣车 - setBulkBuckleTrain() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.setBulkBuckleTrain.menu.operation - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standBulkBuckleTrain.doShow(step, this.selected); - } - }); - }, - // 批量取消扣车 - cancelBulkBuckleTrain() { - const step = { - start: true, - code: this.selected.code, - operation: OperationEvent.StationStand.cancelBulkBuckleTrain.menu.operation - }; - this.$store.dispatch('training/nextNew', step).then(({ valid }) => { - if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.standBulkBuckleTrain.doShow(step, this.selected); - } - }); - }, // 设置跳停 setJumpStop() { const step = { From 91e2c81c6f8d50cadf16b2494acafbd3b827dff0 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Mon, 23 Mar 2020 18:12:37 +0800 Subject: [PATCH 12/14] =?UTF-8?q?=E4=BD=9B=E5=B1=B1=E6=9C=89=E8=BD=A8?= =?UTF-8?q?=E7=94=B5=E8=BD=A6=20=E6=93=8D=E4=BD=9C=E4=BB=A3=E7=A0=81?= =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../menus/dialog/standDetainTrainAll.vue | 341 +++++++++--------- .../menus/dialog/standDetainTrainAll.vue | 187 ++++++++++ .../theme/foshan_01/menus/menuSection.vue | 8 +- .../theme/foshan_01/menus/menuSignal.vue | 15 +- .../foshan_01/menus/menuStationStand.vue | 37 +- 5 files changed, 407 insertions(+), 181 deletions(-) create mode 100644 src/jmapNew/theme/foshan_01/menus/dialog/standDetainTrainAll.vue diff --git a/src/jmap/theme/beijing_01/menus/dialog/standDetainTrainAll.vue b/src/jmap/theme/beijing_01/menus/dialog/standDetainTrainAll.vue index 6aac5f482..cec1b47fd 100644 --- a/src/jmap/theme/beijing_01/menus/dialog/standDetainTrainAll.vue +++ b/src/jmap/theme/beijing_01/menus/dialog/standDetainTrainAll.vue @@ -1,180 +1,187 @@ \ No newline at end of file +}; + diff --git a/src/jmapNew/theme/foshan_01/menus/dialog/standDetainTrainAll.vue b/src/jmapNew/theme/foshan_01/menus/dialog/standDetainTrainAll.vue new file mode 100644 index 000000000..1d4d07108 --- /dev/null +++ b/src/jmapNew/theme/foshan_01/menus/dialog/standDetainTrainAll.vue @@ -0,0 +1,187 @@ + + + diff --git a/src/jmapNew/theme/foshan_01/menus/menuSection.vue b/src/jmapNew/theme/foshan_01/menus/menuSection.vue index d04589eec..3fd27578f 100644 --- a/src/jmapNew/theme/foshan_01/menus/menuSection.vue +++ b/src/jmapNew/theme/foshan_01/menus/menuSection.vue @@ -48,24 +48,24 @@ export default { cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK }, { - label: '区段激活跟踪', + label: '区段激活', handler: this.active, cmdType: CMD.Section.CMD_SECTION_ACTIVE }, { - label: '区段切除跟踪', + label: '区段切除', handler: this.split, cmdType: CMD.Section.CMD_SECTION_CUT_OFF } ], Center: [ { - label: '区段跟踪激活', + label: '区段激活', handler: this.active, cmdType: CMD.Section.CMD_SECTION_ACTIVE }, { - label: '区段跟踪切除', + label: '区段切除', handler: this.split, cmdType: CMD.Section.CMD_SECTION_CUT_OFF } diff --git a/src/jmapNew/theme/foshan_01/menus/menuSignal.vue b/src/jmapNew/theme/foshan_01/menus/menuSignal.vue index cc548ffd6..54782c105 100644 --- a/src/jmapNew/theme/foshan_01/menus/menuSignal.vue +++ b/src/jmapNew/theme/foshan_01/menus/menuSignal.vue @@ -57,12 +57,12 @@ export default { menuNormal: { Local: [ { - label: '设置进路', + label: '进路选排', handler: this.arrangementRoute, cmdType: CMD.Signal.CMD_SIGNAL_SET_ROUTE }, { - label: '取消进路', + label: '进路取消', handler: this.cancelTrainRoute, cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_ROUTE }, @@ -112,19 +112,19 @@ export default { cmdType: CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING }, { - label: '查询进路控制状态', + label: '查询进路状态', handler: this.detail, cmdType: CMD.Signal.CMD_SIGNAL_DETAIL } ], Center: [ { - label: '设置进路', + label: '进路选排', handler: this.arrangementRoute, cmdType: CMD.Signal.CMD_SIGNAL_SET_ROUTE }, { - label: '取消列车进路', + label: '进路取消', handler: this.cancelTrainRoute, cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_ROUTE }, @@ -133,6 +133,9 @@ export default { handler: this.reopenSignal, cmdType: CMD.Signal.CMD_SIGNAL_REOPEN_SIGNAL }, + { + type: 'separator' + }, { label: '进路交人工控', handler: this.humanControl, @@ -144,7 +147,7 @@ export default { cmdType: CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING }, { - label: '查询进路控制状态', + label: '查询进路状态', handler: this.detail, cmdType: CMD.Signal.CMD_SIGNAL_DETAIL } diff --git a/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue b/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue index 301782c75..1f8f107ce 100644 --- a/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue +++ b/src/jmapNew/theme/foshan_01/menus/menuStationStand.vue @@ -7,6 +7,7 @@ + @@ -20,7 +21,7 @@ import StandDetail from './dialog/standDetail'; import StandRunLevel from './dialog/standRunLevel'; import StandStopTime from './dialog/standStopTime'; import NoticeInfo from './dialog/childDialog/childDialog/noticeInfo'; - +import StandDetainTrainAll from './dialog/standDetainTrainAll'; // import Handler from '@/scripts/cmdPlugin/Handler'; import { mapGetters } from 'vuex'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; @@ -38,7 +39,8 @@ export default { StandRunLevel, NoticeInfo, StandBackStrategy, - StandStopTime + StandStopTime, + StandDetainTrainAll }, props: { selected: { @@ -63,6 +65,11 @@ export default { handler: this.cancelDetainTrain, cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN }, + { + label: '全线取消扣车', + handler: this.cancelDetainTrainAll, + cmdType:CMD.Stand.CMD_STAND_WHOLE_LINE_CANCEL_HOLD_TRAIN + }, { label: '设置提前发车', handler: this.earlyDeparture, @@ -73,7 +80,7 @@ export default { handler: this.detail, cmdType:CMD.Stand.CMD_STAND_VIEW_STATUS } - // 全线取消扣车 + ], Center: [ { @@ -86,6 +93,11 @@ export default { handler: this.cancelDetainTrain, cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN }, + { + label: '全线取消扣车', + handler: this.cancelDetainTrainAll, + cmdType:CMD.Stand.CMD_STAND_WHOLE_LINE_CANCEL_HOLD_TRAIN + }, { label: '设置提前发车', handler: this.earlyDeparture, @@ -116,8 +128,8 @@ export default { handler: this.detail, cmdType:CMD.Stand.CMD_STAND_VIEW_STATUS } + // 全线取消跳停 - // 全线取消扣车 ] }, menuForce: [ @@ -354,6 +366,23 @@ export default { } }); }, + // 全线取消扣车 + cancelDetainTrainAll() { + const step = { + start: true, + code: `${this.selected.code}`, + operation: OperationEvent.StationStand.cancelDetainTrainAll.menu.operation, + param: { + standCode: `${this.selected.code}` + } + }; + this.$store.dispatch('training/next', step).then(({ valid }) => { + if (valid) { + this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); + this.$refs.standDetainTrainAll.doShow(step, this.selected); + } + }); + }, // 查询站台状态 detail() { const step = { From 39420c143264ebedd88bb23e62ef895a26e38811 Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Tue, 24 Mar 2020 09:23:24 +0800 Subject: [PATCH 13/14] =?UTF-8?q?=E5=AD=98=E5=9C=A8=E4=BB=BF=E7=9C=9F?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/simulation.js | 4 +- src/scripts/ConstConfig.js | 1 - src/views/system/existingSimulation/index.vue | 40 +++++-------------- 3 files changed, 13 insertions(+), 32 deletions(-) diff --git a/src/api/simulation.js b/src/api/simulation.js index a16d4132b..16e57f8ab 100644 --- a/src/api/simulation.js +++ b/src/api/simulation.js @@ -277,7 +277,7 @@ export function modifyScriptAction(group, actionId, data) { /** 分页查询存在的仿真 */ export function getExistingSimulation(params) { return request({ - url: `/api/simulation/manage/page`, + url: `/manage/simulation/exists`, method: 'get', params }); @@ -286,7 +286,7 @@ export function getExistingSimulation(params) { /** 删除存在的仿真 */ export function deleteExistingSimulation(group) { return request({ - url: `/api/simulation/manage/${group}`, + url: `/manage/simulation/${group}`, method: 'delete' }); } diff --git a/src/scripts/ConstConfig.js b/src/scripts/ConstConfig.js index 427ecf9c7..d65f84bd0 100644 --- a/src/scripts/ConstConfig.js +++ b/src/scripts/ConstConfig.js @@ -148,6 +148,5 @@ export default { { enlabel: 'Dispatch workstation', label: '派班工作站', value: '05'}, { enlabel: 'ISCS workstation', label: 'ISCS工作站', value: '06'} ] - } }; diff --git a/src/views/system/existingSimulation/index.vue b/src/views/system/existingSimulation/index.vue index ae09467ab..67f0d82fc 100644 --- a/src/views/system/existingSimulation/index.vue +++ b/src/views/system/existingSimulation/index.vue @@ -32,23 +32,12 @@ export default { type: 'text', label: this.$t('system.userName') }, - mobile: { - type: 'text', - label: this.$t('global.mobile') - }, prdType: { type: 'select', label: this.$t('system.prdType'), config: { data: [] } - }, - type: { - type: 'select', - label: this.$t('system.simulationType'), - config: { - data: this.$ConstSelect.SimulationType - } } } @@ -63,8 +52,8 @@ export default { prop: 'creator.name' }, { - title: this.$t('global.mobile'), - prop: 'creator.mobile' + title: this.$t('system.mapName'), + prop: 'map.name' }, { title: 'Group', @@ -82,14 +71,6 @@ export default { } } }, - { - title: this.$t('system.prdType'), - prop: 'prdType', - type: 'tag', - columnValue: (row) => { return this.$convertField(row.prdType, this.prdTypeList, ['value', 'label']); }, - tagType: (row) => { return ''; } - - }, { title: this.$t('system.isSuspend'), prop: 'pause', @@ -104,9 +85,9 @@ export default { }, { title: this.$t('system.isDrivingAsplanned'), - prop: 'runAsPlan', + prop: 'planRunning', type: 'tag', - columnValue: (row) => { return this.$ConstSelect.translate(row.runAsPlan, 'Whether'); }, + columnValue: (row) => { return this.$ConstSelect.translate(row.planRunning, 'Whether'); }, tagType: (row) => { switch (row.runAsPlan) { case true: return 'success'; @@ -115,17 +96,18 @@ export default { } }, { - title: this.$t('system.simulationType'), - prop: 'type', + title: this.$t('system.prdType'), + prop: 'prodType', type: 'tag', - columnValue: (row) => { return this.$convertField(row.type, this.$ConstSelect.SimulationType, ['value', 'label']); }, - tagType: (row) => { return 'success'; } + columnValue: (row) => { return this.$convertField(row.prodType, this.prdTypeList, ['value', 'label']); }, + tagType: (row) => { return ''; } + }, { title: this.$t('system.simulationGroupId'), - prop: 'sessionList', + prop: 'onlineUserIdList', type: 'basicText', - columnValue: (row) => { return this.listJoiningTogether(row.sessionList); } + columnValue: (row) => { return this.listJoiningTogether(row.onlineUserIdList); } }, { type: 'button', From e9aad944ae88fbc157eadb701bd5730f359efbca Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Tue, 24 Mar 2020 10:05:51 +0800 Subject: [PATCH 14/14] =?UTF-8?q?=E7=BB=98=E5=9B=BE=E7=BA=BF=E6=9D=A1?= =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../newMap/newMapdraft/mapoperate/line.vue | 35 ++++++++++++++++--- 1 file changed, 31 insertions(+), 4 deletions(-) diff --git a/src/views/newMap/newMapdraft/mapoperate/line.vue b/src/views/newMap/newMapdraft/mapoperate/line.vue index c073abf3e..fe73365c7 100644 --- a/src/views/newMap/newMapdraft/mapoperate/line.vue +++ b/src/views/newMap/newMapdraft/mapoperate/line.vue @@ -28,6 +28,9 @@ px + + + {{ $t('map.localCenter') }} @@ -62,14 +65,14 @@ icon="el-icon-plus" circle class="point-button" - @click="addPoint(addModel.points, index)" + @click="addPointAddModel(index)" /> @@ -125,6 +128,7 @@ export default { type: '', width: 1, showConditions: '01', + lineColor: 'rgba(255, 255, 255, 1)', points: [ { x: 0, y: 0 }, { x: 100, y: 100 } @@ -222,6 +226,25 @@ export default { delPoint(index) { this.editModel.points.splice(index + 1, 0); }, + addPointAddModel(index) { + const data = { x: 0, y: 0}; + this.addModel.points.splice(index + 1, 0, data); + }, + delPointAddModel(index) { + this.addModel.points.splice(index, 1); + }, + clear() { + this.addModel = { + type: '', + width: 1, + showConditions: '01', + lineColor: 'rgba(255, 255, 255, 1)', + points: [ + { x: 0, y: 0 }, + { x: 100, y: 100 } + ] + }; + }, create() { this.$refs['make'].validate((valid) => { if (valid) { @@ -232,10 +255,12 @@ export default { code: getUID('Line', this.lineList), type: this.addModel.type, width: this.addModel.width, - lineColor: '#FFFFFF', + showConditions: this.addModel.showConditions, + lineColor: this.addModel.lineColor, points: JSON.parse(pointArr) }; this.$emit('updateMapModel', model); + this.clear(); } else { this.$message.console.error(this.$t('tip.cannotCoincide')); @@ -302,7 +327,9 @@ export default { } .point-section { - float: left; + /*float: left;*/ + position: absolute; + left: 120px; width: calc(100% - 120px); }