This commit is contained in:
ival 2021-03-10 15:09:24 +08:00
commit 3759386e1f
6 changed files with 142 additions and 122 deletions

View File

@ -276,7 +276,7 @@ export default class ELines extends Group {
}
this.runLine = new Polyline({
zlevel: this.zlevel,
progressive: model.progressive,
// progressive: model.progressive,
z: Z + 2,
shape: {
points: points
@ -426,10 +426,12 @@ export default class ELines extends Group {
setRunLineDefault() {
this.runLine && this.runLine.hide();
this.runLine.dirty();
}
runLineShow() {
this.runLine && this.runLine.show();
this.runLine.dirty();
}
hide() {
@ -565,13 +567,13 @@ export default class ELines extends Group {
}
}
addHover(style) {
this.__zr && this.__zr.addHover(this.section, style);
}
addHover(style) {
this.__zr && this.__zr.addHover(this.section, style);
}
removeHover() {
this.__zr && this.__zr.removeHover(this.section);
}
removeHover() {
this.__zr && this.__zr.removeHover(this.section);
}
recover() {

View File

@ -256,19 +256,9 @@ export default class Section extends Group {
showRunLine() {
this.line && this.line.runLineShow();
if (this.model.code == 'T5') {
console.log(this.line, 'T5');
} else if (this.model.code == 'T10') {
console.log(this.line, 'T10');
}
}
setRunLineDefault() {
this.line && this.line.setRunLineDefault();
if (this.model.code == 'T5') {
console.log(this.line, 'T5', 'default');
} else if (this.model.code == 'T10') {
console.log(this.line, 'T10', 'default');
}
}
/** 保护区段锁闭 09*/

View File

@ -303,7 +303,7 @@ export default {
{ deviceType: '03', orderNum: 4, operateCode: '4072', tip: '鼠标左键点击【确认】按钮' },
{ deviceType: '03', orderNum: 5, operateCode: '4073', tip: '鼠标左键点击【确认1】按钮' },
{ deviceType: '03', orderNum: 6, operateCode: '4074', tip: '鼠标左键点击【确认2】按钮', val: '5' },
{ deviceType: '03', orderNum: 7, operateCode: '001', tip: '鼠标左键点击【关闭】按钮' },
{ deviceType: '03', orderNum: 7, operateCode: '001', tip: '鼠标左键点击【关闭】按钮' }
]
},
{
@ -322,7 +322,7 @@ export default {
{ deviceType: '03', orderNum: 3, operateCode: '4082', tip: '鼠标左键点击【确认】按钮' },
{ deviceType: '03', orderNum: 4, operateCode: '4083', tip: '鼠标左键点击【确认1】按钮' },
{ deviceType: '03', orderNum: 5, operateCode: '4084', tip: '鼠标左键点击【确认2】按钮', val: '0' },
{ deviceType: '03', orderNum: 6, operateCode: '001', tip: '鼠标左键点击【关闭】按钮' },
{ deviceType: '03', orderNum: 6, operateCode: '001', tip: '鼠标左键点击【关闭】按钮' }
]
},
{
@ -721,10 +721,10 @@ export default {
productTypes: ['01'],
stepVOList: [
{ deviceType: '04', orderNum: 1, operateCode: '308', tip: '鼠标右键菜单选择【引导】' },
{ deviceType: '04', orderNum: 2, operateCode: '0011', tip: '请输入密码"root",点击【确认】按钮', val: 'root' },
{ deviceType: '04', orderNum: 3, operateCode: '308', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '04', orderNum: 2, operateCode: '0011', tip: '请输入密码"root",点击【确认】按钮', val: 'root' },
{ deviceType: '04', orderNum: 3, operateCode: '308', tip: '鼠标左键点击【确定】按钮' }
],
config: {onlySignalOP:true}
config: {onlySignalOP:true}
},
{
maxDuration: 15,
@ -795,7 +795,7 @@ export default {
trainingName: '请求站控({1})',
trainingRemark: '控制权限转换,中控转站控',
trainingType: 'ControlConvertMenu',
productTypes: ['01','02'], // 现地请求站控
productTypes: ['01', '02'], // 现地请求站控
stepVOList: [
{ deviceType: 'button', orderNum: 1, operateCode: '202', tip: '鼠标右键菜单选择【请求站控】'},
{ deviceType: '05', orderNum: 2, operateCode: '2023', tip: '鼠标左键点击【应用】按钮' }
@ -903,7 +903,7 @@ export default {
],
config:{tbStrategyBT:true}
},
{
{
maxDuration: 15,
minDuration: 8,
operateType: 'Station_Set_Or_Cancel_Force_Physical_Signal',
@ -914,15 +914,15 @@ export default {
productTypes: ['01', '02'],
stepVOList: [
{ deviceType: '05', orderNum: 1, operateCode: '1100', tip: '鼠标右键菜单选择【设置/取消强制点灯】', subType: 'light'},
{ deviceType: '05', orderNum: 2, operateCode: '0011', tip: '请输入密码"root",点击【确认】按钮', val: 'root' },
{ deviceType: '05', orderNum: 3, operateCode: '11002', tip: '鼠标左键点击【是】按钮' },
{ deviceType: '05', orderNum: 4, operateCode: 'com08', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '05', orderNum: 5, operateCode: 'com02', tip: '请选择【强制点灯】选项', val: '5' },
{ deviceType: '05', orderNum: 6, operateCode: 'com13', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '05', orderNum: 2, operateCode: '0011', tip: '请输入密码"root",点击【确认】按钮', val: 'root' },
{ deviceType: '05', orderNum: 3, operateCode: '11002', tip: '鼠标左键点击【是】按钮' },
{ deviceType: '05', orderNum: 4, operateCode: 'com08', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '05', orderNum: 5, operateCode: 'com02', tip: '请选择【强制点灯】选项', val: '5' },
{ deviceType: '05', orderNum: 6, operateCode: 'com13', tip: '鼠标左键点击【确定】按钮' }
],
config:{tbStrategyBT:true}
},
{
{
maxDuration: 15,
minDuration: 8,
operateType: 'Station_Open_Auto_Setting',
@ -936,86 +936,86 @@ export default {
{ deviceType: '05', orderNum: 2, operateCode: '606', tip: '鼠标左键点击【确定】', val: 'true' }
]
},
// 新增
// 区段计轴复位的操作是一个单独类型设备因此不能直接配置成Section暂不支持
// {
// maxDuration: 15,
// minDuration: 8,
// operateType: 'Section_Axis_Pre_Reset',
// skinCode: '06',
// trainingName: '计轴复位({8}{9})',
// trainingRemark: '计轴复位功能',
// trainingType: 'Section',
// productTypes: ['01'],
// stepVOList: [
// { deviceType: '03', orderNum: 1, operateCode: '1000', tip: '鼠标右键点击菜单【计轴复位】'},
// { deviceType: '03', orderNum: 2, operateCode: '10001', tip: '请选择区段【({8}{9})】' },
// { deviceType: '03', orderNum: 3, operateCode: '1000', tip: '鼠标左键点击【确定】按钮' },
// ]
// },
// {
// maxDuration: 15,
// minDuration: 8,
// operateType: 'Station_Pre_Reset',
// skinCode: '06',
// trainingName: '设置计轴复位({26})',
// trainingRemark: '计轴复位功能',
// trainingType: 'Station',
// productTypes: ['01'],
// stepVOList: [
// { deviceType: '05', orderNum: 1, operateCode: '1000', tip: '鼠标右键点击菜单【设置】'},
// { deviceType: '05', orderNum: 2, operateCode: '10002', tip: '鼠标左键点击【确定】按钮' },
// { deviceType: '05', orderNum: 3, operateCode: 'com16', tip: '鼠标左键点击【执行】按钮' },
// ]
// },
// {
// maxDuration: 15,
// minDuration: 8,
// operateType: 'Station_Cancel_Pre_Reset',
// skinCode: '06',
// trainingName: '取消计轴复位({26})',
// trainingRemark: '计轴复位功能',
// trainingType: 'Station',
// productTypes: ['01'],
// stepVOList: [
// { deviceType: '05', orderNum: 1, operateCode: '1000', tip: '鼠标右键点击菜单【取消】'},
// { deviceType: '05', orderNum: 2, operateCode: '10002', tip: '鼠标左键点击【确定】按钮' },
// ]
// },
{
maxDuration: 15,
minDuration: 8,
operateType: 'Cancel_All_Limit_Speed',
skinCode: '06',
trainingName: '取消全线临时限速({26})',
trainingRemark: '取消全线临时限速',
trainingType: 'LimitControl',
productTypes: ['02'],
stepVOList: [
{ deviceType: '05', orderNum: 1, operateCode: '800', tip: '鼠标右键点击菜单【取消全线临时限速】'},
{ deviceType: '05', orderNum: 2, operateCode: '8001', tip: '鼠标左键点击【打开会话】按钮' },
{ deviceType: '05', orderNum: 3, operateCode: '8003', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '05', orderNum: 4, operateCode: '8004', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '05', orderNum: 5, operateCode: '8005', tip: '鼠标左键点击【关闭】按钮' },
{ deviceType: '05', orderNum: 6, operateCode: '8006', tip: '鼠标左键点击【确定】按钮' },
]
},
{
maxDuration: 15,
minDuration: 8,
operateType: 'Station_Open_Auto_Setting',
skinCode: '06',
trainingName: '{26}全站进路交自动控',
trainingRemark: '全站进路交自动控',
trainingType: 'Station',
productTypes: ['01'],
stepVOList: [
{ deviceType: 'bar', orderNum: 1, operateCode: '002c', tip: '鼠标左键点击菜单【批处理命令】', codeType: 'NULL'},
{ deviceType: 'bar', orderNum: 2, operateCode: '6062', tip: '鼠标左键点击菜单【{26}全站进路交自动控】' },
{ deviceType: '05', orderNum: 3, operateCode: '6063', tip: '鼠标左键点击【确定】按钮' }
],
},
{
// 新增
// 区段计轴复位的操作是一个单独类型设备因此不能直接配置成Section暂不支持
// {
// maxDuration: 15,
// minDuration: 8,
// operateType: 'Section_Axis_Pre_Reset',
// skinCode: '06',
// trainingName: '计轴复位({8}{9})',
// trainingRemark: '计轴复位功能',
// trainingType: 'Section',
// productTypes: ['01'],
// stepVOList: [
// { deviceType: '03', orderNum: 1, operateCode: '1000', tip: '鼠标右键点击菜单【计轴复位】'},
// { deviceType: '03', orderNum: 2, operateCode: '10001', tip: '请选择区段【({8}{9})】' },
// { deviceType: '03', orderNum: 3, operateCode: '1000', tip: '鼠标左键点击【确定】按钮' },
// ]
// },
// {
// maxDuration: 15,
// minDuration: 8,
// operateType: 'Station_Pre_Reset',
// skinCode: '06',
// trainingName: '设置计轴复位({26})',
// trainingRemark: '计轴复位功能',
// trainingType: 'Station',
// productTypes: ['01'],
// stepVOList: [
// { deviceType: '05', orderNum: 1, operateCode: '1000', tip: '鼠标右键点击菜单【设置】'},
// { deviceType: '05', orderNum: 2, operateCode: '10002', tip: '鼠标左键点击【确定】按钮' },
// { deviceType: '05', orderNum: 3, operateCode: 'com16', tip: '鼠标左键点击【执行】按钮' },
// ]
// },
// {
// maxDuration: 15,
// minDuration: 8,
// operateType: 'Station_Cancel_Pre_Reset',
// skinCode: '06',
// trainingName: '取消计轴复位({26})',
// trainingRemark: '计轴复位功能',
// trainingType: 'Station',
// productTypes: ['01'],
// stepVOList: [
// { deviceType: '05', orderNum: 1, operateCode: '1000', tip: '鼠标右键点击菜单【取消】'},
// { deviceType: '05', orderNum: 2, operateCode: '10002', tip: '鼠标左键点击【确定】按钮' },
// ]
// },
{
maxDuration: 15,
minDuration: 8,
operateType: 'Cancel_All_Limit_Speed',
skinCode: '06',
trainingName: '取消全线临时限速({26})',
trainingRemark: '取消全线临时限速',
trainingType: 'LimitControl',
productTypes: ['02'],
stepVOList: [
{ deviceType: '05', orderNum: 1, operateCode: '800', tip: '鼠标右键点击菜单【取消全线临时限速】'},
{ deviceType: '05', orderNum: 2, operateCode: '8001', tip: '鼠标左键点击【打开会话】按钮' },
{ deviceType: '05', orderNum: 3, operateCode: '8003', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '05', orderNum: 4, operateCode: '8004', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '05', orderNum: 5, operateCode: '8005', tip: '鼠标左键点击【关闭】按钮' },
{ deviceType: '05', orderNum: 6, operateCode: '8006', tip: '鼠标左键点击【确定】按钮' }
]
},
{
maxDuration: 15,
minDuration: 8,
operateType: 'Station_Open_Auto_Setting',
skinCode: '06',
trainingName: '{26}全站进路交自动控',
trainingRemark: '全站进路交自动控',
trainingType: 'Station',
productTypes: ['01'],
stepVOList: [
{ deviceType: 'bar', orderNum: 1, operateCode: '002c', tip: '鼠标左键点击菜单【批处理命令】', codeType: 'NULL'},
{ deviceType: 'bar', orderNum: 2, operateCode: '6062', tip: '鼠标左键点击菜单【{26}全站进路交自动控】' },
{ deviceType: '05', orderNum: 3, operateCode: '6063', tip: '鼠标左键点击【确定】按钮' }
]
},
{
maxDuration: 15,
minDuration: 8,
operateType: 'Station_Set_CI_Auto',
@ -1026,11 +1026,11 @@ export default {
productTypes: ['01'],
stepVOList: [
{ deviceType: 'bar', orderNum: 1, operateCode: '002c', tip: '鼠标左键点击菜单【批处理命令】', codeType: 'NULL'},
{ deviceType: 'bar', orderNum: 2, operateCode: '6141', tip: '鼠标左键点击菜单【设置{26}全站自动通过进路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: '6141', tip: '鼠标左键点击菜单【设置{26}全站自动通过进路】' },
{ deviceType: '05', orderNum: 3, operateCode: '6142', tip: '鼠标左键点击【确定】按钮' }
],
},
{
]
},
{
maxDuration: 15,
minDuration: 8,
operateType: 'Station_Cancel_CI_Auto',
@ -1041,10 +1041,10 @@ export default {
productTypes: ['01'],
stepVOList: [
{ deviceType: 'mbm', orderNum: 1, operateCode: '002c', tip: '鼠标左键点击菜单【批处理命令】', codeType: 'NULL'},
{ deviceType: 'mbm', orderNum: 2, operateCode: '6151', tip: '鼠标左键点击菜单【取消{26}全站自动通过进路】' },
{ deviceType: 'mbm', orderNum: 2, operateCode: '6151', tip: '鼠标左键点击菜单【取消{26}全站自动通过进路】' },
{ deviceType: '05', orderNum: 3, operateCode: '6152', tip: '鼠标左键点击【确定】按钮' }
],
},
]
},
// {
// maxDuration: 15,
// minDuration: 8,

View File

@ -231,7 +231,6 @@ export default {
},
handleChange(row) {
if (row) {
debugger;
const runPath = row.runPath;
if (runPath && runPath.length > 0) {
const step = {
@ -241,13 +240,39 @@ export default {
};
this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) {
const oldRunPath = this.$store.state.training.runPathList;
this.setRunPath(oldRunPath, false);
this.setRunPath(runPath, true);
const oldRunPath = [...this.$store.state.training.runPathList];
// this.setRunPath(oldRunPath, false);
// // this.$nextTick(()=>{
// // this.setRunPath(runPath, true);
// // });
// setTimeout(()=>{
// this.setRunPath(runPath, true);
// }, 500);
// this.setRunPath(runPath, true);
runPath.forEach(path=>{
if (oldRunPath.includes(path)) {
const index = oldRunPath.indexOf(path);
oldRunPath.splice(index, 1);
} else {
const section = this.$store.getters['map/getDeviceByCode'](path);
if (section && section.instance) {
section.instance.showRunLine();
}
}
});
oldRunPath.forEach(each=>{
const section = this.$store.getters['map/getDeviceByCode'](each);
if (section && section.instance) {
section.instance.setRunLineDefault();
}
});
this.selectedRunPath = row.code;
this.judgeCanCommit();
this.$store.dispatch('training/setRunPathSelected', runPath);
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
}
}).catch(() => {
this.$refs.noticeInfo.doShow();

View File

@ -277,6 +277,9 @@ export default {
}
},
created() {
if (!loginInfo[this.project]) {
this.$messageBox('无效的登录路径,请查证路径后重试!');
}
document.querySelector("link[rel*='icon']").href = loginInfo[this.project].linkIcon || ProjectIcon[this.project];
removeSessionStorage('projectDevice');
this.computedAttribute();

View File

@ -314,7 +314,7 @@ export default {
if (this.sectionList && this.sectionList.length) {
this.sectionList.forEach(elem => {
// elem.type !== '03' // !elem.switchSection
if (elem.type !== '04' && !elem.switchSection && !elem.trainWindowCode && ( !elem.logicSectionCodeList || elem.logicSectionCodeList.length === 0)) {
if (elem.type !== '04' && elem.type !== '05' && !elem.switchSection && !elem.trainWindowCode && ( !elem.logicSectionCodeList || elem.logicSectionCodeList.length === 0)) {
const triangle = new JTriangle(elem.points[0], elem.points[elem.points.length - 1]);
const param = this.createModel({
triangle: triangle,