成都一号线 列车所在区段位置代码调整(部分)
This commit is contained in:
parent
93be0b7ff6
commit
4c02e416bc
@ -135,6 +135,9 @@ class SkinCode extends defaultStyle {
|
|||||||
},
|
},
|
||||||
block: {
|
block: {
|
||||||
special: false, // 区段特殊显示
|
special: false, // 区段特殊显示
|
||||||
|
},
|
||||||
|
trainPosition:{
|
||||||
|
display: false // 列车实时位置显示
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -135,6 +135,9 @@ class SkinCode extends defaultStyle {
|
|||||||
},
|
},
|
||||||
block: {
|
block: {
|
||||||
special: false, // 区段特殊显示
|
special: false, // 区段特殊显示
|
||||||
|
},
|
||||||
|
trainPosition:{
|
||||||
|
display: true // 列车实时位置显示
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -138,6 +138,9 @@ class SkinCode extends defaultStyle {
|
|||||||
},
|
},
|
||||||
block: {
|
block: {
|
||||||
special: false, // 区段特殊显示
|
special: false, // 区段特殊显示
|
||||||
|
},
|
||||||
|
trainPosition:{
|
||||||
|
display: false // 列车实时位置显示
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -128,6 +128,9 @@ class SkinCode extends defaultStyle {
|
|||||||
},
|
},
|
||||||
block: {
|
block: {
|
||||||
special: false, // 区段特殊显示
|
special: false, // 区段特殊显示
|
||||||
|
},
|
||||||
|
trainPosition:{
|
||||||
|
display: false // 列车实时位置显示
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -128,6 +128,9 @@ class SkinCode extends defaultStyle {
|
|||||||
},
|
},
|
||||||
block: {
|
block: {
|
||||||
special: true, // 区段特殊显示
|
special: true, // 区段特殊显示
|
||||||
|
},
|
||||||
|
trainPosition:{
|
||||||
|
display: false // 列车实时位置显示
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -136,6 +136,9 @@ class SkinCode extends defaultStyle {
|
|||||||
block: {
|
block: {
|
||||||
special: false, // 区段特殊显示
|
special: false, // 区段特殊显示
|
||||||
blockGlint: true, // 区段封锁闪烁显示
|
blockGlint: true, // 区段封锁闪烁显示
|
||||||
|
},
|
||||||
|
trainPosition:{
|
||||||
|
display: false // 列车实时位置显示
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -148,7 +148,7 @@ class Painter {
|
|||||||
try {
|
try {
|
||||||
if (device._dispose) {
|
if (device._dispose) {
|
||||||
this.delete(device);
|
this.delete(device);
|
||||||
} else if (deviceType.Train == device._type) {
|
} else if (deviceType.Train.toUpperCase() == device.deviceType) {
|
||||||
this.updateTrain(device);
|
this.updateTrain(device);
|
||||||
} else {
|
} else {
|
||||||
const instance = device.instance;
|
const instance = device.instance;
|
||||||
|
@ -3,6 +3,8 @@ import TrainHead from './TrainHead';
|
|||||||
import TrainBody from './TrainBody';
|
import TrainBody from './TrainBody';
|
||||||
import BoundingRect from 'zrender/src/core/BoundingRect';
|
import BoundingRect from 'zrender/src/core/BoundingRect';
|
||||||
import Rect from 'zrender/src/graphic/shape/Rect';
|
import Rect from 'zrender/src/graphic/shape/Rect';
|
||||||
|
import { deepAssign } from '@/utils/index';
|
||||||
|
import store from '@/store';
|
||||||
|
|
||||||
/** 列车 */
|
/** 列车 */
|
||||||
export default class Train extends Group {
|
export default class Train extends Group {
|
||||||
@ -115,6 +117,18 @@ export default class Train extends Group {
|
|||||||
getShapeTipPoint() {
|
getShapeTipPoint() {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
updateSection() {
|
||||||
|
const train = this.model;
|
||||||
|
if (train.physicalCode && train.offsetp) {
|
||||||
|
const data = train.physicalCode;
|
||||||
|
const oldmodel = store.getters['map/getDeviceByCode'](data);
|
||||||
|
let models = [];
|
||||||
|
const model = deepAssign(oldmodel, {_type: 'Section'}); // 修改元素model
|
||||||
|
models = [model];
|
||||||
|
store.dispatch('map/updateMapDevices', models);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 恢复颜色状态
|
// 恢复颜色状态
|
||||||
recover() {
|
recover() {
|
||||||
this.trainB && this.trainB.setHShow(false);
|
this.trainB && this.trainB.setHShow(false);
|
||||||
@ -309,6 +323,11 @@ export default class Train extends Group {
|
|||||||
this.setCommunicationStatus(model.runLevel);
|
this.setCommunicationStatus(model.runLevel);
|
||||||
// this.setTrainTypeStatus(model.type); 配合早晚点设置
|
// this.setTrainTypeStatus(model.type); 配合早晚点设置
|
||||||
this.setDoorStatus(model.doorCloseLock);
|
this.setDoorStatus(model.doorCloseLock);
|
||||||
|
|
||||||
|
const style = this.style;
|
||||||
|
if (style.Section.trainPosition.display) {
|
||||||
|
this.updateSection();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// let points = [];
|
// let points = [];
|
||||||
// if (model) {
|
// if (model) {
|
||||||
|
@ -153,7 +153,6 @@ export default {
|
|||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'$store.state.menuOperation.menuCount': function (val) {
|
'$store.state.menuOperation.menuCount': function (val) {
|
||||||
debugger;
|
|
||||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Signal) && !this.buttonOperation) {
|
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Signal) && !this.buttonOperation) {
|
||||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
this.doShow(this.$store.state.menuOperation.menuPosition);
|
||||||
} else {
|
} else {
|
||||||
|
@ -191,7 +191,6 @@ export default {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case OperationEvent.Switch.lock.button.operation: {
|
case OperationEvent.Switch.lock.button.operation: {
|
||||||
debugger;
|
|
||||||
// 道岔单锁
|
// 道岔单锁
|
||||||
if (!selectType.singleLock) {
|
if (!selectType.singleLock) {
|
||||||
this.lock(selectType);
|
this.lock(selectType);
|
||||||
|
@ -388,7 +388,6 @@ export default {
|
|||||||
this.stationName = station.name;
|
this.stationName = station.name;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
debugger;
|
|
||||||
if (this.operation == OperationEvent.StationStand.setJumpStop.menu.operation || this.operation == OperationEvent.StationStand.setJumpStop.menu.operation) {
|
if (this.operation == OperationEvent.StationStand.setJumpStop.menu.operation || this.operation == OperationEvent.StationStand.setJumpStop.menu.operation) {
|
||||||
this.radio = selected.direction;
|
this.radio = selected.direction;
|
||||||
} else if (this.operation == OperationEvent.StationStand.setStopTime.menu.operation) {
|
} else if (this.operation == OperationEvent.StationStand.setStopTime.menu.operation) {
|
||||||
|
Loading…
Reference in New Issue
Block a user