Merge branch 'dev' of https://git.code.tencent.com/lian-cbtc/jl-client into dev
This commit is contained in:
commit
16caa26336
@ -160,6 +160,7 @@ class SkinCode extends defaultStyle {
|
||||
checkColor: '#00FF00' // 信号字体
|
||||
},
|
||||
lamp: {
|
||||
bgShow: false, // 是否被选中
|
||||
guidName: 'defult', // 默认引导类型
|
||||
stopWidth: 2, // 禁止线宽度
|
||||
borderVariable: true, // 信号灯边框可变
|
||||
|
@ -160,6 +160,7 @@ class SkinCode extends defaultStyle {
|
||||
checkColor: '#00FF00' // 信号保护区段检查颜色
|
||||
},
|
||||
lamp: {
|
||||
bgShow: false, // 是否被选中
|
||||
guidName: 'defult', // 默认引导类型
|
||||
borderVariable: true, // 信号灯边框可变
|
||||
stopWidth: 2, // 禁止线宽度
|
||||
|
@ -163,6 +163,7 @@ class SkinCode extends defaultStyle {
|
||||
checkColor: '#00FF00' // 信号保护区段检查颜色
|
||||
},
|
||||
lamp: {
|
||||
bgShow: false, // 是否被选中
|
||||
guidName: 'chengdu_03', // 成都三号线引导类型
|
||||
borderVariable: true, // 信号灯边框可变
|
||||
stopWidth: 2, // 禁止线宽度
|
||||
|
@ -154,6 +154,7 @@ class SkinCode extends defaultStyle {
|
||||
nameBorderShow: true // 信号机名字边框显示
|
||||
},
|
||||
lamp: {
|
||||
bgShow: false, // 是否被选中
|
||||
guidName: 'defult', // 默认引导类型
|
||||
stopWidth: 2, // 禁止线宽度
|
||||
borderWidth: 1, // 信号灯边框线宽度
|
||||
|
@ -155,6 +155,7 @@ class SkinCode extends defaultStyle {
|
||||
nameBorderShow: true // 信号机名字边框显示
|
||||
},
|
||||
lamp: {
|
||||
bgShow: true, // 是否被选中
|
||||
logicDisplayNone: true, // 逻辑点灯斜线不显示
|
||||
guidName: 'defult', // 默认引导类型
|
||||
stopWidth: 2, // 禁止线宽度
|
||||
|
@ -161,6 +161,7 @@ class SkinCode extends defaultStyle {
|
||||
checkColor: '#00FF00' // 信号保护区段检查颜色
|
||||
},
|
||||
lamp: {
|
||||
bgShow: false, // 是否被选中
|
||||
guidName: 'ningbo_01', // 默认引导类型
|
||||
borderVariable: true, // 信号灯边框可变
|
||||
stopWidth: 2, // 禁止线宽度
|
||||
|
@ -575,6 +575,10 @@ class Signal extends Group {
|
||||
this.on('mouseout', () => { this.highlight.mouseout(); });
|
||||
this.on('mouseover', () => { this.highlight.mouseover(); });
|
||||
}
|
||||
if (this.style.Signal.lamp.bgShow) {
|
||||
this.highlight = new EHighlight(this);
|
||||
this.add(this.highlight);
|
||||
}
|
||||
}
|
||||
|
||||
drawBatchSelected(selected, type) {
|
||||
|
@ -13,7 +13,7 @@
|
||||
>
|
||||
<div class="context">
|
||||
<template v-for="message in messages">
|
||||
<span>{{ message }}</span>
|
||||
<span :key="message">{{ message }}</span>
|
||||
</template>
|
||||
</div>
|
||||
<el-row justify="center" class="button-group">
|
||||
@ -29,7 +29,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { MapDeviceType, OperationEvent } from '@/scripts/ConstDic';
|
||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import NoticeInfo from './childDialog/noticeInfo';
|
||||
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
|
||||
@ -52,24 +52,8 @@ export default {
|
||||
return this.dialogShow && !this.$store.state.menuOperation.break;
|
||||
},
|
||||
title() {
|
||||
if (this.operation === OperationEvent.Signal.arrangementRoute.menu.operation) {
|
||||
return '进路设置';
|
||||
} else if (this.operation === OperationEvent.Signal.signalClose.menu.operation) {
|
||||
if (this.operation === OperationEvent.Signal.signalClose.menu.operation) {
|
||||
return '信号关灯';
|
||||
} else if (this.operation === OperationEvent.Signal.reopenSignal.menu.operation) {
|
||||
return '信号重开';
|
||||
} else if (this.operation === OperationEvent.Signal.cancelTrainRoute.menu.operation) {
|
||||
return '取消进路';
|
||||
} else if (this.operation === OperationEvent.Signal.humanControl.menu.operation) {
|
||||
return '进路交人工控';
|
||||
} else if (this.operation === OperationEvent.Signal.atsAutoControl.menu.operation) {
|
||||
return '进路交ATS自动控';
|
||||
} else if (this.operation === OperationEvent.StationStand.setRunLevel.menu.operation) {
|
||||
return '设置运行等级';
|
||||
} else if (this.operation === OperationEvent.StationStand.setStopTime.menu.operation) {
|
||||
return '停站时间';
|
||||
} else if (this.operation === OperationEvent.StationStand.setBackStrategy.menu.operation) {
|
||||
return '设置折返策略';
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
@ -79,36 +63,14 @@ export default {
|
||||
},
|
||||
domIdConfirm() {
|
||||
if (this.dialogShow) {
|
||||
if (this.operation === OperationEvent.Signal.arrangementRoute.menu.operation) {
|
||||
/** 进路设置*/
|
||||
return OperationEvent.Signal.arrangementRoute.confirm.domId;
|
||||
} else if (this.operation === OperationEvent.Signal.signalClose.menu.operation) {
|
||||
if (this.operation === OperationEvent.Signal.signalClose.menu.operation) {
|
||||
/** 信号关灯*/
|
||||
return OperationEvent.Signal.signalClose.confirm.domId;
|
||||
} else if (this.operation === OperationEvent.Signal.reopenSignal.menu.operation) {
|
||||
/** 信号重开*/
|
||||
return OperationEvent.Signal.reopenSignal.confirm.domId;
|
||||
} else if (this.operation === OperationEvent.Signal.cancelTrainRoute.menu.operation) {
|
||||
/** 取消进路*/
|
||||
return OperationEvent.Signal.cancelTrainRoute.confirm.domId;
|
||||
} else if (this.operation === OperationEvent.Signal.humanControl.menu.operation) {
|
||||
/** 进路交人工控*/
|
||||
return OperationEvent.Signal.humanControl.confirm.domId;
|
||||
} else if (this.operation === OperationEvent.Signal.atsAutoControl.menu.operation) {
|
||||
/** 进路交ATS自动控*/
|
||||
return OperationEvent.Signal.atsAutoControl.confirm.domId;
|
||||
} else if (this.operation === OperationEvent.StationStand.setRunLevel.menu.operation) {
|
||||
/** 设置运行等级*/
|
||||
return OperationEvent.StationStand.setRunLevel.confirm.domId;
|
||||
} else if (this.operation === OperationEvent.StationStand.setStopTime.menu.operation) {
|
||||
/** 设置停战时间*/
|
||||
return OperationEvent.StationStand.setStopTime.confirm.domId;
|
||||
} else if (this.operation === OperationEvent.StationStand.setBackStrategy.menu.operation) {
|
||||
/** 设置折返策略*/
|
||||
return OperationEvent.StationStand.setBackStrategy.confirm.domId;
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -137,55 +99,11 @@ export default {
|
||||
this.$store.dispatch('training/emitTipFresh');
|
||||
},
|
||||
commit() {
|
||||
if (this.operation === OperationEvent.Signal.arrangementRoute.menu.operation) {
|
||||
/** 进路设置*/
|
||||
this.routeSetting();
|
||||
} else if (this.operation === OperationEvent.Signal.signalClose.menu.operation) {
|
||||
if (this.operation === OperationEvent.Signal.signalClose.menu.operation) {
|
||||
/** 信号关灯*/
|
||||
this.signalClose();
|
||||
} else if (this.operation === OperationEvent.Signal.reopenSignal.menu.operation) {
|
||||
/** 信号重开*/
|
||||
this.reopenSignal();
|
||||
} else if (this.operation === OperationEvent.Signal.cancelTrainRoute.menu.operation) {
|
||||
/** 取消进路*/
|
||||
this.cancelTrainRoute();
|
||||
} else if (this.operation === OperationEvent.Signal.humanControl.menu.operation) {
|
||||
/** 进路交人工控*/
|
||||
this.humanControl();
|
||||
} else if (this.operation === OperationEvent.Signal.atsAutoControl.menu.operation) {
|
||||
/** 进路交ATS自动控*/
|
||||
this.atsAutoControl();
|
||||
} else if (this.operation === OperationEvent.StationStand.setRunLevel.menu.operation) {
|
||||
/** 设置运行等级*/
|
||||
this.setRunLevel();
|
||||
} else if (this.operation === OperationEvent.StationStand.setStopTime.menu.operation) {
|
||||
/** 停站时间*/
|
||||
this.setStopTime();
|
||||
} else if (this.operation === OperationEvent.StationStand.setBackStrategy.menu.operation) {
|
||||
/** 设置折返策略*/
|
||||
this.setBackStrategy();
|
||||
}
|
||||
},
|
||||
// 进路设置
|
||||
routeSetting() {
|
||||
const operate = {
|
||||
send: true,
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.Signal.arrangementRoute.confirm.operation
|
||||
};
|
||||
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.loading = false;
|
||||
this.doClose();
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
// 信号关灯
|
||||
signalClose() {
|
||||
const operate = {
|
||||
@ -206,149 +124,6 @@ export default {
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
// 信号重开
|
||||
reopenSignal() {
|
||||
const operate = {
|
||||
send: true,
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.Signal.reopenSignal.confirm.operation
|
||||
};
|
||||
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.loading = false;
|
||||
this.doClose();
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
// 取消进路
|
||||
cancelTrainRoute() {
|
||||
const operate = {
|
||||
send: true,
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.Signal.cancelTrainRoute.confirm.operation
|
||||
};
|
||||
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.loading = false;
|
||||
this.doClose();
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
// 进路交人工控
|
||||
humanControl() {
|
||||
const operate = {
|
||||
send: true,
|
||||
type: MapDeviceType.Signal.type,
|
||||
operation: OperationEvent.Signal.humanControl.menu.operation
|
||||
};
|
||||
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch(error => {
|
||||
this.loading = false;
|
||||
this.doClose();
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
// 进路交ATS自动控
|
||||
atsAutoControl() {
|
||||
const operate = {
|
||||
send: true,
|
||||
type: MapDeviceType.Signal.type,
|
||||
operation: OperationEvent.Signal.atsAutoControl.menu.operation
|
||||
};
|
||||
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch(error => {
|
||||
this.loading = false;
|
||||
this.doClose();
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
// 设置运行等级
|
||||
setRunLevel() {
|
||||
const operate = {
|
||||
send: true,
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.StationStand.setRunLevel.confirm.operation,
|
||||
val: this.operate.val
|
||||
};
|
||||
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.loading = false;
|
||||
this.doClose();
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
// 停站时间
|
||||
setStopTime() {
|
||||
const operate = {
|
||||
send: true,
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.StationStand.setStopTime.confirm.operation,
|
||||
val: this.operate.val
|
||||
};
|
||||
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.loading = false;
|
||||
this.doClose();
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
// 设置折返策略
|
||||
setBackStrategy() {
|
||||
const operate = {
|
||||
send: true,
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.StationStand.setBackStrategy.confirm.operation,
|
||||
val: this.operate.val
|
||||
};
|
||||
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.loading = false;
|
||||
this.doClose();
|
||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
||||
});
|
||||
},
|
||||
cancel() {
|
||||
const operate = {
|
||||
type: this.operate.type,
|
||||
|
@ -36,7 +36,9 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { MapDeviceType, OperationEvent, getDomIdByOperation } from '@/scripts/ConstDic';
|
||||
// import { MapDeviceType, OperationEvent, getDomIdByOperation } from '@/scripts/ConstDic';
|
||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import { mouseCancelState } from '../utils/menuItemStatus';
|
||||
import ConfirmControl from './childDialog/confirmControl';
|
||||
import NoticeInfo from './childDialog/childDialog/noticeInfo';
|
||||
@ -66,7 +68,7 @@ export default {
|
||||
return this.dialogShow ? OperationEvent.Command.close.menu.domId : '';
|
||||
},
|
||||
domIdConfirm() {
|
||||
return this.dialogShow ? getDomIdByOperation(this.operation) : '';
|
||||
return this.dialogShow ? OperationHandler.getDomIdByOperation(this.operation) : '';
|
||||
},
|
||||
title() {
|
||||
if (this.operation == OperationEvent.Signal.cancelTrainRoute.menu.operation) {
|
||||
@ -126,13 +128,6 @@ export default {
|
||||
// 取消列车进路
|
||||
cancelTrainRoute() {
|
||||
this.cancelTrainRouteFunc();
|
||||
// if (this.$store.state.training.prdType == '01') {
|
||||
// /** 现地工作站*/
|
||||
// this.cancelTrainRouteFunc();
|
||||
// } else if (this.$store.state.training.prdType == '02') {
|
||||
// /** 行调工作站*/
|
||||
// this.cancelTrainRouteFunc();
|
||||
// }
|
||||
},
|
||||
cancelTrainRouteFunc() {
|
||||
const operate = {
|
||||
@ -195,10 +190,8 @@ export default {
|
||||
// 取消
|
||||
cancel() {
|
||||
const operate = {
|
||||
type: MapDeviceType.Signal.type,
|
||||
operation: OperationEvent.Command.close.menu.operation
|
||||
};
|
||||
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
|
@ -69,7 +69,6 @@
|
||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<confirm-control ref="confirmControl" />
|
||||
<notice-info ref="noticeInfo" />
|
||||
</el-dialog>
|
||||
</div>
|
||||
@ -77,8 +76,8 @@
|
||||
|
||||
<script>
|
||||
import { mapGetters } from 'vuex';
|
||||
import { MapDeviceType, OperationEvent, getDomIdByOperation } from '@/scripts/ConstDic';
|
||||
import ConfirmControl from './childDialog/confirmControl';
|
||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import { mouseCancelState } from '../utils/menuItemStatus';
|
||||
import NoticeInfo from './childDialog/childDialog/noticeInfo';
|
||||
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
@ -86,7 +85,6 @@ import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
export default {
|
||||
name: 'RouteHandControl',
|
||||
components: {
|
||||
ConfirmControl,
|
||||
NoticeInfo
|
||||
},
|
||||
data() {
|
||||
@ -124,10 +122,12 @@ export default {
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
},
|
||||
domIdConfirm() {
|
||||
return this.dialogShow ? getDomIdByOperation(this.operation) : '';
|
||||
return this.dialogShow ? OperationHandler.getDomIdByOperation(this.operation) : '';
|
||||
},
|
||||
title() {
|
||||
if (this.operation == OperationEvent.Signal.humanControl.menu.operation) {
|
||||
@ -241,23 +241,12 @@ export default {
|
||||
this.commitDisabled = true;
|
||||
}
|
||||
},
|
||||
serializeCodeListWithSeparator(sep) {
|
||||
const codeList = [];
|
||||
if (this.selection && this.selection.length) {
|
||||
this.selection.forEach(elem => {
|
||||
codeList.push(elem.code);
|
||||
});
|
||||
}
|
||||
return codeList.join(sep);
|
||||
},
|
||||
handleChooseChange(selection) {
|
||||
this.selection = selection;
|
||||
if (selection && selection.length) {
|
||||
const operate = {
|
||||
repeat: true,
|
||||
type: MapDeviceType.Signal.type,
|
||||
operation: '',
|
||||
val: this.serializeCodeListWithSeparator('::'),
|
||||
selection: selection
|
||||
};
|
||||
|
||||
@ -334,7 +323,6 @@ export default {
|
||||
},
|
||||
cancel() {
|
||||
const operate = {
|
||||
type: MapDeviceType.Signal.type,
|
||||
operation: OperationEvent.Command.cancel.menu.operation
|
||||
};
|
||||
|
||||
|
@ -56,7 +56,6 @@
|
||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<!-- <confirm-control ref="confirmControl"></confirm-control> -->
|
||||
<notice-info ref="noticeInfo" />
|
||||
</el-dialog>
|
||||
</template>
|
||||
@ -64,7 +63,6 @@
|
||||
<script>
|
||||
import { MapDeviceType, OperationEvent } from '@/scripts/ConstDic';
|
||||
import { mouseCancelState } from '../utils/menuItemStatus';
|
||||
// import ConfirmControl from './childDialog/confirmControl';
|
||||
import NoticeInfo from './childDialog/childDialog/noticeInfo';
|
||||
import { deepAssign } from '@/utils/index';
|
||||
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
@ -72,7 +70,6 @@ import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
export default {
|
||||
name: 'RouteSelection',
|
||||
components: {
|
||||
// ConfirmControl,
|
||||
NoticeInfo
|
||||
},
|
||||
data() {
|
||||
|
@ -1,47 +1,69 @@
|
||||
<template>
|
||||
<el-dialog class="beijing-01__systerm stand-run-level" :title="title" :visible.sync="show" width="500px"
|
||||
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag>
|
||||
<el-dialog
|
||||
v-dialogDrag
|
||||
class="beijing-01__systerm stand-run-level"
|
||||
:title="title"
|
||||
:visible.sync="show"
|
||||
width="500px"
|
||||
:before-close="doClose"
|
||||
:z-index="2000"
|
||||
:modal="false"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<el-row class="header">
|
||||
<el-col :span="10"><span>集中站</span></el-col>
|
||||
<el-col :span="10" :offset="2"><span>站台</span></el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-input v-model="stationName" size="small" disabled></el-input>
|
||||
<el-input v-model="stationName" size="small" disabled />
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="2">
|
||||
<el-input v-model="standName" size="small" disabled></el-input>
|
||||
<el-input v-model="standName" size="small" disabled />
|
||||
</el-col>
|
||||
</el-row>
|
||||
<div class="table">
|
||||
<span>站台状态</span>
|
||||
<el-table ref="tempData" :data="tempData" border style="width: 100%; height: 170px;" size="mini">
|
||||
<el-table-column prop="name" :width="180" label="下一站台">
|
||||
</el-table-column>
|
||||
<el-table-column prop="name" :width="180" label="下一站台" />
|
||||
<el-table-column prop="level" label="运行等级">
|
||||
<template slot-scope="scope">
|
||||
<el-select v-model="scope.row.level" size="mini" @change="levelSelectChange(scope.row)"
|
||||
:id='chooseLevelId'>
|
||||
<el-option v-for="item in levelList" :key="item.value" :label="item.label"
|
||||
:value="item.value">
|
||||
</el-option>
|
||||
<el-select
|
||||
:id="chooseLevelId"
|
||||
v-model="scope.row.level"
|
||||
size="mini"
|
||||
@change="levelSelectChange(scope.row)"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in levelList"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="time" label="区间运行时间">
|
||||
<template slot-scope="scope">
|
||||
<el-select v-model="scope.row.time" size="mini" @change="timeSelectChange"
|
||||
:disabled="scope.row.level == 0" :id='domIdChoose'>
|
||||
<el-option v-for="item in timeList[scope.row.level]" :key="item.value" :label="item.label"
|
||||
:value="item.value">
|
||||
</el-option>
|
||||
<el-select
|
||||
:id="domIdChoose"
|
||||
v-model="scope.row.time"
|
||||
size="mini"
|
||||
:disabled="scope.row.level == 0"
|
||||
@change="timeSelectChange"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in timeList[scope.row.level]"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="check" label="一直有效">
|
||||
<template slot-scope="scope">
|
||||
<el-checkbox ref="check" v-model="scope.row.check" @change="checkChange" :id='domIdCheck'>
|
||||
</el-checkbox>
|
||||
<el-checkbox :id="domIdCheck" ref="check" v-model="scope.row.check" @change="checkChange" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@ -59,22 +81,21 @@
|
||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<confirm-control ref="confirmControl"></confirm-control>
|
||||
<notice-info ref="noticeInfo" />
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapGetters } from 'vuex';
|
||||
// import { MapDeviceType, OperationEvent } from '@/scripts/ConstDic';
|
||||
import { mouseCancelState } from '../utils/menuItemStatus';
|
||||
import ConfirmControl from './childDialog/confirmControl';
|
||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
import NoticeInfo from './childDialog/childDialog/noticeInfo';
|
||||
|
||||
export default {
|
||||
name: 'StandRunLevel',
|
||||
components: {
|
||||
ConfirmControl
|
||||
NoticeInfo
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@ -89,29 +110,29 @@ export default {
|
||||
levelList: [
|
||||
{
|
||||
value: '0',
|
||||
label: '自动',
|
||||
label: '自动'
|
||||
},
|
||||
{
|
||||
value: '1',
|
||||
label: '1',
|
||||
label: '1'
|
||||
},
|
||||
{
|
||||
value: '2',
|
||||
label: '2',
|
||||
label: '2'
|
||||
},
|
||||
{
|
||||
value: '3',
|
||||
label: '3',
|
||||
label: '3'
|
||||
},
|
||||
{
|
||||
value: '4',
|
||||
label: '4',
|
||||
},
|
||||
label: '4'
|
||||
}
|
||||
],
|
||||
isSelect: true,
|
||||
isConfirm: false,
|
||||
time: ''
|
||||
}
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
// 深度数据状态
|
||||
@ -149,24 +170,24 @@ export default {
|
||||
return '设置运行等级';
|
||||
},
|
||||
timeList() {
|
||||
let list = {
|
||||
const list = {
|
||||
'0': [{ value: 0, label: '0' }],
|
||||
'1': [], // 120 - 110
|
||||
'2': [], // 100 - 90
|
||||
'3': [], // 80 - 70
|
||||
'4': [], // 60 - 50
|
||||
}
|
||||
'4': [] // 60 - 50
|
||||
};
|
||||
for (var i = 110; i <= 120; i++) {
|
||||
list['1'].push({ value: i, label: `${i}` })
|
||||
list['1'].push({ value: i, label: `${i}` });
|
||||
}
|
||||
for (var i = 90; i <= 100; i++) {
|
||||
list['2'].push({ value: i, label: `${i}` })
|
||||
list['2'].push({ value: i, label: `${i}` });
|
||||
}
|
||||
for (var i = 70; i <= 80; i++) {
|
||||
list['3'].push({ value: i, label: `${i}` })
|
||||
list['3'].push({ value: i, label: `${i}` });
|
||||
}
|
||||
for (var i = 50; i <= 60; i++) {
|
||||
list['4'].push({ value: i, label: `${i}` })
|
||||
list['4'].push({ value: i, label: `${i}` });
|
||||
}
|
||||
return list;
|
||||
}
|
||||
@ -174,7 +195,7 @@ export default {
|
||||
mounted() {
|
||||
this.$nextTick(() => {
|
||||
this.$store.dispatch('training/tipReload');
|
||||
})
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
getLevelByTime(time) {
|
||||
@ -186,20 +207,20 @@ export default {
|
||||
},
|
||||
loadInitData(selected, opts) {
|
||||
this.tempData = [];
|
||||
let stationList = this.stationList.slice();
|
||||
let index = this.stationList.findIndex(n => n.code == selected.stationCode)
|
||||
const stationList = this.stationList.slice();
|
||||
const index = this.stationList.findIndex(n => n.code == selected.stationCode);
|
||||
if (selected.direction == '01') { // 下行
|
||||
// 下行时,此站不是最后一站
|
||||
if (index != 0) {
|
||||
let stationStand = this.$store.getters['map/getDeviceByCode'](this.stationStandList[index + 1].code);
|
||||
let station = this.$store.getters['map/getDeviceByCode'](stationStand.stationCode);
|
||||
const stationStand = this.$store.getters['map/getDeviceByCode'](this.stationStandList[index + 1].code);
|
||||
const station = this.$store.getters['map/getDeviceByCode'](stationStand.stationCode);
|
||||
this.tempData.push({ name: `${stationStand.name}(${station.name})`, level: this.getLevelByTime(opts.intervalRunTime), time: opts.intervalRunTime ? opts.intervalRunTime : 0, check: opts.intervalRunTimeValidStatus });
|
||||
}
|
||||
} else {
|
||||
// 上行时,此站不是最后一站
|
||||
if (index != this.stationList.length) {
|
||||
let stationStand = this.$store.getters['map/getDeviceByCode'](this.stationStandList[index + 1].code);
|
||||
let station = this.$store.getters['map/getDeviceByCode'](stationStand.stationCode);
|
||||
const stationStand = this.$store.getters['map/getDeviceByCode'](this.stationStandList[index + 1].code);
|
||||
const station = this.$store.getters['map/getDeviceByCode'](stationStand.stationCode);
|
||||
this.tempData.push({ name: `${stationStand.name}(${station.name})`, level: this.getLevelByTime(opts.intervalRunTime), time: opts.intervalRunTime ? opts.intervalRunTime : 0, check: opts.intervalRunTimeValidStatus });
|
||||
}
|
||||
}
|
||||
@ -212,7 +233,7 @@ export default {
|
||||
this.stationName = '';
|
||||
if (selected && selected._type.toUpperCase() === 'StationStand'.toUpperCase()) {
|
||||
this.standName = selected.name;
|
||||
let station = this.$store.getters['map/getDeviceByCode'](selected.stationCode);
|
||||
const station = this.$store.getters['map/getDeviceByCode'](selected.stationCode);
|
||||
if (station) {
|
||||
this.stationName = station.name;
|
||||
}
|
||||
@ -226,16 +247,16 @@ export default {
|
||||
});
|
||||
},
|
||||
checkTableDataSelction(data) {
|
||||
let selection = [];
|
||||
const selection = [];
|
||||
if (data && data.length > 0) {
|
||||
data.forEach(row => {
|
||||
if (row.check && !row.disabled) {
|
||||
selection.push(row);
|
||||
}
|
||||
})
|
||||
});
|
||||
}
|
||||
|
||||
this.disabledSend = selection.length ? false : true;
|
||||
this.disabledSend = !selection.length;
|
||||
if (JSON.stringify(selection) !== JSON.stringify(this.selection)) {
|
||||
this.selection = selection;
|
||||
}
|
||||
@ -243,7 +264,7 @@ export default {
|
||||
timeSelectChange(time) {
|
||||
const operate = {
|
||||
operation: OperationEvent.StationStand.setRunLevel.choose.operation,
|
||||
val: time.toString(),
|
||||
val: time.toString()
|
||||
};
|
||||
|
||||
this.time = time.toString();
|
||||
@ -253,13 +274,13 @@ export default {
|
||||
if (valid) {
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
levelSelectChange(row) {
|
||||
const operate = {
|
||||
operation: OperationEvent.StationStand.setRunLevel.chooseLevel.operation,
|
||||
val: row.level.toString(),
|
||||
}
|
||||
val: row.level.toString()
|
||||
};
|
||||
|
||||
this.time = row.time = this.timeList[row.level][0].value;
|
||||
this.isSelect = false;
|
||||
@ -305,8 +326,7 @@ export default {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
// this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
// this.$refs.confirmControl.doShow(operate);
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.loading = false;
|
||||
@ -319,7 +339,7 @@ export default {
|
||||
},
|
||||
cancel() {
|
||||
const operate = {
|
||||
operation: OperationEvent.Command.cancel.menu.operation,
|
||||
operation: OperationEvent.Command.cancel.menu.operation
|
||||
};
|
||||
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
@ -331,5 +351,5 @@ export default {
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
@ -61,14 +61,12 @@
|
||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<confirm-control ref="confirmControl" />
|
||||
<notice-info ref="noticeInfo" />
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mouseCancelState } from '../utils/menuItemStatus';
|
||||
import ConfirmControl from './childDialog/confirmControl';
|
||||
import NoticeInfo from './childDialog/childDialog/noticeInfo';
|
||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
@ -76,7 +74,6 @@ import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
export default {
|
||||
name: 'StandStopTime',
|
||||
components: {
|
||||
ConfirmControl,
|
||||
NoticeInfo
|
||||
},
|
||||
data() {
|
||||
@ -229,8 +226,7 @@ export default {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
// this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
// this.$refs.confirmControl.doShow(operate);
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.loading = false;
|
||||
|
@ -72,6 +72,7 @@ export default {
|
||||
data() {
|
||||
return {
|
||||
tempData: [],
|
||||
oldDevice: null, // 上一次点击元素
|
||||
canCommand: true,
|
||||
operate: '',
|
||||
cmdType: '',
|
||||
@ -109,6 +110,16 @@ export default {
|
||||
{ name: '取消联锁', cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_ROUTE, operate: OperationEvent.Signal.cancelTrainRoute.menu.operation, show: false },
|
||||
{ name: '引导进路', cmdType: CMD.Signal.CMD_SIGNAL_ROUTE_GUIDE, operate: OperationEvent.Signal.guide.menu.operation, show: false },
|
||||
{ name: '取消引导', cmdType: CMD.Signal.CMD_SIGNAL_HUMAN_RELEASE_ROUTE, operate: OperationEvent.Signal.humanTrainRoute.menu.operation, show: false }
|
||||
],
|
||||
sectionParamList: [
|
||||
{ name: '封锁区段', cmdType: CMD.Section.CMD_SECTION_BLOCK, operate: OperationEvent.Section.lock.menu.operation, show: false },
|
||||
{ name: '解封区段', cmdType: CMD.Section.CMD_SECTION_UNBLOCK, operate: OperationEvent.Section.unlock.menu.operation, show: false },
|
||||
{ name: '轨区消限', cmdType: CMD.Section.CMD_SECTION_CANCEL_LIMIT_SPEED, operate: OperationEvent.Section.cancelSpeed.menu.operation, show: false },
|
||||
{ name: '轨区设限', cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED, operate: OperationEvent.Section.setSpeed.menu.operation, show: false },
|
||||
{ name: '强解区段', cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK, operate: OperationEvent.Section.fault.menu.operation, show: false }
|
||||
],
|
||||
stationParamList: [
|
||||
{ name: '关站信号', cmdType: CMD.Section.CMD_SECTION_BLOCK, operate: OperationEvent.Signal.cancelTrainRoute.menu.operation, show: false } // 流程未处理
|
||||
]
|
||||
};
|
||||
},
|
||||
@ -125,6 +136,9 @@ export default {
|
||||
switch (this.selected._type) {
|
||||
case 'Switch':
|
||||
this.handleSwicthMenu();
|
||||
this.deviceHighLight(this.oldDevice, false);
|
||||
this.deviceHighLight(this.selected, true);
|
||||
this.oldDevice = this.selected;
|
||||
break;
|
||||
case 'Signal':
|
||||
if (this.oldClickObj && this.oldClickObj.code != this.selected.code) {
|
||||
@ -133,11 +147,46 @@ export default {
|
||||
this.handleSingalMenu();
|
||||
}
|
||||
break;
|
||||
case 'Section':
|
||||
this.handleSectionMenu();
|
||||
this.deviceHighLight(this.oldDevice, false);
|
||||
this.deviceHighLight(this.selected, true);
|
||||
this.oldDevice = this.selected;
|
||||
break;
|
||||
case 'Station':
|
||||
this.handleStationMenu();
|
||||
this.deviceHighLight(this.oldDevice, false);
|
||||
this.deviceHighLight(this.selected, true);
|
||||
this.oldDevice = this.selected;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 高亮设备
|
||||
deviceHighLight(device, flag) {
|
||||
if (device && device.instance && typeof device.instance.drawSelected === 'function' ) {
|
||||
if (device._type === 'Section' && device.type === '04') {
|
||||
device.relevanceSectionList.forEach(item => {
|
||||
const sectionModel = this.$store.getters['map/getDeviceByCode'](item);
|
||||
sectionModel && sectionModel.instance.drawSelected(flag);
|
||||
});
|
||||
} else if (device._type === 'Section' && device.type === '01' && device.logicSectionCodeList && device.logicSectionCodeList.length) {
|
||||
device.logicSectionCodeList.forEach(item => {
|
||||
const sectionModel = this.$store.getters['map/getDeviceByCode'](item);
|
||||
sectionModel && sectionModel.instance.drawSelected(flag);
|
||||
});
|
||||
} else {
|
||||
device.instance.drawSelected(flag);
|
||||
}
|
||||
} else if (device) {
|
||||
const model = this.$store.getters['map/getDeviceByCode'](device.code);
|
||||
if (model.instance) {
|
||||
model.instance.drawSelected(flag);
|
||||
}
|
||||
}
|
||||
},
|
||||
clickCommand(row) {
|
||||
this.clearAllMenuShow();
|
||||
if (this.tempData.length) {
|
||||
@ -166,6 +215,13 @@ export default {
|
||||
};
|
||||
},
|
||||
handleSingalMenu() {
|
||||
this.deviceHighLight(this.oldDevice, false);
|
||||
this.deviceHighLight(this.selected, true);
|
||||
this.oldDevice = this.selected;
|
||||
if (this.oldClickObj) { // 清除上上次信号机背景
|
||||
this.deviceHighLight(this.oldClickObj, false);
|
||||
}
|
||||
|
||||
this.oldClickObj = deepAssign({}, this.selected);
|
||||
this.centralizedStationList = new Array(15).fill({});
|
||||
this.signalParamList.forEach((swicth, index) => {
|
||||
@ -198,10 +254,35 @@ export default {
|
||||
});
|
||||
if (this.route && this.route.code) {
|
||||
this.handleRouteMenu();
|
||||
this.deviceHighLight(this.selected, true);
|
||||
this.oldDevice = this.selected;
|
||||
} else {
|
||||
this.handleSingalMenu();
|
||||
}
|
||||
},
|
||||
handleSectionMenu() {
|
||||
this.centralizedStationList = new Array(15).fill({});
|
||||
this.sectionParamList.forEach((swicth, index) => {
|
||||
this.centralizedStationList[index] = swicth;
|
||||
});
|
||||
this.tempData = [];
|
||||
this.tempData.push(this.selected);
|
||||
this.param = {
|
||||
sectionCode: this.selected.code,
|
||||
speedLimitValue: 5
|
||||
};
|
||||
},
|
||||
handleStationMenu() {
|
||||
this.centralizedStationList = new Array(15).fill({});
|
||||
this.stationParamList.forEach((swicth, index) => {
|
||||
this.centralizedStationList[index] = swicth;
|
||||
});
|
||||
this.tempData = [];
|
||||
this.tempData.push(this.selected);
|
||||
this.param = {
|
||||
sectionCode: this.selected.code
|
||||
};
|
||||
},
|
||||
handleParam() {
|
||||
if (this.operate == OperationEvent.Signal.cancelTrainRoute.menu.operation || this.operate == OperationEvent.Signal.humanTrainRoute.menu.operation) {
|
||||
this.param = {
|
||||
@ -217,7 +298,6 @@ export default {
|
||||
operation: this.operate,
|
||||
param: this.param
|
||||
};
|
||||
// console.log(step);
|
||||
this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
@ -228,12 +308,16 @@ export default {
|
||||
});
|
||||
},
|
||||
doClose() {
|
||||
this.deviceHighLight(this.selected, false); // 当前选中
|
||||
this.operate = ''; // 清空指令
|
||||
this.cmdType = '';
|
||||
this.oldClickObj = null; // 清空上次点击信号机
|
||||
if (this.oldClickObj) {
|
||||
this.deviceHighLight(this.oldClickObj, false);
|
||||
}
|
||||
this.param = {};
|
||||
this.tempData = []; // 清空执行栏
|
||||
this.canCommand = true; // 执行变为禁用
|
||||
this.oldClickObj = null; // 清空上次点击信号机
|
||||
this.clearAllMenuShow();
|
||||
}
|
||||
}
|
||||
|
@ -182,7 +182,9 @@ export default {
|
||||
/** 设置引导总锁 */
|
||||
CMD_STATION_SET_MASTER_GUIDE_LOCK: {value: 'Station_Set_Master_Guide_Lock', label: '设置引导总锁'},
|
||||
/** 取消引导总锁 */
|
||||
CMD_STATION_CANCEL_MASTER_GUIDE_LOCK: {value: 'Station_Cancel_Master_Guide_Lock', label: '取消引导总锁'}
|
||||
CMD_STATION_CANCEL_MASTER_GUIDE_LOCK: {value: 'Station_Cancel_Master_Guide_Lock', label: '取消引导总锁'},
|
||||
/** 封锁车站所有信号机 */
|
||||
CMD_STATION_CANCEL_MASTER_GUIDE: {value: 'Station_Cancel_Master_Guide_Lock', label: '封锁集中站信号'}
|
||||
},
|
||||
|
||||
// 列车
|
||||
|
Loading…
Reference in New Issue
Block a user