Merge branch 'test' of https://git.code.tencent.com/lian-cbtc/jl-client into test
This commit is contained in:
commit
c55b7175e4
@ -36,6 +36,7 @@ class Signal extends Group {
|
|||||||
y: 0
|
y: 0
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
this.cbtcStatus = '';
|
||||||
this.create();
|
this.create();
|
||||||
this.createMouseEvent();
|
this.createMouseEvent();
|
||||||
this.transformRotation(this);
|
this.transformRotation(this);
|
||||||
@ -321,14 +322,18 @@ class Signal extends Group {
|
|||||||
this.lamps[0].setColor(this.style.Signal.lamp.grayColor);
|
this.lamps[0].setColor(this.style.Signal.lamp.grayColor);
|
||||||
this.insideTriangle.show();
|
this.insideTriangle.show();
|
||||||
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.redColor});
|
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.redColor});
|
||||||
|
if (this.cbtcStatus !== 'close') {
|
||||||
setTimeout(()=> {
|
setTimeout(()=> {
|
||||||
this.insideTriangle.setStyle({fill: '#000'});
|
this.insideTriangle.setStyle({fill: '#000'});
|
||||||
}, 500);
|
}, 1000);
|
||||||
setTimeout(()=> {
|
setTimeout(()=> {
|
||||||
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.redColor});
|
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.redColor});
|
||||||
}, 1000);
|
}, 2000);
|
||||||
|
}
|
||||||
|
this.cbtcStatus = 'close';
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
this.cbtcStatus = '';
|
||||||
if (this.count == 2) { // 双灯
|
if (this.count == 2) { // 双灯
|
||||||
this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.redColor);
|
this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.redColor);
|
||||||
this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor);
|
this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor);
|
||||||
@ -351,6 +356,7 @@ class Signal extends Group {
|
|||||||
this.lamps[0].setColor(this.style.Signal.lamp.grayColor);
|
this.lamps[0].setColor(this.style.Signal.lamp.grayColor);
|
||||||
this.insideTriangle.show();
|
this.insideTriangle.show();
|
||||||
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.greenColor});
|
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.greenColor});
|
||||||
|
if (this.cbtcStatus !== 'openPositive') {
|
||||||
setTimeout(()=> {
|
setTimeout(()=> {
|
||||||
this.insideTriangle.setStyle({fill: '#000'});
|
this.insideTriangle.setStyle({fill: '#000'});
|
||||||
}, 500);
|
}, 500);
|
||||||
@ -358,7 +364,10 @@ class Signal extends Group {
|
|||||||
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.greenColor});
|
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.greenColor});
|
||||||
}, 1000);
|
}, 1000);
|
||||||
}
|
}
|
||||||
|
this.cbtcStatus = 'openPositive';
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
|
this.cbtcStatus = '';
|
||||||
this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.greenColor);
|
this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.greenColor);
|
||||||
this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor); // 设置黑色
|
this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor); // 设置黑色
|
||||||
this.virtualSignal && this.virtualSignal.setColor(this.style.Signal.lamp.greenColor);
|
this.virtualSignal && this.virtualSignal.setColor(this.style.Signal.lamp.greenColor);
|
||||||
@ -378,14 +387,10 @@ class Signal extends Group {
|
|||||||
this.lamps[0].setColor(this.style.Signal.lamp.grayColor);
|
this.lamps[0].setColor(this.style.Signal.lamp.grayColor);
|
||||||
this.insideTriangle.show();
|
this.insideTriangle.show();
|
||||||
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.yellowColor});
|
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.yellowColor});
|
||||||
setTimeout(()=> {
|
this.cbtcStatus = 'openLateral';
|
||||||
this.insideTriangle.setStyle({fill: '#000'});
|
|
||||||
}, 1000);
|
|
||||||
setTimeout(()=> {
|
|
||||||
this.insideTriangle.setStyle({fill: this.style.Signal.lamp.yellowColor});
|
|
||||||
}, 2000);
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
this.cbtcStatus = '';
|
||||||
this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.yellowColor);
|
this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.yellowColor);
|
||||||
this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor);
|
this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor);
|
||||||
if (this.style.Signal.lamp.guidName === 'doubleAndBase') { // 设置底座颜色
|
if (this.style.Signal.lamp.guidName === 'doubleAndBase') { // 设置底座颜色
|
||||||
@ -408,6 +413,7 @@ class Signal extends Group {
|
|||||||
|
|
||||||
// 引导
|
// 引导
|
||||||
guid() {
|
guid() {
|
||||||
|
this.cbtcStatus = 'guid';
|
||||||
if (this.style.Signal.lamp.guidName === 'double') {
|
if (this.style.Signal.lamp.guidName === 'double') {
|
||||||
this.lamps[1].show();
|
this.lamps[1].show();
|
||||||
}
|
}
|
||||||
|
@ -3,6 +3,7 @@ import Text from 'zrender/src/graphic/Text';
|
|||||||
import LangStorage from '@/utils/lang';
|
import LangStorage from '@/utils/lang';
|
||||||
import Rect from 'zrender/src/graphic/shape/Rect';
|
import Rect from 'zrender/src/graphic/shape/Rect';
|
||||||
import store from '@/store/index_APP_TARGET';
|
import store from '@/store/index_APP_TARGET';
|
||||||
|
import Vue from 'vue';
|
||||||
|
|
||||||
class EMouse extends Group {
|
class EMouse extends Group {
|
||||||
constructor(device) {
|
constructor(device) {
|
||||||
@ -33,9 +34,13 @@ class EMouse extends Group {
|
|||||||
direction = this.device.model.right != 1;
|
direction = this.device.model.right != 1;
|
||||||
}
|
}
|
||||||
if (LangStorage.getLang() == 'en') {
|
if (LangStorage.getLang() == 'en') {
|
||||||
text = ` The planned train: ${trainType} \n Table No.: ${this.device.model.serviceNumber} \n Train Trip No.: ${this.device.model.tripNumber}\n Destination: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n Train No.: ${this.device.model.groupNumber}\n Early or late: ${destinationText}\n Direction: ${direction ? 'up' : 'down'}\n Crew No.: \n Start Station: \n Terminal Station: \n Occupied Track: ${this.device.model.sectionModel ? this.device.model.sectionModel.name : ''}\n Current Station: \n Train-ground communication: normal \n Operation Speed level: 4 \n Detained: ${this.device.model.hold ? 'Detained' : 'Normal'}\n \n 跳停状态: ${this.device.model.jump ? 'Skip to continue moving' : 'Normal'}Stationary: ${!this.device.model.stop ? 'No' : 'Yes'}\n Blocked: No \n Speed: ${this.device.model.speed || 0} km/h \n Authorized Distance: ${this.device.model.maLen || 0} m`;
|
text = ` The planned train: ${trainType} \n Table No.: ${this.device.model.serviceNumber} \n Train Trip No.: ${this.device.model.tripNumber}\n Destination: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n Train No.: ${this.device.model.groupNumber}\n Early or late: ${destinationText}\n Direction: ${direction ? 'up' : 'down'}\n Crew No.: \n Start Station: \n Terminal Station: \n Occupied Track: ${this.device.model.sectionModel ? this.device.model.sectionModel.parentName : ''}\n Current Station: \n Train-ground communication: normal \n Operation Speed level: 4 \n Detained: ${this.device.model.hold ? 'Detained' : 'Normal'}\n \n 跳停状态: ${this.device.model.jump ? 'Skip to continue moving' : 'Normal'}Stationary: ${!this.device.model.stop ? 'No' : 'Yes'}\n Blocked: No \n Speed: ${this.device.model.speed || 0} km/h \n Authorized Distance: ${this.device.model.maLen || 0} m`;
|
||||||
} else {
|
} else {
|
||||||
text = `列车类型: ${trainType} \n表\0\0\0\0号: ${this.device.model.serviceNumber}\n车\0次\0号: ${this.device.model.tripNumber}\n目的地号: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n车\0组\0号: ${this.device.model.groupNumber}\n早\0晚\0点: ${destinationText}\n运行方向: ${direction ? '上行' : '下行'}\n乘务组号: \n起点站名: \n终点站名: \n占用轨道: ${this.device.model.sectionModel ? this.device.model.sectionModel.name : ''}\n所在车站: \n车地通信: 正常\n运行等级: 4\n扣车状态: ${ this.device.model.hold ? '扣车' : '正常'}\n跳停状态: ${this.device.model.jump ? '跳停' : '正常'} \n停稳状态: ${!this.device.model.stop ? '未停稳' : '停稳'}\n阻塞状态: 无\n列车速度: ${this.device.model.speed || 0} km/h\n列车移动授权距离: ${this.device.model.maLen || 0} m`;
|
if (Vue.prototype.$jlmap.lineCode == '11' || Vue.prototype.$jlmap.lineCode == '10') {
|
||||||
|
text = `列车类型: ${trainType}\n来\0\0\0\0源:人工标记\n车\0组\0号: ${this.device.model.groupNumber}\n表\0\0\0\0号: ${this.device.model.serviceNumber}\n车\0次\0号: ${this.device.model.tripNumber}\n目的地号: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n早\0晚\0点: ${destinationText}\n运行方向: ${direction ? '上行' : '下行'}\nATP报告方向: ${direction ? '上行' : '下行'}\n起点站名: \n终点站名: \n占用轨道: ${this.device.model.sectionModel ? this.device.model.sectionModel.parentName : ''}\n所在车站: \n车次通信: 通信车\n运行时间: \n停站时间: \n扣车状态: ${ this.device.model.hold ? '扣车' : '正常'}\n车戴扣车: 不执行\n跳停状态: 无跳停\n停稳状态: ${!this.device.model.stop ? '未停稳' : '停稳'}\n阻塞状态: 无\n列车状态: CTC车\n最高信号系统控制: CTC\n驾驶模式: SM模式\n最高ATP模式: AM\nATP1状态: 激活\nATP2状态: 备用\n速度: ${this.device.model.speed || 0} km/h\n车门状态: ${this.device.model.speed ? '关闭' : direction ? '左开右关' : '左关右开'}\n制动状态: 无紧急制动\n停车保证: 可保证停车\n站台无法进入: 否\n前方站台停车点: 中间\n折法策略: \n折返状态: \n屏蔽门开门许可: 是\n运营里程: 无效\n总重量: 196T\n车长: 11860cm\n列车编组: 1`;
|
||||||
|
} else {
|
||||||
|
text = `列车类型: ${trainType} \n表\0\0\0\0号: ${this.device.model.serviceNumber}\n车\0次\0号: ${this.device.model.tripNumber}\n目的地号: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n车\0组\0号: ${this.device.model.groupNumber}\n早\0晚\0点: ${destinationText}\n运行方向: ${direction ? '上行' : '下行'}\n乘务组号: \n起点站名: \n终点站名: \n占用轨道: ${this.device.model.sectionModel ? this.device.model.sectionModel.parentName : ''}\n所在车站: \n车地通信: 正常\n运行等级: 4\n扣车状态: ${ this.device.model.hold ? '扣车' : '正常'}\n跳停状态: ${this.device.model.jump ? '跳停' : '正常'} \n停稳状态: ${!this.device.model.stop ? '未停稳' : '停稳'}\n阻塞状态: 无\n列车速度: ${this.device.model.speed || 0} km/h\n列车移动授权距离: ${this.device.model.maLen || 0} m`;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
const trainTip = this.device.style.Train.common.trainTip;
|
const trainTip = this.device.style.Train.common.trainTip;
|
||||||
if (trainTip) {
|
if (trainTip) {
|
||||||
|
@ -47,6 +47,12 @@ export function parser(data, skinCode, showConfig) {
|
|||||||
mapDevice[elem.code] = createDevice(deviceType.Section, elem, propConvert, showConfig);
|
mapDevice[elem.code] = createDevice(deviceType.Section, elem, propConvert, showConfig);
|
||||||
}, this);
|
}, this);
|
||||||
|
|
||||||
|
zrUtil.each(data.sectionList || [], elem => {
|
||||||
|
if (elem.type == '02' || elem.type == '03') {
|
||||||
|
mapDevice[elem.code].parentName = mapDevice[mapDevice[elem.code].parentCode].name;
|
||||||
|
}
|
||||||
|
}, this);
|
||||||
|
|
||||||
zrUtil.each(data.signalList || [], elem => {
|
zrUtil.each(data.signalList || [], elem => {
|
||||||
mapDevice[elem.code] = createDevice(deviceType.Signal, elem, propConvert, showConfig);
|
mapDevice[elem.code] = createDevice(deviceType.Signal, elem, propConvert, showConfig);
|
||||||
}, this);
|
}, this);
|
||||||
|
Loading…
Reference in New Issue
Block a user