项目登录仿真里的返回按钮点击无效&prdType转换

This commit is contained in:
fan 2022-11-08 10:53:07 +08:00
parent fe68d15acf
commit 4438debc22
12 changed files with 23 additions and 38 deletions

View File

@ -84,7 +84,7 @@ class EHorizontal2Door extends Group {
this.stand2.setStyle('fill', style.Psd.horizontal2Door.defaultColor);
}
}
if (model.noStatus || (model.atsNoStatus && store.state.training.prdType == '02')) {
if (model.noStatus || (model.atsNoStatus && store.state.map.picture === 'dispatchWork')) {
this.stand1.setStyle('fill', '#7F7F7F');
this.stand2.setStyle('fill', '#7F7F7F');
}

View File

@ -51,7 +51,7 @@ class ERect2Door extends Group {
this.psd.setStyle('fill', style.Psd.rectDoor.defaultColor);
}
}
if (model.noStatus || (model.atsNoStatus && store.state.training.prdType == '02')) {
if (model.noStatus || (model.atsNoStatus && store.state.map.picture === 'dispatchWork')) {
this.psd.setStyle('fill', '#7F7F7F');
}
}

View File

@ -578,7 +578,7 @@ export default class Section extends Group {
// 区段延时解锁
model.remain > 0 && this.delayUnlock();
// 设置灰显
if (model.noStatus || (model.atsNoStatus && store.state.training.prdType == '02')) {
if (model.noStatus || (model.atsNoStatus && store.state.map.picture === 'dispatchWork')) {
this.setAshShow();
}
// 设置脱轨器

View File

@ -1210,7 +1210,7 @@ class Signal extends Group {
}
this.model.virtual && this.sigBack && this.sigBack.show();
// 设置灰显
if (model.noStatus || (model.atsNoStatus && store.state.training.prdType == '02')) {
if (model.noStatus || (model.atsNoStatus && store.state.map.picture === 'dispatchWork')) {
this.setAshShow();
}
@ -1218,7 +1218,7 @@ class Signal extends Group {
if (this.style.Signal.text.conflictColor && model.checkConflict) {
this.sigName.setColor(this.style.Signal.text.conflictColor);
}
if (store.state.training.prdType === '01') {
if (store.state.map.picture === 'localWork') {
this.lowButton && this.lowButton.show();
}
}

View File

@ -55,7 +55,7 @@ class ETrainSetButton extends Group {
}
setState(model) {
if (model.noStatus || (model.atsNoStatus && store.state.training.prdType == '02')) {
if (model.noStatus || (model.atsNoStatus && store.state.map.picture === 'dispatchWork')) {
this.setColor('#7F7F7F');
}
}

View File

@ -159,7 +159,7 @@ class StationStand extends Group {
this.downDetainLamp && this.downDetainLamp.hide();
}
setScreenDoorOpenStatus(model) {
if (!this.model.noStatus && !(this.model.atsNoStatus && store.state.training.prdType == '02')) {
if (!this.model.noStatus && !(this.model.atsNoStatus && store.state.map.picture === 'dispatchWork')) {
this.gapStand && this.gapStand.setState(model);
}
}
@ -183,7 +183,7 @@ class StationStand extends Group {
currentTypeList.forEach(element => {
this[element].setState(model);
});
if (store.state.training.prdType === '01') {
if (store.state.map.picture === 'localWork') {
this.stopJumpLamp && this.stopJumpLamp.show();
this.cancelStopJumpLamp && this.cancelStopJumpLamp.show();
this.upDetainLamp && this.upDetainLamp.show();

View File

@ -110,7 +110,7 @@ class EGapStand extends Group {
this.setClose();
}
}
if (model.noStatus || (model.atsNoStatus && store.state.training.prdType == '02')) {
if (model.noStatus || (model.atsNoStatus && store.state.map.picture === '02')) {
this.setColor('#7F7F7F');
}
}

View File

@ -877,7 +877,7 @@ export default class Switch extends Group {
const sectionC = this.mapDevice[switchModel.sectionCCode];
sectionC && sectionC.instance && sectionC.instance.handleSwitchSection(sectionC);
}
if (model.noStatus || (model.atsNoStatus && store.state.training.prdType == '02')) {
if (model.noStatus || (model.atsNoStatus && store.state.map.picture === 'dispatchWork')) {
this.setAshShow();
}
!model.auto && this.artificialArc && this.artificialArc.show();

View File

@ -4,34 +4,25 @@ export default class EMouse {
}
mouseover(e) {
if (this.device.prdType) {
this.device.setVisible(true);
const instance = this.device.getInstanceByCode(this.device.model.sectionCode);
if (instance && instance.mouseEvent && instance.mouseEvent.mouseover) {
instance.mouseEvent.mouseEnter(e);
}
this.device.setVisible(true);
const instance = this.device.getInstanceByCode(this.device.model.sectionCode);
if (instance && instance.mouseEvent && instance.mouseEvent.mouseover) {
instance.mouseEvent.mouseEnter(e);
}
}
mouseout(e) {
if (this.device.prdType) {
this.device.setVisible(false);
const instance = this.device.getInstanceByCode(this.device.model.sectionCode);
if (instance && instance.mouseEvent && instance.mouseEvent.mouseout) {
instance.mouseEvent.mouseLeave(e);
}
this.device.setVisible(false);
const instance = this.device.getInstanceByCode(this.device.model.sectionCode);
if (instance && instance.mouseEvent && instance.mouseEvent.mouseout) {
instance.mouseEvent.mouseLeave(e);
}
}
mouseEnter() {
// if (this.device.prdType) {
// this.device.setVisible(true);
// }
}
mouseLeave() {
if (this.device.prdType ) {
this.device.setVisible(false);
}
this.device.setVisible(false);
}
}

View File

@ -23,13 +23,12 @@ class TrainWindow extends Group {
this.model = model;
this.style = style;
this.z = 9;
this.prdType = store.state.training.prdType;
this.create();
this.createMouseEvent();
this.setState(model);
}
create() {
if (this.prdType !== '01') {
if (store.state.map.picture !== 'localWork') {
this.createTrainWindow();
}
}

View File

@ -707,14 +707,8 @@ export default {
});
}
} else {
// || this.isCtc
if (this.project === 'bjd') {
window.close();
} else {
// this.$store.dispatch('map/setShowCentralizedStationCode', '');
history.go(-1);
Notification.closeAll();
}
history.go(-1);
Notification.closeAll();
}
},
//

View File

@ -4,6 +4,7 @@
<div ref="drapBox" class="reminder-box">
<div class="tip-title">
<div>
<i class="icon el-icon-tickets" />
<i v-show="isShrink" class="icon el-icon-minus" @click="shrink" />
<i v-show="!isShrink" class="icon el-icon-plus" @click="shrink" />
<i v-show="!isShrink && !trainingSwitch && trainingDetail" class="icon el-icon-video-play" @click="handlerStart" />