Merge remote-tracking branch 'origin/test'

This commit is contained in:
fan 2021-03-12 19:00:40 +08:00
commit 4f99403a9c
35 changed files with 1412 additions and 787 deletions

View File

@ -133,6 +133,25 @@ export function listRoutingData(mapId, params) {
}); });
} }
/** 分页查询公共的交路数据(新版)*/
export function listPublicRoutingData(mapId, params) {
return request({
// url: `/api/mapBuild/${mapId}/routingData`,
url: `/api/runPlan/userData/${mapId}/default/routing/page`,
method: 'get',
params: params
});
}
/** 用户拉取公共的交路数据(新版)*/
export function pullPublicRoutingData(mapId, data) {
return request({
url: `/api/runPlan/userData/${mapId}/default/routing/pull`,
method: 'put',
data: data
});
}
/** 创建交路(新版)*/ /** 创建交路(新版)*/
export function addRoutingData(data) { export function addRoutingData(data) {
return request({ return request({

View File

@ -165,14 +165,6 @@
</el-table-column> </el-table-column>
</template> </template>
</el-table> </el-table>
<div v-if="queryList.selectCheckShow" style="margin-top: 8px; margin-left: 8px;">
<el-button
size="mini"
:type="'primary'"
:disabled="!queryList.selection.length"
@click="queryList.selectAllClick(queryList.selection)"
>{{ $t('global.selectAdd') }}</el-button>
</div>
<div v-if="!queryList.paginationHiden" class="page-container " style="text-align: center; margin: 10px 0; height: 40px;"> <div v-if="!queryList.paginationHiden" class="page-container " style="text-align: center; margin: 10px 0; height: 40px;">
<el-pagination <el-pagination
:current-page="pageIndex" :current-page="pageIndex"
@ -184,6 +176,15 @@
@current-change="changePage" @current-change="changePage"
/> />
</div> </div>
<div v-if="queryList.selectCheckShow" :class="queryList.selectCheckClass?queryList.selectCheckClass:'defaultCheckClass'">
<el-button
:size="queryList.selectCheckSize?queryList.selectCheckSize:'mini'"
:type="'primary'"
:disabled="!queryList.selection.length"
:loading="queryList.selectCheckLoading?queryList.selectCheckLoading:false"
@click="queryList.selectAllClick(queryList.selection)"
>{{ queryList.selectCheckText?queryList.selectCheckText:$t('global.selectAdd') }}</el-button>
</div>
</el-card> </el-card>
</div> </div>
</template> </template>
@ -517,12 +518,12 @@ export default {
}, },
onRowClick(row) { onRowClick(row) {
this.choose = row; this.choose = row;
}, },
onReset() { onReset() {
if (this.$refs.queryForm) { if (this.$refs.queryForm) {
this.$refs.queryForm.doClean(); this.$refs.queryForm.doClean();
} }
}, },
currentChoose() { currentChoose() {
return this.choose; return this.choose;
}, },
@ -568,7 +569,7 @@ export default {
delete self.queryData[self.sortBy]; delete self.queryData[self.sortBy];
self.refresh(true); self.refresh(true);
} }
} }
} }
}; };
@ -594,4 +595,8 @@ export default {
z-index: 100; z-index: 100;
} }
} }
.defaultCheckClass{
margin-top: 8px;
margin-left: 8px;
}
</style> </style>

View File

@ -153,7 +153,8 @@ export default class Section extends Group {
}); });
if (this.model.parentCode && this.model.type == '01') { if (this.model.parentCode && this.model.type == '01') {
this.line.setCrossRouteLock(); const section = this.mapDevice[this.model.parentCode];
section && section.instance && section.instance.line.setCrossRouteLock();
} }
} }
@ -178,7 +179,8 @@ export default class Section extends Group {
} }
if (this.model.parentCode && this.model.type == '01') { if (this.model.parentCode && this.model.type == '01') {
this.line.setCrossRouteLock(); const section = this.mapDevice[this.model.parentCode];
section && section.instance && section.instance.line.setCrossRouteLock();
} }
} }
/** ARB故障 */ /** ARB故障 */

View File

@ -615,7 +615,7 @@ export default {
mapLocation(code) { mapLocation(code) {
if (code) { if (code) {
this.$store.dispatch('training/updateOffsetStationCode', { offsetStationCode: code }); this.$store.dispatch('training/updateOffsetStationCode', { offsetStationCode: code });
this.$refs.menuBar.closeMenu(true);
} }
}, },
// //
@ -625,8 +625,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.helpAbout.doShow(operate); this.$refs.helpAbout.doShow(operate);
} }
}); });
@ -646,8 +645,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.setLimitSpeed.doShow(operate, true); this.$refs.setLimitSpeed.doShow(operate, true);
} }
}); });
@ -658,8 +656,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.setLimitSpeed.doShow(operate, false); this.$refs.setLimitSpeed.doShow(operate, false);
} }
}); });

View File

@ -324,8 +324,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationControlConvert.doShow(operate); this.$refs.stationControlConvert.doShow(operate);
} }
}); });
@ -337,8 +336,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.passwordBox.doShow(operate); this.$refs.passwordBox.doShow(operate);
} }
}); });
@ -350,8 +348,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationControlConvert.doShow(operate); this.$refs.stationControlConvert.doShow(operate);
} }
}); });
@ -363,8 +360,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.viewTrainId.doShow(operate); this.$refs.viewTrainId.doShow(operate);
} }
}); });
@ -376,8 +372,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.viewName.doShow(operate); this.$refs.viewName.doShow(operate);
} }
}); });
@ -389,8 +384,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.viewDevice.doShow(operate); this.$refs.viewDevice.doShow(operate);
} }
}); });
@ -402,8 +396,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainAdd.doShow(operate); this.$refs.trainAdd.doShow(operate);
} }
}); });
@ -415,8 +408,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainTranstalet.doShow(operate); this.$refs.trainTranstalet.doShow(operate);
} }
}); });
@ -428,8 +420,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainDelete.doShow(operate); this.$refs.trainDelete.doShow(operate);
} }
}); });
@ -441,8 +432,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.manageUser.doShow(operate); this.$refs.manageUser.doShow(operate);
} }
}); });
@ -454,15 +444,14 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.helpAbout.doShow(operate); this.$refs.helpAbout.doShow(operate);
} }
}); });
}, },
// //
refresh() { refresh() {
this.$refs.menuBar.closeMenu(true);
EventBus.$emit('refresh'); EventBus.$emit('refresh');
}, },
getLoginResult(operate) { getLoginResult(operate) {

View File

@ -555,7 +555,7 @@ export default {
mapLocation(code) { mapLocation(code) {
if (code) { if (code) {
this.$store.dispatch('training/updateOffsetStationCode', { offsetStationCode: code }); this.$store.dispatch('training/updateOffsetStationCode', { offsetStationCode: code });
this.$refs.menuBar.closeMenu(true);
} }
}, },
// //
@ -567,8 +567,7 @@ export default {
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationControl.doShow(operate); this.$refs.stationControl.doShow(operate);
} }
}); });
@ -581,8 +580,7 @@ export default {
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.areaSelection.doShow(operate); this.$refs.areaSelection.doShow(operate);
} }
@ -596,8 +594,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.detainTrainContorl.doShow(operate); this.$refs.detainTrainContorl.doShow(operate);
} }
}); });
@ -611,8 +608,7 @@ export default {
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.detainTrainContorl.doShow(operate); this.$refs.detainTrainContorl.doShow(operate);
} }
}); });
@ -626,8 +622,7 @@ export default {
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.detainTrainContorlUpDown.doShow(operate); this.$refs.detainTrainContorlUpDown.doShow(operate);
} }
}); });
@ -641,8 +636,7 @@ export default {
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.detainTrainContorlUpDown.doShow(operate); this.$refs.detainTrainContorlUpDown.doShow(operate);
} }
}); });
@ -655,8 +649,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainAdd.doShow(operate); this.$refs.trainAdd.doShow(operate);
} }
}); });
@ -669,8 +662,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainTranstalet.doShow(operate); this.$refs.trainTranstalet.doShow(operate);
} }
}); });
@ -683,8 +675,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainDelete.doShow(operate); this.$refs.trainDelete.doShow(operate);
} }
}); });
@ -697,8 +688,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.manageUser.doShow(operate); this.$refs.manageUser.doShow(operate);
} }
}); });
@ -711,8 +701,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.helpAbout.doShow(operate); this.$refs.helpAbout.doShow(operate);
} }
}); });
@ -724,8 +713,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode); const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode);
const nextOperate = { const nextOperate = {
operation: OperationEvent.Station.stationSetCIAuto.confirm.operation, operation: OperationEvent.Station.stationSetCIAuto.confirm.operation,
@ -743,8 +731,7 @@ export default {
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode); const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode);
const nextOperate = { const nextOperate = {
operation: OperationEvent.Station.atsAutoControlALL.confirm.operation, operation: OperationEvent.Station.atsAutoControlALL.confirm.operation,
@ -762,8 +749,7 @@ export default {
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode); const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode);
const nextOperate = { const nextOperate = {
operation: OperationEvent.Station.stationCancelCIAuto.confirm.operation, operation: OperationEvent.Station.stationCancelCIAuto.confirm.operation,

View File

@ -651,11 +651,13 @@ export default {
children: [ children: [
{ {
title: '初始化', title: '初始化',
operate: OperationEvent.Command.commandNingBo3.line_section_clearSpeed operate: OperationEvent.Command.commandNingBo3.line_section_clearSpeed_init,
click: e => this.setLimitSpeed(e, false)
}, },
{ {
title: '确定/取消', title: '确定/取消',
operate: OperationEvent.Command.commandNingBo3.line_section_clearSpeed operate: OperationEvent.Command.commandNingBo3.line_section_clearSpeed_sure,
click: e => this.setLimitSpeed(e, true)
} }
] ]
} }
@ -1853,7 +1855,6 @@ export default {
const oldStation = this.$store.getters['map/getDeviceByCode'](oldMember.deviceCode); const oldStation = this.$store.getters['map/getDeviceByCode'](oldMember.deviceCode);
const newStation = this.$store.getters['map/getDeviceByCode'](newMember.deviceCode); const newStation = this.$store.getters['map/getDeviceByCode'](newMember.deviceCode);
if (oldStation.controller || newStation.controller) { if (oldStation.controller || newStation.controller) {
// console.log(9999999999, oldStation.controller, newStation.controller);
if (newStation.controller) { if (newStation.controller) {
let centerStation; let centerStation;
if (newStation.centralized) { if (newStation.centralized) {
@ -1903,8 +1904,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.arrangeRoute.doShow(); this.$refs.arrangeRoute.doShow();
} }
}); });
@ -1916,8 +1916,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainDistribution.doShow(operate, 'first'); this.$refs.trainDistribution.doShow(operate, 'first');
} }
}); });
@ -1929,8 +1928,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainDistribution.doShow(operate, 'second'); this.$refs.trainDistribution.doShow(operate, 'second');
} }
}); });
@ -1942,8 +1940,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainDistribution.doShow(operate, 'third'); this.$refs.trainDistribution.doShow(operate, 'third');
} }
}); });
@ -1956,8 +1953,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standControl.doShow(); this.$refs.standControl.doShow();
} }
}); });
@ -1970,8 +1966,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standDetain.doShow({active:'first'}); this.$refs.standDetain.doShow({active:'first'});
} }
}); });
@ -1983,8 +1978,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.intervalStopNumber.doShow(); this.$refs.intervalStopNumber.doShow();
} }
}); });
@ -1997,8 +1991,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.allocateTime.doShow(); this.$refs.allocateTime.doShow();
} }
}); });
@ -2011,8 +2004,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationTransfer.doShow(); this.$refs.stationTransfer.doShow();
} }
}); });
@ -2025,8 +2017,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationRequest.doShow(); this.$refs.stationRequest.doShow();
} }
}); });
@ -2039,8 +2030,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationDevolution.doShow(); this.$refs.stationDevolution.doShow();
} }
}); });
@ -2053,8 +2043,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationReclaim.doShow(); this.$refs.stationReclaim.doShow();
} }
}); });
@ -2066,8 +2055,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standDetail.doShow(); this.$refs.standDetail.doShow();
} }
}); });
@ -2079,8 +2067,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.switchCommand.doShow(); this.$refs.switchCommand.doShow();
} }
}); });
@ -2093,8 +2080,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'switchBlockSure' : 'switchBlockInit'].doShow(operate, sure); this.$refs[sure ? 'switchBlockSure' : 'switchBlockInit'].doShow(operate, sure);
} }
}); });
@ -2108,8 +2094,7 @@ export default {
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'switchBlockSure' : 'switchBlockInit'].doShow(operate, sure); this.$refs[sure ? 'switchBlockSure' : 'switchBlockInit'].doShow(operate, sure);
} }
}); });
@ -2122,8 +2107,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) =>{ this.$store.dispatch('training/nextNew', operate).then(({valid}) =>{
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.switchActive.doShow(); this.$refs.switchActive.doShow();
} }
}); });
@ -2136,8 +2120,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.switchDetail.doShow(); this.$refs.switchDetail.doShow();
} }
}); });
@ -2150,8 +2133,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.routeCommand.doShow(); this.$refs.routeCommand.doShow();
} }
}); });
@ -2164,8 +2146,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'signalGuideSure' : 'signalGuideInit'].doShow(operate, sure); this.$refs[sure ? 'signalGuideSure' : 'signalGuideInit'].doShow(operate, sure);
} }
}); });
@ -2177,8 +2158,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs['cancleSignalGuide'].doShow(operate); this.$refs['cancleSignalGuide'].doShow(operate);
// this.$refs[sure ? 'signalGuideSure' : 'signalGuideInit'].doShow(operate, sure); // this.$refs[sure ? 'signalGuideSure' : 'signalGuideInit'].doShow(operate, sure);
} }
@ -2192,8 +2172,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'signalCanBlockSure' : 'signalCanBlockInit'].doShow(operate, sure); this.$refs[sure ? 'signalCanBlockSure' : 'signalCanBlockInit'].doShow(operate, sure);
} }
}); });
@ -2205,8 +2184,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'sectionOpenSure' : 'sectionOpenInit'].doShow(operate, sure); this.$refs[sure ? 'sectionOpenSure' : 'sectionOpenInit'].doShow(operate, sure);
} }
}); });
@ -2218,8 +2196,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'cancelTransferLockSure' : 'cancelTransferLockInit'].doShow(operate, sure); this.$refs[sure ? 'cancelTransferLockSure' : 'cancelTransferLockInit'].doShow(operate, sure);
} }
}); });
@ -2231,8 +2208,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'cancelSwitchLockSure' : 'cancelSwitchLockInit'].doShow(operate, sure); this.$refs[sure ? 'cancelSwitchLockSure' : 'cancelSwitchLockInit'].doShow(operate, sure);
} }
}); });
@ -2244,8 +2220,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'remoteResetFuncSure' : 'remoteResetFuncInit'].doShow(operate, sure); this.$refs[sure ? 'remoteResetFuncSure' : 'remoteResetFuncInit'].doShow(operate, sure);
} }
}); });
@ -2257,8 +2232,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'sectionOpenSure' : 'sectionOpenInit'].doShow(operate, sure); this.$refs[sure ? 'sectionOpenSure' : 'sectionOpenInit'].doShow(operate, sure);
} }
}); });
@ -2270,21 +2244,19 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'sectionLimitSpeedSure' : 'sectionLimitSpeedInit'].doShow(operate, sure); this.$refs[sure ? 'sectionLimitSpeedSure' : 'sectionLimitSpeedInit'].doShow(operate, sure);
} }
}); });
}, },
handleSectionShow(item) { handleSectionShow(item) {
const operate = { const operate = {
type: 'bar', type: 'bar',
operation: item.operation operation: item.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.sectionShow.doShow(); this.$refs.sectionShow.doShow();
} }
}); });
@ -2296,8 +2268,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.sectionLock.doShow(); this.$refs.sectionLock.doShow();
} }
}); });
@ -2309,8 +2280,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.sectionLock.doShow(); this.$refs.sectionLock.doShow();
} }
}); });
@ -2322,8 +2292,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.sectionLock.doShow(); this.$refs.sectionLock.doShow();
} }
}); });
@ -2335,8 +2304,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.sectionLock.doShow(); this.$refs.sectionLock.doShow();
} }
}); });
@ -2348,8 +2316,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.signalModel.doShow(); this.$refs.signalModel.doShow();
} }
}); });
@ -2361,8 +2328,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.sectionLock.doShow(); this.$refs.sectionLock.doShow();
} }
}); });
@ -2374,8 +2340,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'signalBlockSure' : 'signalBlockInit'].doShow(operate, sure); this.$refs[sure ? 'signalBlockSure' : 'signalBlockInit'].doShow(operate, sure);
} }
}); });
@ -2387,8 +2352,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'signalBlockSure' : 'signalBlockInit'].doShow(operate, sure); this.$refs[sure ? 'signalBlockSure' : 'signalBlockInit'].doShow(operate, sure);
} }
}); });
@ -2400,8 +2364,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.signalDetail.doShow(operate); this.$refs.signalDetail.doShow(operate);
} }
}); });
@ -2413,8 +2376,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.initSignalMode.doShow(operate); this.$refs.initSignalMode.doShow(operate);
} }
}); });
@ -2426,8 +2388,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs[sure ? 'signalModeSure' : 'signalModeInit'].doShow(operate, sure); this.$refs[sure ? 'signalModeSure' : 'signalModeInit'].doShow(operate, sure);
} }
}); });
@ -2439,8 +2400,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
// this.$refs.systemDetain.doShow(operate); // this.$refs.systemDetain.doShow(operate);
this.$refs.standDetain.doShow({active:'second'}); this.$refs.standDetain.doShow({active:'second'});
} }
@ -2453,8 +2413,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.runningInterval.doShow(operate); this.$refs.runningInterval.doShow(operate);
} }
}); });
@ -2466,8 +2425,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.adjustStrategy.doShow(operate); this.$refs.adjustStrategy.doShow(operate);
} }
}); });
@ -2479,8 +2437,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.trainDepart.doShow(operate); this.$refs.trainDepart.doShow(operate);
} }
}); });
@ -2492,8 +2449,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.trainDepart.doShow(operate); this.$refs.trainDepart.doShow(operate);
} }
}); });
@ -2505,8 +2461,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.trainDepart.doShow(operate); this.$refs.trainDepart.doShow(operate);
} }
}); });
@ -2518,8 +2473,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.trainJumpStop.doShow(operate); this.$refs.trainJumpStop.doShow(operate);
} }
}); });
@ -2531,8 +2485,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.trainCancelDeviation.doShow(operate); this.$refs.trainCancelDeviation.doShow(operate);
} }
}); });
@ -2544,8 +2497,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.trainUpdateDeviation.doShow(operate); this.$refs.trainUpdateDeviation.doShow(operate);
} }
}); });
@ -2557,8 +2509,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.cancelRoute.doShow(operate); this.$refs.cancelRoute.doShow(operate);
} }
}); });
@ -2570,8 +2521,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.trainIdAssociated.doShow(operate); this.$refs.trainIdAssociated.doShow(operate);
} }
}); });
@ -2583,8 +2533,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.occupancyTrainCorrelation.doShow(operate); this.$refs.occupancyTrainCorrelation.doShow(operate);
} }
}); });
@ -2596,8 +2545,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.modifyTrainNumber.doShow(operate); this.$refs.modifyTrainNumber.doShow(operate);
} }
}); });
@ -2609,8 +2557,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.trainRunType.doShow(operate); this.$refs.trainRunType.doShow(operate);
} }
}); });
@ -2622,8 +2569,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break:true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break:true});
this.$refs.trainDetail.doShow(operate); this.$refs.trainDetail.doShow(operate);
} }
}); });
@ -2635,8 +2581,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
this.$refs.allTrainDetail.doShow(operate); this.$refs.allTrainDetail.doShow(operate);
} }
}); });
@ -2648,8 +2593,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({valid}) => { this.$store.dispatch('training/nextNew', operate).then(({valid}) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', {break:true});
this.$store.dispatch('menuOperation/handleBreakFlag', {break:true});
this.$refs.routeDetail.doShow(operate); this.$refs.routeDetail.doShow(operate);
} }
}); });

View File

@ -102,7 +102,8 @@ export default {
command: true, command: true,
sure: false, sure: false,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false,
}; };
}, },
computed: { computed: {
@ -125,16 +126,16 @@ export default {
return this.sectionList.filter(el => ['01', '04'].includes(el.type) ) return this.sectionList.filter(el => ['01', '04'].includes(el.type) )
}, },
domIdChoose() { domIdChoose() {
return this.dialogShow ? OperationEvent.Command.common.choose1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.choose.domId : '';
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? OperationEvent.Command.common.confirm1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
}, },
domIdApply() { domIdApply() {
return this.dialogShow ? OperationEvent.Command.common.apply1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
}, },
domIdClose() { domIdClose() {
return this.dialogShow ? OperationEvent.Command.common.close1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.close.domId : '';
} }
}, },
watch: { watch: {
@ -156,10 +157,12 @@ export default {
doShow(operate, sure) { doShow(operate, sure) {
this.operate = operate; this.operate = operate;
this.sure = sure; this.sure = sure;
if (!sure) this.command = true;
this.title = `${sure? '确认/取消过岔锁闭取消': '初始化过岔锁闭取消'}`; this.title = `${sure? '确认/取消过岔锁闭取消': '初始化过岔锁闭取消'}`;
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code); this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure
this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -181,7 +184,7 @@ export default {
const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code]) const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code])
const operate = { const operate = {
cmdType: this.sure&&isOK? this.cmdType: null, cmdType: this.sure&&isOK? this.cmdType: null,
operation: isClose ? OperationEvent.Command.common.confirm1.operation : OperationEvent.Command.common.apply1.operation, operation: isClose ? OperationEvent.Command.common.confirm.operation : OperationEvent.Command.common.apply.operation,
over: this.sure, over: this.sure,
param: {sectionCode: this.currentSelect.code} param: {sectionCode: this.currentSelect.code}
}; };
@ -207,14 +210,18 @@ export default {
} }
}, },
handleChangeLine(val) { handleChangeLine(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose1.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone') this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
@ -251,7 +258,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.common.close1.operation operation: OperationEvent.Command.common.close.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {

View File

@ -97,7 +97,8 @@ export default {
command: true, command: true,
sure: false, sure: false,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false
}; };
}, },
computed: { computed: {
@ -120,16 +121,16 @@ export default {
return this.sectionList.filter(el => ['01', '04'].includes(el.type) ) return this.sectionList.filter(el => ['01', '04'].includes(el.type) )
}, },
domIdChoose() { domIdChoose() {
return this.dialogShow ? OperationEvent.Command.common.choose1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.choose.domId : '';
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? OperationEvent.Command.common.confirm1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
}, },
domIdApply() { domIdApply() {
return this.dialogShow ? OperationEvent.Command.common.apply1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
}, },
domIdClose() { domIdClose() {
return this.dialogShow ? OperationEvent.Command.common.close1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.close.domId : '';
} }
}, },
watch: { watch: {
@ -151,10 +152,12 @@ export default {
doShow(operate, sure) { doShow(operate, sure) {
this.operate = operate; this.operate = operate;
this.sure = sure; this.sure = sure;
if (!sure) this.command = true;
this.title = `${sure? '确认/取消转换锁闭取消': '初始化转换锁闭取消'}`; this.title = `${sure? '确认/取消转换锁闭取消': '初始化转换锁闭取消'}`;
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code); this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure;
this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -176,7 +179,7 @@ export default {
const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code]) const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code])
const operate = { const operate = {
cmdType: this.sure&&isOK? this.cmdType: null, cmdType: this.sure&&isOK? this.cmdType: null,
operation: isClose ? OperationEvent.Command.common.confirm1.operation : OperationEvent.Command.common.apply1.operation, operation: isClose ? OperationEvent.Command.common.confirm.operation : OperationEvent.Command.common.apply.operation,
over: this.sure, over: this.sure,
param: {sectionCode: this.currentSelect.code} param: {sectionCode: this.currentSelect.code}
}; };
@ -202,14 +205,18 @@ export default {
} }
}, },
handleChangeLine(val) { handleChangeLine(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose1.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone') this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
@ -244,7 +251,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.common.close1.operation operation: OperationEvent.Command.common.close.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {

View File

@ -21,11 +21,6 @@
<span>{{ getCanGuide(scope.row.code) }}</span> <span>{{ getCanGuide(scope.row.code) }}</span>
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column prop="unblockProcess" label="引导过程" width="120">
<template slot-scope="scope">
<span>{{ getProcess(scope.row.code) }}</span>
</template>
</el-table-column> -->
<el-table-column prop="unblockProcess" width="150" label="区间信号引导过程" /> <el-table-column prop="unblockProcess" width="150" label="区间信号引导过程" />
</el-table> </el-table>
</el-row> </el-row>
@ -45,22 +40,18 @@
</el-row> </el-row>
</el-dialog> </el-dialog>
<notice-info ref="noticeInfo" pop-class="ningbo-01__systerm" /> <notice-info ref="noticeInfo" pop-class="ningbo-01__systerm" />
<!-- <signal-guide ref="signalGuide" @commandSuccess="commandSuccess" @cancelCommand="cancelCommand" /> -->
</div> </div>
</template> </template>
<script> <script>
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo'; import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
// import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
// import SignalGuide from './signalGuide';
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import CMD from '@/scripts/cmdPlugin/CommandEnum';
export default { export default {
name: 'CancleSignalGuide', name: 'CancleSignalGuide',
components: { components: {
// SignalGuide,
NoticeInfo NoticeInfo
}, },
data() { data() {
@ -71,8 +62,6 @@ export default {
dialogShow: false, dialogShow: false,
loading: false, loading: false,
operate: '' operate: ''
// initEle: null,
// commandEleCode: null
}; };
}, },
computed: { computed: {
@ -113,10 +102,7 @@ export default {
}, },
methods: { methods: {
doShow(operate) { doShow(operate) {
// this.initEle = null;
// this.commandEleCode = null;
this.operate = operate; this.operate = operate;
//
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.$refs.table.setCurrentRow(); this.$refs.table.setCurrentRow();
@ -151,15 +137,6 @@ export default {
return '否'; return '否';
} }
}, },
// getProcess(code) {
// if (this.commandEleCode === code) {
// return '';
// } else if (this.initEle && this.initEle.code === code) {
// return '/';
// } else {
// return '';
// }
// },
commit(isClose = false) { commit(isClose = false) {
this.loading = true; this.loading = true;
const val = this.selected || {}; const val = this.selected || {};
@ -203,12 +180,6 @@ export default {
this.$refs.noticeInfo.doShow(); this.$refs.noticeInfo.doShow();
}); });
}, },
// commandSuccess(code) {
// this.commandEleCode = code;
// },
// cancelCommand() {
// this.initEle = null;
// },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.common.close.operation operation: OperationEvent.Command.common.close.operation

View File

@ -87,7 +87,8 @@ export default {
command: true, command: true,
sure: false, sure: false,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false
}; };
}, },
computed: { computed: {
@ -110,16 +111,16 @@ export default {
return this.sectionList.filter(el => ['01', '04'].includes(el.type) ) return this.sectionList.filter(el => ['01', '04'].includes(el.type) )
}, },
domIdChoose() { domIdChoose() {
return this.dialogShow ? OperationEvent.Command.common.choose1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.choose.domId : '';
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? OperationEvent.Command.common.confirm1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
}, },
domIdApply() { domIdApply() {
return this.dialogShow ? OperationEvent.Command.common.apply1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
}, },
domIdClose() { domIdClose() {
return this.dialogShow ? OperationEvent.Command.common.close1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.close.domId : '';
} }
}, },
watch: { watch: {
@ -141,10 +142,12 @@ export default {
doShow(operate, sure) { doShow(operate, sure) {
this.operate = operate; this.operate = operate;
this.sure = sure; this.sure = sure;
if (!sure) this.command = true;
this.title = `${sure? '确认/取消远程预复位使能': '初始化远程预复位使能'}`; this.title = `${sure? '确认/取消远程预复位使能': '初始化远程预复位使能'}`;
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code); this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure;
this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -166,7 +169,7 @@ export default {
const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code]) const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code])
const operate = { const operate = {
cmdType: this.sure&&isOK? this.cmdType: null, cmdType: this.sure&&isOK? this.cmdType: null,
operation: isClose ? OperationEvent.Command.common.confirm1.operation : OperationEvent.Command.common.apply1.operation, operation: isClose ? OperationEvent.Command.common.confirm.operation : OperationEvent.Command.common.apply.operation,
over: this.sure, over: this.sure,
param: {sectionCode: this.currentSelect.code} param: {sectionCode: this.currentSelect.code}
}; };
@ -192,14 +195,18 @@ export default {
} }
}, },
handleChangeLine(val) { handleChangeLine(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose1.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone') this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
@ -227,7 +234,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.common.close1.operation operation: OperationEvent.Command.common.close.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {

View File

@ -1,8 +1,8 @@
<template> <template>
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="900px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false"> <el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="900px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
<el-row> <el-row>
<el-col :span="(sure? 18: 21) + (isLimitSpeed? 0: 3)"> <el-col :span="(sure? 18: 21) + (isSetSpeed? 0: 3)">
<el-table ref="singleTable1" :data="tempList" highlight-current-row height="300px" @current-change="selectLine1"> <el-table ref="singleTable1" :id="domIdChoose" :data="tempList" highlight-current-row height="300px" @current-change="selectLine1">
<el-table-column prop="name" label="轨道" /> <el-table-column prop="name" label="轨道" />
<el-table-column prop="blockStatus" width="120" label="MAU"> <el-table-column prop="blockStatus" width="120" label="MAU">
<template slot-scope="scope"> <template slot-scope="scope">
@ -28,8 +28,8 @@
<el-table-column prop="unblockProcess" label="用户里程终点" width="110" /> <el-table-column prop="unblockProcess" label="用户里程终点" width="110" />
</el-table> </el-table>
</el-col> </el-col>
<el-col :span="3" v-if="isLimitSpeed"> <el-col :span="3" v-if="isSetSpeed">
<el-table ref="singleTable2" :data="limitList" highlight-current-row height="300px" @current-change="selectLine2"> <el-table ref="singleTable2" :id="domIdSelect" :data="limitList" highlight-current-row height="300px" @current-change="selectLine2">
<el-table-column prop="name" label="速度" /> <el-table-column prop="name" label="速度" />
</el-table> </el-table>
</el-col> </el-col>
@ -48,7 +48,7 @@
<el-button :id="domIdConfirm" type="primary" :disabled="!!disabled" :loading="loading" @click="commit(true)">确定(O)</el-button> <el-button :id="domIdConfirm" type="primary" :disabled="!!disabled" :loading="loading" @click="commit(true)">确定(O)</el-button>
</el-col> </el-col>
<el-col :span="4" :offset="2"> <el-col :span="4" :offset="2">
<el-button :id="domIdConfirm" type="primary" :disabled="!!disabled" :loading="loading" @click="commit(false)">应用(A)</el-button> <el-button :id="domIdApply" type="primary" :disabled="!!disabled" :loading="loading" @click="commit(false)">应用(A)</el-button>
</el-col> </el-col>
<el-col :span="4" :offset="2"> <el-col :span="4" :offset="2">
<el-button :id="domIdClose" @click="cancel">关闭(C)</el-button> <el-button :id="domIdClose" @click="cancel">关闭(C)</el-button>
@ -122,7 +122,8 @@ export default {
sure: false, sure: false,
speedLimitValue: 0, speedLimitValue: 0,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false,
}; };
}, },
computed: { computed: {
@ -135,8 +136,8 @@ export default {
tempList() { tempList() {
return this.sectionList.filter(el => ['01', '04'].includes(el.type) ) return this.sectionList.filter(el => ['01', '04'].includes(el.type) )
}, },
isLimitSpeed() { isSetSpeed() {
return this.operate && this.operate.operation === OperationEvent.Command.commandNingBo3.line_section_limitSpeed.operation; return this.operate && this.operate.operation.includes(OperationEvent.Command.commandNingBo3.line_section_setSpeed.operation);
}, },
initSelect() { initSelect() {
return this.initInfo.initSelect||{}; return this.initInfo.initSelect||{};
@ -145,19 +146,25 @@ export default {
return this.initInfo.initParams||{}; return this.initInfo.initParams||{};
}, },
cmdType() { cmdType() {
return this.isLimitSpeed ? CMD.Section.CMD_SECTION_SET_LIMIT_SPEED : CMD.Section.CMD_SECTION_CANCEL_LIMIT_SPEED; return this.isSetSpeed ? CMD.Section.CMD_SECTION_SET_LIMIT_SPEED : CMD.Section.CMD_SECTION_CANCEL_LIMIT_SPEED;
}, },
disabled() { disabled() {
return !this.currentSelect || (this.isLimitSpeed? !this.speedLimitValue: !this.currentSelect.speedUpLimit) || this.noInit; return !this.currentSelect || (this.isSetSpeed? !this.speedLimitValue: !this.currentSelect.speedUpLimit) || this.noInit;
}, },
domIdChoose() {
return this.dialogShow ? OperationEvent.Command.common.choose.domId : '';
},
domIdSelect() {
return this.dialogShow ? OperationEvent.Command.common.select.domId : '';
},
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? OperationEvent.Command.common.confirm1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
}, },
domIdApply() { domIdApply() {
return this.dialogShow ? OperationEvent.Command.common.apply1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
}, },
domIdClose() { domIdClose() {
return this.dialogShow ? OperationEvent.Command.common.close1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.close.domId : '';
} }
}, },
watch: { watch: {
@ -180,18 +187,18 @@ export default {
this.operate = operate; this.operate = operate;
this.sure = sure; this.sure = sure;
if (this.isLimitSpeed) { if (this.isSetSpeed) {
this.title = `${sure ? '确认/取消设置临时限速区域' : '初始化设置临时限速区域'}`; this.title = `${sure ? '确认/取消设置临时限速区域' : '初始化设置临时限速区域'}`;
} else { } else {
this.title = `${sure ? '清除临时限速区域' : '初始化清除临时限速区域'}`; this.title = `${sure ? '清除临时限速区域' : '初始化清除临时限速区域'}`;
this.command = true;
} }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.speedLimitValue = this.initParams.value||0;
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure;
this.$refs.singleTable1.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.singleTable1.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.isLimitSpeed && this.$refs.singleTable2.setCurrentRow(this.limitList[this.initParams.value / 5 - 1]); this.isSetSpeed && this.$refs.singleTable2.setCurrentRow(sure? this.limitList[this.initParams.value / 5 - 1]: 0);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
}, },
@ -201,7 +208,7 @@ export default {
this.sure && (this.currentSelect = null); this.sure && (this.currentSelect = null);
this.sure && (this.speedLimitValue = 0); this.sure && (this.speedLimitValue = 0);
this.sure && this.$refs.singleTable1.setCurrentRow(); this.sure && this.$refs.singleTable1.setCurrentRow();
this.sure && this.isLimitSpeed && this.$refs.singleTable2.setCurrentRow(); this.sure && this.isSetSpeed && this.$refs.singleTable2.setCurrentRow();
this.sure && this.$root.$emit('iniCacheMap', this.cmdType.value, this.sure && this.$root.$emit('iniCacheMap', this.cmdType.value,
Object.fromEntries(Object.entries(this.getCacheMap()).filter(el => el[1].done == 'done')) Object.fromEntries(Object.entries(this.getCacheMap()).filter(el => el[1].done == 'done'))
) )
@ -215,7 +222,7 @@ export default {
const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code]) const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code])
const operate = { const operate = {
cmdType: this.sure&&isOK? this.cmdType: null, cmdType: this.sure&&isOK? this.cmdType: null,
operation: isClose ? OperationEvent.Command.common.confirm1.operation : OperationEvent.Command.common.apply1.operation, operation: isClose ? OperationEvent.Command.common.confirm.operation : OperationEvent.Command.common.apply.operation,
over: this.sure, over: this.sure,
param: {sectionCode: this.currentSelect.code, speedLimitValue:this.speedLimitValue} param: {sectionCode: this.currentSelect.code, speedLimitValue:this.speedLimitValue}
}; };
@ -241,14 +248,17 @@ export default {
}, },
selectLine1(val) { selectLine1(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
@ -260,13 +270,16 @@ export default {
}, },
selectLine2(val) { selectLine2(val) {
if (!val) { return; } if (!val) { return; }
this.speedLimitValue = val.value;
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
operation: OperationEvent.Command.common.choose1.operation, operation: OperationEvent.Command.common.select.operation,
val: val.value val: val.value
}; };
this.speedLimitValue = val.value; this.changeIgnore = false;
this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
@ -293,7 +306,7 @@ export default {
const cache = cacheMap[code]; const cache = cacheMap[code];
if (cache) { if (cache) {
if (this.sure) { if (this.sure) {
return cache.done == 'two' ? this.isLimitSpeed? '确认设置限速完成': '确认清除限速完成' : '等待确认/取消'; return cache.done == 'two' ? this.isSetSpeed? '确认设置限速完成': '确认清除限速完成' : '等待确认/取消';
} else { } else {
return cache.done == 'one' ? '已初始化' : '' return cache.done == 'one' ? '已初始化' : ''
} }
@ -302,7 +315,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.common.close1.operation operation: OperationEvent.Command.common.close.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {

View File

@ -92,7 +92,8 @@ export default {
command: true, command: true,
sure: false, sure: false,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false
}; };
}, },
computed: { computed: {
@ -118,16 +119,16 @@ export default {
return this.sectionList.filter(el => ['01', '04'].includes(el.type) ) return this.sectionList.filter(el => ['01', '04'].includes(el.type) )
}, },
domIdChoose() { domIdChoose() {
return this.dialogShow ? OperationEvent.Command.common.choose1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.choose.domId : '';
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? OperationEvent.Command.common.confirm1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
}, },
domIdApply() { domIdApply() {
return this.dialogShow ? OperationEvent.Command.common.apply1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
}, },
domIdClose() { domIdClose() {
return this.dialogShow ? OperationEvent.Command.common.close1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.close.domId : '';
} }
}, },
watch: { watch: {
@ -154,11 +155,13 @@ export default {
this.title = `${this.isBlock ? '确认/取消关闭轨道' : '确认/取消开放轨道'}`; this.title = `${this.isBlock ? '确认/取消关闭轨道' : '确认/取消开放轨道'}`;
} else { } else {
this.title = `${this.isBlock ? '初始化关闭轨道': '初始化开放轨道'}`; this.title = `${this.isBlock ? '初始化关闭轨道': '初始化开放轨道'}`;
this.command = true;
} }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code); this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure;
this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -180,7 +183,7 @@ export default {
const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code]) const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code])
const operate = { const operate = {
cmdType: this.sure&&isOK? this.cmdType: null, cmdType: this.sure&&isOK? this.cmdType: null,
operation: isClose ? OperationEvent.Command.common.confirm1.operation : OperationEvent.Command.common.apply1.operation, operation: isClose ? OperationEvent.Command.common.confirm.operation : OperationEvent.Command.common.apply.operation,
over: this.sure, over: this.sure,
param: {sectionCode: this.currentSelect.code} param: {sectionCode: this.currentSelect.code}
}; };
@ -206,14 +209,18 @@ export default {
} }
}, },
handleChangeLine(val) { handleChangeLine(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose1.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone') this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
@ -246,7 +253,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.common.close1.operation operation: OperationEvent.Command.common.close.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {

View File

@ -7,6 +7,7 @@
:data="tempList" :data="tempList"
highlight-current-row highlight-current-row
height="350px" height="350px"
:id="domIdChoose"
@current-change="handleCurrentChange" @current-change="handleCurrentChange"
> >
<el-table-column prop="name" label="信号机" /> <el-table-column prop="name" label="信号机" />
@ -93,7 +94,8 @@ export default {
operate: {}, operate: {},
sure: false, sure: false,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false
}; };
}, },
computed: { computed: {
@ -118,14 +120,17 @@ export default {
disabled() { disabled() {
return !this.currentSelect || (this.isBlock? this.currentSelect.blockade: !this.currentSelect.blockade) || this.noInit; return !this.currentSelect || (this.isBlock? this.currentSelect.blockade: !this.currentSelect.blockade) || this.noInit;
}, },
domIdChoose() {
return this.dialogShow ? OperationEvent.Command.common.choose.domId : '';
},
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? OperationEvent.Command.common.confirm1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
}, },
domIdApply() { domIdApply() {
return this.dialogShow ? OperationEvent.Command.common.apply1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
}, },
domIdClose() { domIdClose() {
return this.dialogShow ? OperationEvent.Command.common.close1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.close.domId : '';
} }
}, },
watch: { watch: {
@ -152,11 +157,13 @@ export default {
this.title = `${this.isBlock ? '确认/取消信号机封锁' : '确认/取消信号机解除封锁'}`; this.title = `${this.isBlock ? '确认/取消信号机封锁' : '确认/取消信号机解除封锁'}`;
} else { } else {
this.title = `${this.isBlock ? '初始化信号机封锁': '初始化信号机解除封锁'}`; this.title = `${this.isBlock ? '初始化信号机封锁': '初始化信号机解除封锁'}`;
this.command = true;
} }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code); this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure;
this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -178,7 +185,7 @@ export default {
const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code]) const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code])
const operate = { const operate = {
cmdType: this.sure&&isOK? this.cmdType: null, cmdType: this.sure&&isOK? this.cmdType: null,
operation: isClose ? OperationEvent.Command.common.confirm1.operation : OperationEvent.Command.common.apply1.operation, operation: isClose ? OperationEvent.Command.common.confirm.operation : OperationEvent.Command.common.apply.operation,
over: this.sure, over: this.sure,
param: {signalCode: this.currentSelect.code} param: {signalCode: this.currentSelect.code}
}; };
@ -204,14 +211,18 @@ export default {
} }
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone') this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
@ -243,7 +254,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.common.close1.operation operation: OperationEvent.Command.common.close.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {

View File

@ -7,6 +7,7 @@
:data="tempList" :data="tempList"
highlight-current-row highlight-current-row
height="300px" height="300px"
:id="domIdChoose"
@current-change="handleCurrentChange" @current-change="handleCurrentChange"
> >
<el-table-column prop="name" label="信号机" /> <el-table-column prop="name" label="信号机" />
@ -36,7 +37,7 @@
<el-button :id="domIdConfirm" type="primary" :disabled="!!disabled" :loading="loading" @click="commit(true)">确定(O)</el-button> <el-button :id="domIdConfirm" type="primary" :disabled="!!disabled" :loading="loading" @click="commit(true)">确定(O)</el-button>
</el-col> </el-col>
<el-col :span="4" :offset="2"> <el-col :span="4" :offset="2">
<el-button :id="domIdConfirm" type="primary" :disabled="!!disabled" :loading="loading" @click="commit(false)">应用(A)</el-button> <el-button :id="domIdApply" type="primary" :disabled="!!disabled" :loading="loading" @click="commit(false)">应用(A)</el-button>
</el-col> </el-col>
<el-col :span="4" :offset="2"> <el-col :span="4" :offset="2">
<el-button :id="domIdClose" @click="cancel">关闭(C)</el-button> <el-button :id="domIdClose" @click="cancel">关闭(C)</el-button>
@ -89,7 +90,8 @@ export default {
command: true, command: true,
sure: false, sure: false,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false
}; };
}, },
computed: { computed: {
@ -111,14 +113,17 @@ export default {
disabled() { disabled() {
return !this.currentSelect || this.currentSelect.blockade || this.noInit; return !this.currentSelect || this.currentSelect.blockade || this.noInit;
}, },
domIdClose() { domIdChoose() {
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : ''; return this.dialogShow ? OperationEvent.Command.common.choose.domId : '';
},
domIdChoose() {
return this.dialogShow ? OperationEvent.Signal.arrangementRoute.choose.domId : '';
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? OperationEvent.Signal.arrangementRoute.menu.domId : ''; return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
},
domIdApply() {
return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
},
domIdClose() {
return this.dialogShow ? OperationEvent.Command.common.close.domId : '';
} }
}, },
watch: { watch: {
@ -140,11 +145,13 @@ export default {
doShow(operate, sure) { doShow(operate, sure) {
this.operate = operate; this.operate = operate;
this.sure = sure; this.sure = sure;
if (!sure) this.command = true;
this.title = `${sure ? '确认/取消允许锁闭' : '初始化允许锁闭'}`; this.title = `${sure ? '确认/取消允许锁闭' : '初始化允许锁闭'}`;
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code); this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure;
this.$refs.table.setCurrentRow(sure ? this.tempList.find(el => el.code == this.initSelect.code) : null); this.$refs.table.setCurrentRow(sure ? this.tempList.find(el => el.code == this.initSelect.code) : null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -166,7 +173,7 @@ export default {
const isOK = this.command && (!this.sure || this.sure && cacheMap[this.currentSelect.code]); const isOK = this.command && (!this.sure || this.sure && cacheMap[this.currentSelect.code]);
const operate = { const operate = {
cmdType: this.sure && isOK ? this.cmdType : null, cmdType: this.sure && isOK ? this.cmdType : null,
operation: this.command ? OperationEvent.Signal.lock.confirm1.operation : OperationEvent.Signal.unlock.confirm1.operation, operation: isClose? OperationEvent.Signal.lock.confirm.operation : OperationEvent.Signal.unlock.confirm.operation,
over: this.sure, over: this.sure,
param: {signalCode: this.currentSelect.code} param: {signalCode: this.currentSelect.code}
}; };
@ -192,14 +199,18 @@ export default {
} }
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone'); this.$emit('updateDone');
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
@ -228,7 +239,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.cancel.menu.operation operation: OperationEvent.Command.close.menu.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {

View File

@ -7,6 +7,7 @@
:data="tempList" :data="tempList"
highlight-current-row highlight-current-row
height="300px" height="300px"
:id="domIdChoose"
@current-change="handleCurrentChange" @current-change="handleCurrentChange"
> >
<el-table-column prop="name" label="信号机" /> <el-table-column prop="name" label="信号机" />
@ -93,7 +94,8 @@ export default {
command: true, command: true,
sure: false, sure: false,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false
}; };
}, },
computed: { computed: {
@ -116,16 +118,16 @@ export default {
return !this.currentSelect || !this.currentSelect.callOn || this.noInit; return !this.currentSelect || !this.currentSelect.callOn || this.noInit;
}, },
domIdChoose() { domIdChoose() {
return this.dialogShow ? OperationEvent.Command.common.choose1.domId : '' return this.dialogShow ? OperationEvent.Command.common.choose.domId : ''
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? OperationEvent.Command.common.confirm1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
}, },
domIdClose() { domIdClose() {
return this.dialogShow ? OperationEvent.Command.common.close1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.close.domId : '';
}, },
domIdApply() { domIdApply() {
return this.dialogShow ? OperationEvent.Command.common.apply1.domId : ''; return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
} }
}, },
watch: { watch: {
@ -147,11 +149,13 @@ export default {
doShow(operate, sure) { doShow(operate, sure) {
this.operate = operate; this.operate = operate;
this.sure = sure; this.sure = sure;
if (!sure) this.command = true;
this.title = `${sure? '确认/取消引导': '初始化引导'}`; this.title = `${sure? '确认/取消引导': '初始化引导'}`;
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code); this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure;
this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -173,9 +177,7 @@ export default {
const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code]) const isOK = this.command&&(!this.sure || this.sure&&cacheMap[this.currentSelect.code])
const operate = { const operate = {
cmdType: this.sure&&isOK? this.cmdType: null, cmdType: this.sure&&isOK? this.cmdType: null,
operation: this.command operation: isClose ? OperationEvent.Command.common.confirm.operation : OperationEvent.Command.common.apply.operation,
? OperationEvent.Command.common.confirm1.operation
: OperationEvent.Command.common.apply1.operation,
over: this.sure, over: this.sure,
param: {signalCode: this.currentSelect.code} param: {signalCode: this.currentSelect.code}
}; };
@ -202,13 +204,17 @@ export default {
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone') this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
@ -251,7 +257,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.common.close1.operation operation: OperationEvent.Command.common.close.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {

View File

@ -84,7 +84,8 @@ export default {
operate: {}, operate: {},
sure: false, sure: false,
currentSelect: null, currentSelect: null,
noInit: true noInit: true,
changeIgnore: false
}; };
}, },
computed: { computed: {
@ -101,7 +102,7 @@ export default {
return this.initInfo.initSelect||{}; return this.initInfo.initSelect||{};
}, },
isCbtc() { isCbtc() {
return this.operate.operation === OperationEvent.Command.mBar.cbtcMode.operation; return true //this.operate.operation.includes(OperationEvent.Command.mBar.cbtcMode.operation);
}, },
cmdType() { cmdType() {
return this.isCbtc ? CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING : CMD.Signal.CMD_SIGNAL_CLOSE_AUTO_SETTING; return this.isCbtc ? CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING : CMD.Signal.CMD_SIGNAL_CLOSE_AUTO_SETTING;
@ -146,11 +147,13 @@ export default {
this.title = `${this.isCbtc ? '确认/取消CBTC模式' : '确认/取消后备模式'}`; this.title = `${this.isCbtc ? '确认/取消CBTC模式' : '确认/取消后备模式'}`;
} else { } else {
this.title = `${this.isCbtc ? '初始化CBTC模式' : '初始化后备模式'}`; this.title = `${this.isCbtc ? '初始化CBTC模式' : '初始化后备模式'}`;
this.command = true;
} }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code); this.currentSelect = this.$store.getters['map/getDeviceByCode'](this.initSelect.code);
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure;
this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -166,14 +169,18 @@ export default {
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });

View File

@ -95,6 +95,7 @@ export default {
operate: {}, operate: {},
currentSelect: null, currentSelect: null,
noInit: true, noInit: true,
changeIgnore: false,
}; };
}, },
computed: { computed: {
@ -156,11 +157,13 @@ export default {
this.title = `${this.isBlock ? '确认/取消道岔封锁' : '确认/取消道岔解除封锁'}`; this.title = `${this.isBlock ? '确认/取消道岔封锁' : '确认/取消道岔解除封锁'}`;
} else { } else {
this.title = `${this.isBlock ? '初始化道岔封锁': '初始化解除封锁'}`; this.title = `${this.isBlock ? '初始化道岔封锁': '初始化解除封锁'}`;
this.command = true;
} }
this.currentSelect = sure? this.$store.getters['map/getDeviceByCode'](this.initSelect.code): null this.currentSelect = sure? this.$store.getters['map/getDeviceByCode'](this.initSelect.code): null
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.changeIgnore = sure
this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null); this.$refs.table.setCurrentRow(sure? this.tempList.find(el => el.code == this.initSelect.code): null);
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}); });
@ -210,14 +213,17 @@ export default {
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
if (!val) { return; } if (!val) { return; }
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code);
this.$emit('updateDone')
if (this.changeIgnore) { return; }
const step = { const step = {
code: val.code, code: val.code,
operation: OperationEvent.Command.common.choose.operation, operation: OperationEvent.Command.common.choose.operation,
val: val.code val: val.code
}; };
this.currentSelect = this.$store.getters['map/getDeviceByCode'](val.code); this.changeIgnore = false;
this.$emit('updateDone')
this.$store.dispatch('training/nextNew', step).then(({ valid }) => { this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
if (valid) { if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });

View File

@ -234,9 +234,16 @@ export default {
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_switch.operation, tip: '鼠标左键选择【道岔】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_switch.operation, tip: '鼠标左键选择【道岔】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_switch_block.operation, tip: '鼠标左键选择【封锁】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_switch_block.operation, tip: '鼠标左键选择【封锁】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择道岔【{7}】', codeType:'SWITCH', val: '{17}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_switch_block_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '02', orderNum: 5, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择道岔【{7}】', codeType:'SWITCH', val: '{17}' },
{ deviceType: '02', orderNum: 6, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }, { deviceType: '02', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '02', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 8, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line_switch.operation, tip: '鼠标左键选择【道岔】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_switch_block.operation, tip: '鼠标左键选择【封锁】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_switch_block_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '02', orderNum: 12, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '02', orderNum: 13, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
] ]
}, },
{ {
@ -252,9 +259,16 @@ export default {
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_switch.operation, tip: '鼠标左键选择【道岔】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_switch.operation, tip: '鼠标左键选择【道岔】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_switch_unblock.operation, tip: '鼠标左键选择【解除封锁】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_switch_unblock.operation, tip: '鼠标左键选择【解除封锁】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择道岔【{7}】', codeType:'SWITCH', val: '{17}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_switch_unblock_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '02', orderNum: 5, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择道岔【{7}】', codeType:'SWITCH', val: '{17}' },
{ deviceType: '02', orderNum: 6, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }, { deviceType: '02', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '02', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 8, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line_switch.operation, tip: '鼠标左键选择【道岔】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_switch_unblock.operation, tip: '鼠标左键选择【解除封锁】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_switch_unblock_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '02', orderNum: 12, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '02', orderNum: 13, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
] ]
}, },
{ {
@ -293,7 +307,6 @@ export default {
{ deviceType: '02', orderNum: 6, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }, { deviceType: '02', orderNum: 6, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
] ]
}, },
{ {
maxDuration: 15, maxDuration: 15,
minDuration: 8, minDuration: 8,
@ -307,9 +320,36 @@ export default {
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_guide.operation, tip: '鼠标左键选择【引导】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_guide.operation, tip: '鼠标左键选择【引导】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_signal_guide_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '04', orderNum: 5, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' },
{ deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' } { deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 8, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_signal_guide.operation, tip: '鼠标左键选择【引导】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_signal_guide_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '04', orderNum: 12, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 13, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }
],
config: {onlySignalOP:true}
},
{
maxDuration: 15,
minDuration: 8,
operateType: CMD.Signal.CMD_SIGNAL_CLOSE_GUIDE.value,
skinCode: '12',
trainingName: '信号机引导清除({3})',
trainingRemark: '信号机引导清除',
trainingType: 'Signal',
productTypes: ['01', '02'],
stepVOList: [
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_guide.operation, tip: '鼠标左键选择【引导】' },
{ deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_signal_guide_clear.operation, tip: '鼠标左键选择【清除】' },
{ deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' },
{ deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
], ],
config: {onlySignalOP:true} config: {onlySignalOP:true}
}, },
@ -325,10 +365,18 @@ export default {
stepVOList: [ stepVOList: [
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_lockOrNot.operation, tip: '鼠标左键选择【开始锁闭解除】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_lockOrNot.operation, tip: '鼠标左键选择【取消允许锁闭】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_signal_lockOrNot_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '04', orderNum: 5, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' },
{ deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' } { deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 8, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_signal_lockOrNot.operation, tip: '鼠标左键选择【取消允许锁闭】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_signal_lockOrNot_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '04', orderNum: 12, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 13, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }
] ]
}, },
{ {
@ -344,10 +392,16 @@ export default {
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_block.operation, tip: '鼠标左键选择【封锁】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_block.operation, tip: '鼠标左键选择【封锁】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_signal_block_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '04', orderNum: 5, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' },
{ deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.confirm1.operation, tip: '请点击【确定】' }, { deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' } { deviceType: '04', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 8, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_signal_block.operation, tip: '鼠标左键选择【封锁】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_signal_block_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '04', orderNum: 12, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 13, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }
] ]
}, },
{ {
@ -363,10 +417,16 @@ export default {
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_unblock.operation, tip: '鼠标左键选择【解除封锁】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_signal_unblock.operation, tip: '鼠标左键选择【解除封锁】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_signal_unblock_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '04', orderNum: 5, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择信号机【{5}】', codeType:'SIGNAL', val: '{6}' },
{ deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.confirm1.operation, tip: '请点击【确定】' }, { deviceType: '04', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' } { deviceType: '04', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 8, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line_signal.operation, tip: '鼠标左键选择【信号机】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_signal_unblock.operation, tip: '鼠标左键选择【解除封锁】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_signal_unblock_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '04', orderNum: 12, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '04', orderNum: 13, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }
] ]
}, },
{ {
@ -435,10 +495,17 @@ export default {
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_section_open.operation, tip: '鼠标左键选择【开放】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_section_open.operation, tip: '鼠标左键选择【开放】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择轨道【{8}】', codeType:'SECTION', val: '{19}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_section_open_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '03', orderNum: 5, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择轨道【{8}】', codeType:'SECTION', val: '{19}' },
{ deviceType: '03', orderNum: 6, operateCode: OperationEvent.Command.common.confirm1.operation, tip: '请点击【确定】' }, { deviceType: '03', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '03', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' } { deviceType: '03', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 8, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_section_open.operation, tip: '鼠标左键选择【开放】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_section_open_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '03', orderNum: 12, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '03', orderNum: 13, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }
] ]
}, },
{ {
@ -454,10 +521,16 @@ export default {
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_section_close.operation, tip: '鼠标左键选择【关闭】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_section_close.operation, tip: '鼠标左键选择【关闭】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择轨道【{8}】', codeType:'SECTION', val: '{19}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_section_close_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '03', orderNum: 5, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择轨道【{8}】', codeType:'SECTION', val: '{19}' },
{ deviceType: '03', orderNum: 6, operateCode: OperationEvent.Command.common.confirm1.operation, tip: '请点击【确定】' }, { deviceType: '03', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '03', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' } { deviceType: '03', orderNum: 7, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 8, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_section_close.operation, tip: '鼠标左键选择【关闭】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_section_close_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '03', orderNum: 12, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '03', orderNum: 13, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }
] ]
}, },
{ {
@ -473,11 +546,47 @@ export default {
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' }, { deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' }, { deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_section_limitSpeed.operation, tip: '鼠标左键选择【临时限速】' }, { deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_section_limitSpeed.operation, tip: '鼠标左键选择【临时限速】' },
{ deviceType: 'mbm', orderNum: 4, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择轨道【{8}】', codeType:'SECTION', val: '{19}' }, { deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_section_setSpeed.operation, tip: '鼠标左键选择【设置】' },
{ deviceType: 'mbm', orderNum: 5, operateCode: OperationEvent.Command.common.choose1.operation, tip: '请选择速度【25】', val: '25' }, { deviceType: 'bar', orderNum: 5, operateCode: OperationEvent.Command.commandNingBo3.line_section_setSpeed_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: '03', orderNum: 6, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' }, { deviceType: 'mbm', orderNum: 6, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择轨道【{8}】', codeType:'SECTION', val: '{19}' },
{ deviceType: '03', orderNum: 7, operateCode: OperationEvent.Command.common.confirm1.operation, tip: '请点击【确定】' }, { deviceType: 'mbm', orderNum: 7, operateCode: OperationEvent.Command.common.select.operation, tip: '请选择速度【25】', val: '25' },
{ deviceType: '03', orderNum: 8, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' } { deviceType: '03', orderNum: 8, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '03', orderNum: 9, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' },
{ deviceType: 'bar', orderNum: 12, operateCode: OperationEvent.Command.commandNingBo3.line_section_limitSpeed.operation, tip: '鼠标左键选择【临时限速】' },
{ deviceType: 'bar', orderNum: 13, operateCode: OperationEvent.Command.commandNingBo3.line_section_setSpeed.operation, tip: '鼠标左键选择【设置】' },
{ deviceType: 'bar', orderNum: 14, operateCode: OperationEvent.Command.commandNingBo3.line_section_setSpeed_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '03', orderNum: 15, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '03', orderNum: 16, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }
]
},
{
maxDuration: 15,
minDuration: 8,
operateType: CMD.Section.CMD_SECTION_CANCEL_LIMIT_SPEED.value,
skinCode: '12',
trainingName: '轨道清除限速({8}{9})',
trainingRemark: '轨道清除限速',
trainingType: 'Section',
productTypes: ['01', '02'],
stepVOList: [
{ deviceType: 'bar', orderNum: 1, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 2, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' },
{ deviceType: 'bar', orderNum: 3, operateCode: OperationEvent.Command.commandNingBo3.line_section_limitSpeed.operation, tip: '鼠标左键选择【临时限速】' },
{ deviceType: 'bar', orderNum: 4, operateCode: OperationEvent.Command.commandNingBo3.line_section_clearSpeed.operation, tip: '鼠标左键选择【清除】' },
{ deviceType: 'bar', orderNum: 5, operateCode: OperationEvent.Command.commandNingBo3.line_section_clearSpeed_init.operation, tip: '鼠标左键选择【初始化】' },
{ deviceType: 'mbm', orderNum: 6, operateCode: OperationEvent.Command.common.choose.operation, tip: '请选择轨道【{8}】', codeType:'SECTION', val: '{19}' },
{ deviceType: '03', orderNum: 7, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '03', orderNum: 8, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' },
{ deviceType: 'bar', orderNum: 9, operateCode: OperationEvent.Command.commandNingBo3.line.operation, tip: '鼠标左键选择【线路】' },
{ deviceType: 'bar', orderNum: 10, operateCode: OperationEvent.Command.commandNingBo3.line_section.operation, tip: '鼠标左键选择【轨道】' },
{ deviceType: 'bar', orderNum: 11, operateCode: OperationEvent.Command.commandNingBo3.line_section_limitSpeed.operation, tip: '鼠标左键选择【临时限速】' },
{ deviceType: 'bar', orderNum: 12, operateCode: OperationEvent.Command.commandNingBo3.line_section_clearSpeed.operation, tip: '鼠标左键选择【清除】' },
{ deviceType: 'bar', orderNum: 13, operateCode: OperationEvent.Command.commandNingBo3.line_section_clearSpeed_sure.operation, tip: '鼠标左键选择【确定/取消】' },
{ deviceType: '03', orderNum: 14, operateCode: OperationEvent.Command.common.apply.operation, tip: '请点击【应用】' },
{ deviceType: '03', orderNum: 15, operateCode: OperationEvent.Command.common.close.operation, tip: '请点击【关闭】' }
] ]
}, },

View File

@ -330,8 +330,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationControlConvert.doShow(operate); this.$refs.stationControlConvert.doShow(operate);
} }
}); });
@ -343,8 +342,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.passwordBox.doShow(operate); this.$refs.passwordBox.doShow(operate);
} }
}); });
@ -356,8 +354,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.stationControlConvert.doShow(operate); this.$refs.stationControlConvert.doShow(operate);
} }
}); });
@ -369,8 +366,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.viewTrainId.doShow(operate); this.$refs.viewTrainId.doShow(operate);
} }
}); });
@ -382,8 +378,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.viewName.doShow(operate); this.$refs.viewName.doShow(operate);
} }
}); });
@ -395,8 +390,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.viewDevice.doShow(operate); this.$refs.viewDevice.doShow(operate);
} }
}); });
@ -408,8 +402,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainAdd.doShow(operate); this.$refs.trainAdd.doShow(operate);
} }
}); });
@ -421,8 +414,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainTranstalet.doShow(operate); this.$refs.trainTranstalet.doShow(operate);
} }
}); });
@ -434,8 +426,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.trainDelete.doShow(operate); this.$refs.trainDelete.doShow(operate);
} }
}); });
@ -447,8 +438,7 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.manageUser.doShow(operate); this.$refs.manageUser.doShow(operate);
} }
}); });
@ -460,15 +450,14 @@ export default {
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.$refs.menuBar.closeMenu(true); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.helpAbout.doShow(operate); this.$refs.helpAbout.doShow(operate);
} }
}); });
}, },
// //
refresh() { refresh() {
this.$refs.menuBar.closeMenu(true);
EventBus.$emit('refresh'); EventBus.$emit('refresh');
}, },
getLoginResult(operate) { getLoginResult(operate) {

View File

@ -11,7 +11,7 @@
top="10vh" top="10vh"
:close-on-click-modal="false" :close-on-click-modal="false"
> >
<data-form ref="dataform" :form="form" :form-model="formModel" :rules="rules" /> <data-form ref="dataform" v-loading="dataLoading" :form="form" :form-model="formModel" :rules="rules" />
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
<el-button size="small" @click="doClose">{{ $t('global.cancel') }}</el-button> <el-button size="small" @click="doClose">{{ $t('global.cancel') }}</el-button>
<el-button type="primary" size="small" :loading="loading" @click="handleCommit">{{ $t('global.confirm') }}</el-button> <el-button type="primary" size="small" :loading="loading" @click="handleCommit">{{ $t('global.confirm') }}</el-button>
@ -33,8 +33,10 @@ export default {
data() { data() {
return { return {
dialogShow: false, dialogShow: false,
dataLoading:false,
routingList: [], routingList: [],
loading: false, loading: false,
runningRoutingMap:{},
runLevelList: [ runLevelList: [
{ value: 1, label: '等级一' }, { value: 1, label: '等级一' },
{ value: 2, label: '等级二' }, { value: 2, label: '等级二' },
@ -49,11 +51,11 @@ export default {
overTime: '', // overTime: '', //
runLevel:'', // runLevel:'', //
departureInterval:180, // departureInterval:180, //
// reentryTime:120, //
inboundRouting:'', // code inboundRouting:'', // code
outboundRouting:'', // code outboundRouting:'', // code
runningRouting1: '', // code1 runningRouting1: '', // code1
runningRouting2: '' // code2 runningRouting2: '', // code2
runningRouting:''
}, },
rules: { rules: {
@ -74,23 +76,15 @@ export default {
departureInterval:[ departureInterval:[
{ required: true, message: '请填写发车间隔', trigger: 'blur' } { required: true, message: '请填写发车间隔', trigger: 'blur' }
], ],
// reentryTime:[
// { required: true, message: '', trigger: 'blur' }
// ],
inboundRouting: [ inboundRouting: [
{ required: true, message: '请选择回库交路', trigger: 'change' } { required: true, message: '请选择回库交路', trigger: 'change' }
], ],
runningRouting: [
{ required: true, message: '请选择环路', trigger: 'blur' },
{ required: true, message: '请选择环路', trigger: 'change' }
],
outboundRouting: [ outboundRouting: [
{ required: true, message: '请选择出库交路', trigger: 'change' } { required: true, message: '请选择出库交路', trigger: 'change' }
],
runningRouting1: [
// message: '',
{ required: true, validator: this.validateRunningRouting, trigger: 'change' },
{ required: true, validator: this.validateRunningRouting, trigger: 'blur' }
],
runningRouting2: [
{ required: true, validator: this.validateRunningRouting, trigger: 'change' },
{ required: true, validator: this.validateRunningRouting, trigger: 'blur' }
] ]
} }
}; };
@ -113,10 +107,10 @@ export default {
{ prop: 'overTime', label: '结束时间', type: 'timePicker', selectableRange:'02:00:00-23:59:59'}, { prop: 'overTime', label: '结束时间', type: 'timePicker', selectableRange:'02:00:00-23:59:59'},
{ prop: 'runLevel', label: '运行等级', type: 'select', options: this.runLevelList }, { prop: 'runLevel', label: '运行等级', type: 'select', options: this.runLevelList },
{ prop: 'departureInterval', label: '发车间隔', type: 'number', show:this.formModel.gernarateType == '02', min:0, step:1, precisionFlag:true, precision:0, message:'s'}, { prop: 'departureInterval', label: '发车间隔', type: 'number', show:this.formModel.gernarateType == '02', min:0, step:1, precisionFlag:true, precision:0, message:'s'},
// { prop: 'reentryTime', label: '', type: 'number', min:120, step:1, precisionFlag:true, precision:0, message:'s' },
{ prop: 'outboundRouting', label: '出库交路', type: 'select', options: this.covertRouting('OUTBOUND'), noDataText:'请先设置交路'}, { prop: 'outboundRouting', label: '出库交路', type: 'select', options: this.covertRouting('OUTBOUND'), noDataText:'请先设置交路'},
{ prop: 'runningRouting1', label: '环路交路1', type: 'select', show:true, options: this.covertRouting('LOOP'), noDataText:'请先设置交路', change:true, onChange:this.changeRoute2 }, { prop: 'runningRouting1', label: '环路交路1', type: 'select', show:false},
{ prop: 'runningRouting2', label: '环路交路2', type: 'select', show:true, options: this.covertRouting('LOOP'), noDataText:'请先设置交路', change:true, onChange:this.changeRoute1}, { prop: 'runningRouting2', label: '环路交路2', type: 'select', show:false},
{prop:'runningRouting', label:'环路', type: 'select', options:this.covertRoutingCircle(), noDataText:'请先设置交路', change:true, onChange:this.changeRoute},
{ prop: 'inboundRouting', label: '入库交路', type: 'select', options: this.covertRouting('INBOUND'), noDataText:'请先设置交路'} { prop: 'inboundRouting', label: '入库交路', type: 'select', options: this.covertRouting('INBOUND'), noDataText:'请先设置交路'}
] ]
}; };
@ -127,9 +121,39 @@ export default {
this.loading = false; this.loading = false;
const mapId = this.$route.query.mapId; const mapId = this.$route.query.mapId;
if (mapId) { if (mapId) {
const runningRoutingMap = {};
this.dataLoading = true;
listUserRoutingData(mapId).then(response => { listUserRoutingData(mapId).then(response => {
this.routingList = response.data.map(elem => { return { value: elem.code, label: elem.name, routingType:elem.routingType }; }); const list = response.data;
this.routingList = list.map(elem => { return { value: elem.code, label: elem.name, routingType:elem.routingType }; });
list.forEach(elem=>{
// this.routingList.push({value: elem.code, label: elem.name, routingType:elem.routingType});
if (elem.routingType === 'LOOP') {
// const name = elem.name;
// let temp = '';
if (elem.right) {
// temp = name.split('-')[0];
// const data = ;
const data = runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode];
if (!data) { runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode] = {}; }
runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode].label = elem.name;
runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode].value = elem.startSectionCode + '-' + elem.endSectionCode;
runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode].runningRouting1 = elem.code;
} else {
// temp = name.split('-')[1];
// const data = ;
const data = runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode];
if (!data) { runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode] = {}; }
runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode].label = elem.name;
runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode].value = elem.endSectionCode + '-' + elem.startSectionCode;
runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode].runningRouting2 = elem.code;
}
}
});
this.runningRoutingMap = runningRoutingMap;
this.dataLoading = false;
}).catch(() => { }).catch(() => {
this.dataLoading = false;
this.$messageBox(`获取交路列表失败`); this.$messageBox(`获取交路列表失败`);
}); });
} }
@ -171,34 +195,39 @@ export default {
} }
} }
}, },
validateRunningRouting(rule, value, callback) { // changeRoute(runningRouting) {
if (value.trim().length == 0) { // if (this.formModel[runningRouting]) { this.$refs.dataform.validateField([runningRouting]); }
return callback(new Error('请选择环路')); // },
} else {
if (this.formModel.runningRouting1 == this.formModel.runningRouting2) {
return callback(new Error('环路交路1和环路交路2不能相同'));
} else {
return callback();
}
}
},
changeRoute2() {
this.changeRoute('runningRouting2');
},
changeRoute1() {
this.changeRoute('runningRouting1');
},
changeRoute(runningRouting) { changeRoute(runningRouting) {
if (this.formModel[runningRouting]) { this.$refs.dataform.validateField([runningRouting]); } const temp = this.runningRoutingMap[runningRouting];
this.formModel.runningRouting1 = temp.runningRouting1;
this.formModel.runningRouting2 = temp.runningRouting2;
}, },
doClose() { doClose() {
this.loading = false; this.loading = false;
this.$refs.dataform.resetForm(); this.$refs.dataform.resetForm();
this.formModel = {
gernarateType:'01',
serviceNumber:'', //
beginTime: '', //
overTime: '', //
runLevel:'', //
departureInterval:180, //
inboundRouting:'', // code
outboundRouting:'', // code
runningRouting1: '', // code1
runningRouting2: '', // code2
runningRouting:''
};
this.dialogShow = false; this.dialogShow = false;
}, },
covertRouting(routingType) { covertRouting(routingType) {
return this.routingList.filter(route=>{ return route.routingType == routingType; }); return this.routingList.filter(route=>{ return route.routingType == routingType; });
}, },
covertRoutingCircle() {
const list = Object.values(this.runningRoutingMap);
return list.filter(route=>{ return route.runningRouting1 && route.runningRouting2; });
},
handleCommit() { handleCommit() {
this.$refs.dataform.validateForm(() => { this.$refs.dataform.validateForm(() => {
if (this.formModel.overTime <= this.formModel.beginTime) { if (this.formModel.overTime <= this.formModel.beginTime) {
@ -212,6 +241,7 @@ export default {
delete formModel.serviceNumber; delete formModel.serviceNumber;
} }
delete formModel.gernarateType; delete formModel.gernarateType;
this.loading = true; this.loading = true;
generatePlanTrain(this.$route.query.planId || this.loadRunPlanId, formModel).then(res => { generatePlanTrain(this.$route.query.planId || this.loadRunPlanId, formModel).then(res => {
this.loading = false; this.loading = false;

View File

@ -10,7 +10,7 @@
:modal="false" :modal="false"
:close-on-click-modal="false" :close-on-click-modal="false"
> >
<data-form ref="dataform" :form="form" :form-model="formModel" :rules="rules" /> <data-form ref="dataform" v-loading="dataLoading" :form="form" :form-model="formModel" :rules="rules" />
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
<el-button size="medium" @click="doClose">{{ $t('global.cancel') }}</el-button> <el-button size="medium" @click="doClose">{{ $t('global.cancel') }}</el-button>
<el-button type="primary" size="medium" :loading="loading" @click="handleCommit">{{ $t('global.confirm') }}</el-button> <el-button type="primary" size="medium" :loading="loading" @click="handleCommit">{{ $t('global.confirm') }}</el-button>
@ -33,8 +33,10 @@ export default {
return { return {
dialogShow: false, dialogShow: false,
// stationList: [], // stationList: [],
routingList: [], // routingList: [],
loading: false, loading: false,
dataLoading:false,
runningRoutingMap:{},
formModel: { formModel: {
stationRunningTime: 60, // stationRunningTime: 60, //
right: 3, // right: 3, //
@ -44,7 +46,8 @@ export default {
// parkedTime: 30, // // parkedTime: 30, //
// reentryTime: 120, // // reentryTime: 120, //
runningRouting1:'', // code1 runningRouting1:'', // code1
runningRouting2:'' // code2 runningRouting2:'', // code2
runningRouting:''
// startStationCode: '', // startStationCode: '',
// endStationCode: '' // endStationCode: ''
}, },
@ -59,18 +62,22 @@ export default {
departureTimeInterval: [ departureTimeInterval: [
{ required: true, message: '请填写发车间隔', trigger: 'blur' } { required: true, message: '请填写发车间隔', trigger: 'blur' }
], ],
runningRouting: [
{ required: true, message: '请选择环路', trigger: 'blur' },
{ required: true, message: '请选择环路', trigger: 'change' }
]
// parkedTime: [ // parkedTime: [
// { required: true, message: '', trigger: 'blur' } // { required: true, message: '', trigger: 'blur' }
// ], // ],
// reentryTime: [ // reentryTime: [
// { required: true, message: '', trigger: 'blur' } // { required: true, message: '', trigger: 'blur' }
// ], // ],
runningRouting1: [ // runningRouting1: [
{ required: true, validator: this.validateRunningRouting, trigger: 'change' } // { required: true, validator: this.validateRunningRouting, trigger: 'change' }
], // ],
runningRouting2: [ // runningRouting2: [
{ required: true, validator: this.validateRunningRouting, trigger: 'change' } // { required: true, validator: this.validateRunningRouting, trigger: 'change' }
] // ]
// startStationCode: [ // startStationCode: [
// { required: true, message: '', trigger: 'change' } // { required: true, message: '', trigger: 'change' }
// ], // ],
@ -91,15 +98,14 @@ export default {
{ prop: 'beginTime', label: '开始时间', type: 'timePicker', selectableRange:'02:00:00-23:59:59'}, { prop: 'beginTime', label: '开始时间', type: 'timePicker', selectableRange:'02:00:00-23:59:59'},
{ prop: 'overTime', label: '结束时间', type: 'timePicker', selectableRange:'02:00:00-23:59:59'}, { prop: 'overTime', label: '结束时间', type: 'timePicker', selectableRange:'02:00:00-23:59:59'},
{ prop: 'departureTimeInterval', label: '发车间隔', type: 'number', min:0, step:1, precisionFlag:true, precision:0, message:'s'}, { prop: 'departureTimeInterval', label: '发车间隔', type: 'number', min:0, step:1, precisionFlag:true, precision:0, message:'s'},
// { prop: 'parkedTime', label: '', type: 'number', min:0, step:1, precisionFlag:true, precision:0},
// { prop: 'reentryTime', label: '', type: 'number', min:120, step:1, precisionFlag:true, precision:0, message:'s'},
{ prop: 'right', label: '发车类型', type: 'checkBox', children: [ { prop: 'right', label: '发车类型', type: 'checkBox', children: [
{ name: '上行发车', value: 1 }, { name: '上行发车', value: 1 },
{ name: '下次发车', value: 2 }, { name: '下次发车', value: 2 },
{ name: '同时发车', value: 3 } { name: '同时发车', value: 3 }
] }, ] },
{ prop: 'runningRouting1', label: '环路交路1', type: 'select', show:true, options: this.covertRouting('LOOP'), noDataText:'请先设置交路', change:true, onChange:this.changeRoute2 }, { prop: 'runningRouting1', label: '环路交路1', type: 'select', show:false},
{ prop: 'runningRouting2', label: '环路交路2', type: 'select', show:true, options: this.covertRouting('LOOP'), noDataText:'请先设置交路', change:true, onChange:this.changeRoute1} { prop: 'runningRouting2', label: '环路交路2', type: 'select', show:false},
{prop:'runningRouting', label:'环路', type: 'select', options:this.covertRouting(), noDataText:'请先设置交路', change:true, onChange:this.changeRoute}
// { prop: 'startStationCode', label: '', type: 'select', options: this.stationList }, // { prop: 'startStationCode', label: '', type: 'select', options: this.stationList },
// { prop: 'endStationCode', label: '', type: 'select', options: this.stationList } // { prop: 'endStationCode', label: '', type: 'select', options: this.stationList }
] ]
@ -121,21 +127,60 @@ export default {
this.loading = false; this.loading = false;
const mapId = this.$route.query.mapId; const mapId = this.$route.query.mapId;
if (mapId) { if (mapId) {
const runningRoutingMap = {};
this.dataLoading = true;
listUserRoutingData(mapId).then(response => { listUserRoutingData(mapId).then(response => {
this.routingList = response.data.map(elem => { return { value: elem.code, label: elem.name, routingType:elem.routingType }; }); const list = response.data;
list.forEach(elem=>{
if (elem.routingType === 'LOOP') {
// const name = elem.name;
// let temp = '';
if (elem.right) {
// temp = name.split('-')[0];
// const data = ;
const data = runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode];
if (!data) { runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode] = {}; }
runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode].label = elem.name;
runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode].value = elem.startSectionCode + '-' + elem.endSectionCode;
runningRoutingMap[elem.startSectionCode + '-' + elem.endSectionCode].runningRouting1 = elem.code;
} else {
// temp = name.split('-')[1];
// const data = ;
const data = runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode];
if (!data) { runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode] = {}; }
runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode].label = elem.name;
runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode].value = elem.endSectionCode + '-' + elem.startSectionCode;
runningRoutingMap[elem.endSectionCode + '-' + elem.startSectionCode].runningRouting2 = elem.code;
}
}
});
this.runningRoutingMap = runningRoutingMap;
this.dataLoading = false;
}).catch(() => { }).catch(() => {
this.dataLoading = false;
this.$messageBox(`获取交路列表失败`); this.$messageBox(`获取交路列表失败`);
}); });
this.dialogShow = true;
} }
this.dialogShow = true;
}, },
doClose() { doClose() {
this.loading = false; this.loading = false;
this.$refs.dataform.resetForm(); this.$refs.dataform.resetForm();
this.formModel = {
stationRunningTime: 60, //
right: 3, //
beginTime: '',
overTime: '',
departureTimeInterval: 180, //
runningRouting1:'', // code1
runningRouting2:'', // code2
runningRouting:''
};
this.dialogShow = false; this.dialogShow = false;
}, },
handleCommit() { handleCommit() {
this.$refs.dataform.validateForm(() => { this.$refs.dataform.validateForm(() => {
delete this.formModel.runningRouting;
if (this.formModel.right == 1) { if (this.formModel.right == 1) {
this.formModel.right = true; this.formModel.right = true;
} else if (this.formModel.right == 2) { } else if (this.formModel.right == 2) {
@ -160,28 +205,14 @@ export default {
} }
}); });
}, },
validateRunningRouting(rule, value, callback) {
if (value.trim().length == 0) {
return callback(new Error('请选择环路'));
} else {
if (this.formModel.runningRouting1 == this.formModel.runningRouting2) {
return callback(new Error('环路交路1和环路交路2不能相同'));
} else {
return callback();
}
}
},
changeRoute2() {
this.changeRoute('runningRouting2');
},
changeRoute1() {
this.changeRoute('runningRouting1');
},
changeRoute(runningRouting) { changeRoute(runningRouting) {
if (this.formModel[runningRouting]) { this.$refs.dataform.validateField([runningRouting]); } const temp = this.runningRoutingMap[runningRouting];
this.formModel.runningRouting1 = temp.runningRouting1;
this.formModel.runningRouting2 = temp.runningRouting2;
}, },
covertRouting(routingType) { covertRouting() {
return this.routingList.filter(route=>{ return route.routingType == routingType; }); const list = Object.values(this.runningRoutingMap);
return list.filter(route=>{ return route.runningRouting1 && route.runningRouting2; });
} }
} }
}; };

View File

@ -0,0 +1,267 @@
<template>
<el-dialog v-dialogDrag title="导入公共交路" :visible.sync="show" width="80%" :before-do-close="doClose" append-to-body>
<div>
<QueryListPage
ref="queryListPage"
:pager-config="pagerConfig"
:query-form="queryForm"
:query-list="queryList"
/>
</div>
<pre-view-field ref="previewField" />
</el-dialog>
</template>
<script>
import { mapGetters } from 'vuex';
import { listPublicRoutingData, pullPublicRoutingData} from '@/api/jmap/mapdraft';
import PreViewField from './preview';
export default {
name: 'ImportRouteDetail',
components: {
PreViewField
},
data() {
return {
show: false,
pagerConfig: {
pageSize: 'pageSize',
pageIndex: 'pageNum'
},
queryForm: {
labelWidth: '120px',
queryObject: {
startStationCode: {
type: 'select',
label: this.$t('map.startStation'),
config: {
data: []
}
},
endStationCode: {
type: 'select',
label: this.$t('map.endStation'),
config: {
data: []
}
},
startSectionCode: {
type: 'select',
label: '起始区段',
config: {
data: []
}
},
endSectionCode: {
type: 'select',
label: '终到区段',
config: {
data: []
}
}
}
},
queryList: {
query: this.queryFunction,
afterQuery: this.afterQuery,
selectCheckShow: true,
selectCheckClass:'selectCheckClass',
selectCheckSize:'medium',
selectAllClick:this.selectAllClick,
selectCheckText:'导入',
selectCheckLoading:false,
indexShow: true,
columns: [
{
title: '交路名称',
prop: 'name',
width:'260'
},
{
title: this.$t('map.startStation'),
prop: 'startStationCode'
},
{
title: '起始区段',
prop: 'startSectionCode'
},
{
title: this.$t('map.endStation'),
prop: 'endStationCode'
},
{
title: '终到区段',
prop: 'endSectionCode'
},
{
title: this.$t('map.routingDirection'),
prop: 'right',
type: 'tag',
columnValue: (row) => { if (row.right) { return '右行'; } else { return '左行'; } },
tagType: (row) => { if (row.right) { return 'primary'; } else { return 'success'; } }
},
// {
// title: this.$t('map.destination'),
// prop: 'destinationCode'
// },
// {
// title: this.$t('map.remarks'),
// prop: 'remarks'
// },
{
type: 'button',
title: this.$t('map.sectionData'),
buttons: [
{
name: this.$t('map.preview'),
handleClick: this.sectionDetail
}
]
}
// {
// type: 'button',
// title: this.$t('map.operation'),
// width: '300',
// buttons: [
// {
// name: this.$t('map.compile'),
// handleClick: this.editObj
// },
// {
// name: this.$t('map.deleteObj'),
// type: 'danger',
// handleClick: this.deleteObj
// }
// ]
// }
]
}
};
},
computed: {
...mapGetters('map', [
'sectionList',
'stationList'
])
},
mounted() {
// this.acquireMapList();
this.initQueryObject();
},
methods: {
doShow() {
this.show = true;
this.reloadTable();
},
initQueryObject() {
const stationList = [];
if (this.stationList && this.stationList.length) {
this.stationList.forEach(elem => {
stationList.push({ label: this.formatName(elem.code), value: elem.code });
});
this.queryForm.queryObject.startStationCode.config.data = stationList;
this.queryForm.queryObject.endStationCode.config.data = stationList;
}
const sectionList = [];
if (this.sectionList && this.sectionList.length) {
this.sectionList.forEach(elem => {
if (elem.standTrack || elem.reentryTrack || elem.transferTrack) {
sectionList.push({ label: this.formatName(elem.code), value: elem.code });
}
});
this.queryForm.queryObject.startSectionCode.config.data = sectionList;
this.queryForm.queryObject.endSectionCode.config.data = sectionList;
}
},
doClose() {
this.show = false;
},
formatName(code) {
let name = '';
const device = this.$store.getters['map/getDeviceByCode'](code);
if (device) {
name = device.name;
}
return name;
},
queryFunction(params) {
if (this.$route.query.mapId) {
return listPublicRoutingData(this.$route.query.mapId, params);
}
},
afterQuery(data) {
if (data && data.list) {
const that = this;
const list = data.list;
if (list) {
list.map(elem => {
elem.startStationCode = that.formatName(elem.startStationCode);
elem.startSectionCode = that.formatName(elem.startSectionCode);
elem.endStationCode = that.formatName(elem.endStationCode);
elem.endSectionCode = that.formatName(elem.endSectionCode);
});
}
}
return data;
},
sectionDetail(index, row) {
const sectionDict = {};
const stationDict = {};
this.sectionList.forEach(elem => { sectionDict[elem.code] = elem.name; });
this.stationList.forEach(elem => { stationDict[elem.code] = elem.name; });
const fieldList = {
id: row.id,
mapId: this.$route.params.mapId,
title: '区段列表',
name: row.name,
model: {
field: 'parkSectionCodeList',
items: [
{ prop: 'stationCode', label: this.$t('map.stationCodeClomn'), type: 'text' },
{
prop: 'stationCode', label: '车站名称', type: 'select', options: stationDict
},
{ prop: 'sectionCode', label: this.$t('map.blockCodingClomn'), type: 'text' },
{
prop: 'sectionCode', label: this.$t('map.sectionName'), type: 'select', options: sectionDict
}
]
}
};
this.$refs.previewField.doShow(fieldList, row.parkSectionCodeList);
},
reloadTable() {
if (this.queryList && this.queryList.reload) {
this.queryList.reload();
}
},
selectAllClick(selection) {
const routeList = [];
selection.forEach(each=>{
routeList.push(each.id);
});
if (routeList.length > 0) {
this.queryList.selectCheckLoading = true;
pullPublicRoutingData(this.$route.query.mapId, routeList ).then(res=>{
this.queryList.selectCheckLoading = false;
this.$message.success('导入公共交路成功');
this.doClose();
}).catch((error) => {
this.$messageBox('导入公共交路失败' + ':' + error.message);
this.queryList.selectCheckLoading = false;
});
}
}
}
};
</script>
<style lang="scss">
.selectCheckClass{
text-align: center;
padding: 14px 0px 20px 0px;
}
</style>

View File

@ -1,169 +1,173 @@
<template> <template>
<div class="routeConfig"> <div class="routeConfig">
<div> <!-- <div style="position:relative"> -->
<div class="clearfix" style="padding-right: 20px;"> <div class="routeConfigTop">
<el-button type="text" class="mapEdit_box" @click="previewRouteEvent">{{ $t('map.preview') }}</el-button> <el-button type="text" class="mapEdit_box" @click="previewRouteEvent">{{ $t('map.preview') }}</el-button>
<el-button type="text" class="mapEdit_box" @click="createRouteEvent">{{ $t('map.newConstruction') }}</el-button> <el-button type="text" class="mapEdit_box" @click="createRouteEvent">{{ $t('map.newConstruction') }}</el-button>
</div> <el-button type="text" class="mapEdit_box" @click="importRouteEvent">导入公共交路</el-button>
<el-form ref="form" :model="addModel" :rules="rules" label-width="120px" size="mini">
<div class="definition">
<el-form-item :label="$t('map.routingName')" prop="name">
<el-input v-model="addModel.name" />
</el-form-item>
<el-form-item :label="$t('map.startStationCodeColon')" prop="startStationCode">
<el-select v-model="addModel.startStationCode" clearable :filterable="true" disabled @change="changeStartStation">
<el-option
v-for="item in filterStationList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
</el-form-item>
<el-form-item :label="$t('map.startSectionColon')" prop="startSectionCode">
<el-select v-model="addModel.startSectionCode" clearable :filterable="true" :disabled="editShow" @change="changeStartSection">
<el-option
v-for="item in filterStartSectionList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
<el-button
:disabled="editShow"
:type=" field === 'startSectionCode' ? 'danger' : 'primary'"
@click="hover('startSectionCode')"
>{{ $t('map.activate') }}</el-button>
</el-form-item>
<el-form-item :label="$t('map.endStationColon')" prop="endStationCode">
<el-select v-model="addModel.endStationCode" :filterable="true" disabled @change="changeEndStation">
<el-option
v-for="item in filterStationList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
</el-form-item>
<el-form-item :label="$t('map.endSectionColon')" prop="endSectionCode">
<el-select v-model="addModel.endSectionCode" :filterable="true" clearable :disabled="editShow || !isStartSelected" @change="changeEndSection">
<el-option
v-for="item in filterEndSectionList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
<el-button
:disabled="editShow || !isStartSelected"
:type=" field === 'endSectionCode' ? 'danger' : 'primary'"
@click="hover('endSectionCode')"
>{{ $t('map.activate') }}</el-button>
</el-form-item>
<el-form-item :label="$t('map.destinationCode')" prop="destinationCode" :disabled="editShow">
<el-input v-model="addModel.destinationCode" />
</el-form-item>
<el-form-item :label="$t('map.routingDirection')" prop="directionCode">
<el-select v-model="addModel.right" clearable :filterable="true" :placeholder="$t('map.pleaseSelect')">
<el-option
v-for="item in DirectionCodeList"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item :label="$t('map.remarksColon')" prop="remarks">
<el-input v-model="addModel.remarks" type="textarea" :rows="4" :placeholder="$t('map.pleaseSelect')" />
</el-form-item>
<el-form-item :label="$t('map.trafficSegmentData')" prop="parkSectionCodeList">
<el-button type="primary" size="small" :loading="generating" style="margin-bottom:10px" @click.native.prevent="generateParkSection">生成经停区段</el-button>
<el-table
:data="addModel.parkSectionCodeList"
border
style="width:97%"
height="300"
class="el-parkSectionCode-table"
>
<el-table-column prop="sectionCode" :label="$t('map.stationName')">
<template slot-scope="scope">
<span>{{ formatName(scope.row.stationCode) }}</span>
</template>
</el-table-column>
<el-table-column prop="sectionCode" :label="$t('map.sectionName')">
<template slot-scope="scope">
<span>{{ formatName(scope.row.sectionCode) }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('map.operation')" width="50">
<template slot-scope="scope">
<el-button
v-show="scope.$index!=0&&scope.$index!=addModel.parkSectionCodeList.length-1"
type="text"
size="small"
@click.native.prevent="deleteSection(addModel.parkSectionCodeList, scope.$index)"
>
{{ $t('map.remove') }}
</el-button>
</template>
</el-table-column>
</el-table>
<div style="margin-top:10px;">
<span>车站:</span>
<el-select v-model="stationCode" clearable :filterable="true" :placeholder="$t('map.pleaseSelect')">
<el-option
v-for="item in filterStationList"
:key="item.code"
:label="`${item.name}(${item.code})`"
:value="item.code"
/>
</el-select>
<el-button
:disabled="!allowSelect"
:type="field === 'routingStation' ? 'danger' : 'primary'"
@click="hover('routingStation')"
>{{ $t('map.activate') }}</el-button>
</div>
<div style="margin-top:10px;">
<span>区段:</span>
<el-select v-model="sectionCode" clearable :filterable="true" :placeholder="$t('map.pleaseSelect')">
<el-option
v-for="item in filterStandSection"
:key="item.code"
:label="`${item.name}(${item.code})`"
:value="item.code"
/>
</el-select>
<el-button
:type=" field === 'routingSection' ? 'danger' : 'primary'"
:disabled="!allowSelect"
@click="hover('routingSection')"
>{{ $t('map.activate') }}</el-button>
<el-button
type="primary"
:disabled="!allowSelect"
@click="pushSection({stationCode: stationCode, sectionCode: sectionCode},'center')"
>
{{ $t('map.add') }}
</el-button>
</div>
</el-form-item>
<el-form-item>
<el-button-group style="padding-bottom:10px">
<el-button v-if="isSave" type="primary" size="small" :loading="loading" @click="save">{{ $t('map.save') }}
</el-button>
<el-button v-else type="warning" size="small" :loading="loading" @click="update">{{ $t('map.updata') }}
</el-button>
</el-button-group>
</el-form-item>
</div>
</el-form>
</div> </div>
<el-form ref="form" :model="addModel" :rules="rules" label-width="120px" size="mini" style="height:100%">
<div class="definition">
<el-form-item :label="$t('map.routingName')" prop="name">
<el-input v-model="addModel.name" />
</el-form-item>
<el-form-item :label="$t('map.startStationCodeColon')" prop="startStationCode">
<el-select v-model="addModel.startStationCode" clearable :filterable="true" disabled @change="changeStartStation">
<el-option
v-for="item in filterStationList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
</el-form-item>
<el-form-item :label="$t('map.startSectionColon')" prop="startSectionCode">
<el-select v-model="addModel.startSectionCode" clearable :filterable="true" :disabled="editShow" @change="changeStartSection">
<el-option
v-for="item in filterStartSectionList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
<el-button
:disabled="editShow"
:type=" field === 'startSectionCode' ? 'danger' : 'primary'"
@click="hover('startSectionCode')"
>{{ $t('map.activate') }}</el-button>
</el-form-item>
<el-form-item :label="$t('map.endStationColon')" prop="endStationCode">
<el-select v-model="addModel.endStationCode" :filterable="true" disabled @change="changeEndStation">
<el-option
v-for="item in filterStationList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
</el-form-item>
<el-form-item :label="$t('map.endSectionColon')" prop="endSectionCode">
<el-select v-model="addModel.endSectionCode" :filterable="true" clearable :disabled="editShow || !isStartSelected" @change="changeEndSection">
<el-option
v-for="item in filterEndSectionList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
<el-button
:disabled="editShow || !isStartSelected"
:type=" field === 'endSectionCode' ? 'danger' : 'primary'"
@click="hover('endSectionCode')"
>{{ $t('map.activate') }}</el-button>
</el-form-item>
<el-form-item :label="$t('map.destinationCode')" prop="destinationCode" :disabled="editShow">
<el-input v-model="addModel.destinationCode" />
</el-form-item>
<el-form-item :label="$t('map.routingDirection')" prop="directionCode">
<el-select v-model="addModel.right" clearable :filterable="true" :placeholder="$t('map.pleaseSelect')">
<el-option
v-for="item in DirectionCodeList"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item :label="$t('map.remarksColon')" prop="remarks">
<el-input v-model="addModel.remarks" type="textarea" :rows="4" :placeholder="$t('map.pleaseSelect')" />
</el-form-item>
<el-form-item :label="$t('map.trafficSegmentData')" prop="parkSectionCodeList">
<el-button type="primary" size="small" :loading="generating" style="margin-bottom:10px" @click.native.prevent="generateParkSection">生成经停区段</el-button>
<el-table
:data="addModel.parkSectionCodeList"
border
style="width:97%"
height="300"
class="el-parkSectionCode-table"
>
<el-table-column prop="sectionCode" :label="$t('map.stationName')">
<template slot-scope="scope">
<span>{{ formatName(scope.row.stationCode) }}</span>
</template>
</el-table-column>
<el-table-column prop="sectionCode" :label="$t('map.sectionName')">
<template slot-scope="scope">
<span>{{ formatName(scope.row.sectionCode) }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('map.operation')" width="50">
<template slot-scope="scope">
<el-button
v-show="scope.$index!=0&&scope.$index!=addModel.parkSectionCodeList.length-1"
type="text"
size="small"
@click.native.prevent="deleteSection(addModel.parkSectionCodeList, scope.$index)"
>
{{ $t('map.remove') }}
</el-button>
</template>
</el-table-column>
</el-table>
<div style="margin-top:10px;">
<span>车站:</span>
<el-select v-model="stationCode" clearable :filterable="true" :placeholder="$t('map.pleaseSelect')">
<el-option
v-for="item in filterStationList"
:key="item.code"
:label="`${item.name}(${item.code})`"
:value="item.code"
/>
</el-select>
<el-button
:disabled="!allowSelect"
:type="field === 'routingStation' ? 'danger' : 'primary'"
@click="hover('routingStation')"
>{{ $t('map.activate') }}</el-button>
</div>
<div style="margin-top:10px;">
<span>区段:</span>
<el-select v-model="sectionCode" clearable :filterable="true" :placeholder="$t('map.pleaseSelect')">
<el-option
v-for="item in filterStandSection"
:key="item.code"
:label="`${item.name}(${item.code})`"
:value="item.code"
/>
</el-select>
<el-button
:type=" field === 'routingSection' ? 'danger' : 'primary'"
:disabled="!allowSelect"
@click="hover('routingSection')"
>{{ $t('map.activate') }}</el-button>
<el-button
type="primary"
:disabled="!allowSelect"
@click="pushSection({stationCode: stationCode, sectionCode: sectionCode},'center')"
>
{{ $t('map.add') }}
</el-button>
</div>
</el-form-item>
</div>
<el-form-item class="buttonGroup">
<el-button-group>
<el-button v-if="isSave" type="primary" size="small" :loading="loading" @click="save">{{ $t('map.save') }}
</el-button>
<el-button v-else type="warning" size="small" :loading="loading" @click="update">{{ $t('map.updata') }}
</el-button>
</el-button-group>
</el-form-item>
</el-form>
<!-- </div> -->
<route-operate ref="routeOperate" @routingSelected="routingSelected" /> <route-operate ref="routeOperate" @routingSelected="routingSelected" />
<import-route-operate ref="importRouteOperate" />
</div> </div>
</template> </template>
<script> <script>
import RouteOperate from './routeOperate'; import RouteOperate from './routeOperate';
import ImportRouteOperate from './importRouteOperate';
import { setUID } from '@/jmapNew/utils/Uid'; import { setUID } from '@/jmapNew/utils/Uid';
import { addRoutingData, updateRoutingData, gernateRoutingSectionInRunplan } from '@/api/jmap/mapdraft'; import { addRoutingData, updateRoutingData, gernateRoutingSectionInRunplan } from '@/api/jmap/mapdraft';
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
@ -172,7 +176,8 @@ import Sortable from 'sortablejs';
export default { export default {
name:'RouteConfig', name:'RouteConfig',
components: { components: {
RouteOperate RouteOperate,
ImportRouteOperate
}, },
data() { data() {
return { return {
@ -308,6 +313,9 @@ export default {
previewRouteEvent() { previewRouteEvent() {
this.$refs.routeOperate.doShow(); this.$refs.routeOperate.doShow();
}, },
importRouteEvent() {
this.$refs.importRouteOperate.doShow();
},
createRouteEvent() { createRouteEvent() {
this.clear(); this.clear();
}, },
@ -697,4 +705,57 @@ export default {
padding: 3px 0; padding: 3px 0;
margin-right: 5px; margin-right: 5px;
} }
.routeConfig{
height:100%;
position: relative;
}
.routeConfigTop{
padding: 7px 20px 7px 0px;
position: absolute;
background: #fff;
width: 100%;
z-index: 2;
height: 35px;
font-size: 16px;
display: inline-block;
-webkit-box-shadow: 0px 1px 3px #ccc;
box-shadow: 0px 1px 3px #ccc;
right: 0;
top: 0;
}
.routeConfigTop button{
display:inline-block;
}
.definition{
padding: 45px 30px 45px 0px;
height: 100%;
overflow: auto;
&::-webkit-scrollbar {
width: 4px;
}
&::-webkit-scrollbar-thumb {
border-radius: 10px;
background: #c3c3c3;
}
&::-webkit-scrollbar-track {
border-radius: 0;
background: #f0f0f0;
}
}
.buttonGroup{
position: absolute;
width: 100%;
height: 40px;
bottom: 0;
background: #fff;
margin-bottom: 0px;
box-shadow: 0px -2px 5px #ccc;
z-index: 2;
text-align: right;
padding-right: 26px;
padding-top: 4px;
}
</style> </style>

View File

@ -14,7 +14,6 @@
<script> <script>
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
import { listMap } from '@/api/jmap/mapdraft';
import { listRoutingData, deleteRoutingData, getRoutingData } from '@/api/jmap/mapdraft'; import { listRoutingData, deleteRoutingData, getRoutingData } from '@/api/jmap/mapdraft';
import PreViewField from './preview'; import PreViewField from './preview';
@ -26,7 +25,6 @@ export default {
data() { data() {
return { return {
show: false, show: false,
mapList: [],
pagerConfig: { pagerConfig: {
pageSize: 'pageSize', pageSize: 'pageSize',
pageIndex: 'pageNum' pageIndex: 'pageNum'
@ -71,8 +69,9 @@ export default {
indexShow: true, indexShow: true,
columns: [ columns: [
{ {
title: this.$t('map.routingCode'), title: '交路名称',
prop: 'code' prop: 'name',
width:'260'
}, },
{ {
title: this.$t('map.startStation'), title: this.$t('map.startStation'),
@ -127,8 +126,8 @@ export default {
}, },
{ {
name: this.$t('map.deleteObj'), name: this.$t('map.deleteObj'),
handleClick: this.deleteObj, type: 'danger',
type: 'danger' handleClick: this.deleteObj
} }
// { // {
// name: '', // name: '',
@ -148,7 +147,6 @@ export default {
]) ])
}, },
mounted() { mounted() {
this.acquireMapList();
this.initQueryObject(); this.initQueryObject();
}, },
methods: { methods: {
@ -193,19 +191,12 @@ export default {
return listRoutingData(this.$route.query.mapId, params); return listRoutingData(this.$route.query.mapId, params);
} }
}, },
acquireMapList() {
//
listMap({drawWay: true}).then(response => {
this.mapList = response.data;
});
},
afterQuery(data) { afterQuery(data) {
if (data && data.list) { if (data && data.list) {
const that = this; const that = this;
const list = data.list; const list = data.list;
if (list) { if (list) {
list.map(elem => { list.map(elem => {
that.$convertSpecifiedField(elem, that.mapList, 'id', 'name', ['mapId']);
elem.startStationCode = that.formatName(elem.startStationCode); elem.startStationCode = that.formatName(elem.startStationCode);
elem.startSectionCode = that.formatName(elem.startSectionCode); elem.startSectionCode = that.formatName(elem.startSectionCode);
elem.endStationCode = that.formatName(elem.endStationCode); elem.endStationCode = that.formatName(elem.endStationCode);

View File

@ -206,9 +206,19 @@ export default {
}; };
</script> </script>
<style> <style lang="scss">
.plan-tool { .plan-tool {
position: absolute; position: absolute;
&::before {
// content: '';
// position: absolute;
// width: 100%;
// height: 100%;
// left: 0;
// top: 0;
// background-image: url(https://www.cnblogs.com/skins/imetro/images/background.jpg);
// filter: blur(30px);
}
} }
.plan-tool .pop-menu { .plan-tool .pop-menu {

View File

@ -5,9 +5,11 @@
:actived="active==i" :actived="active==i"
@click="onClick(el, i)" @click="onClick(el, i)"
@mouseenter="onMouseEnter(el, i)" @mouseenter="onMouseEnter(el, i)"
@mouseleave="onMouseLeave(el, i)" :color="color" > @mouseleave="onMouseLeave(el, i)"
:background="background"
:color="color" >
<template v-if="el.children&&el.children.length" slot="append"> <template v-if="el.children&&el.children.length" slot="append">
<menu-list style="transform: translateY(-3px);" v-show="index==i" :menus="el.children" :background="background" :color="color" :elMenuClass="elMenuClass" <menu-list style="transform: translate(-9px, 1px);" v-show="index==i" :menus="el.children" :background="background" :color="color" :elMenuClass="elMenuClass"
@close="onClose(el, i)" /> @close="onClose(el, i)" />
</template> </template>
</menu-item> </menu-item>
@ -80,6 +82,7 @@ export default {
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
align-items: center; align-items: center;
box-sizing: content-box;
box-shadow: 0 2px 12px 0 rgba(0,0,0,.1); box-shadow: 0 2px 12px 0 rgba(0,0,0,.1);
&-menu { &-menu {
position: relative; position: relative;

View File

@ -1,5 +1,6 @@
<template> <template>
<div class="menu" <div class="menu"
:style="{background: background}"
@click.stop="onClick" @click.stop="onClick"
@mouseenter.stop="onMouseEnter" @mouseenter.stop="onMouseEnter"
@mouseleave.stop="onMouseLeave"> @mouseleave.stop="onMouseLeave">
@ -22,6 +23,10 @@ export default {
type: String, type: String,
required: true required: true
}, },
background: {
type: String,
required: true
},
actived: { actived: {
type: Boolean, type: Boolean,
default: false default: false
@ -48,17 +53,11 @@ export default {
.menu { .menu {
list-style: none; list-style: none;
position: relative; position: relative;
padding: 0 17px; padding: 0 8px;
margin: 0; margin: 0;
&::after { line-height: 30px;
content:""; box-sizing: border-box;
position: absolute; border: 1px solid transparent;
left: 0;
bottom: 0;
width: 100%;
height:100%;
border: 1px solid transparent;
}
cursor: pointer; cursor: pointer;
&-label { &-label {
@ -66,16 +65,13 @@ export default {
} }
&:hover { &:hover {
background: #cfe1f6; background: aliceblue !important;
&::after { border: 1px solid #0295f6;
border: 1px solid #49A4FE;
}
} }
&:active { &:active {
background: #cfe1f6; background: aliceblue !important;
&::after { border: 1px solid #0295f6;
border: 1px solid #49A4FE;
}
} }
.__active { .__active {
@ -90,4 +86,15 @@ export default {
} }
} }
} }
.frosted-glass{
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: aliceblue;
filter:drop-shadow(2px 4px 6px black);
filter: progid:DXImageTransform.Microsoft.Blur(PixelRadius=4, MakeShadow=false);
}
</style> </style>

View File

@ -2,11 +2,13 @@
<ul class="menu-ul" :style="{background: background}"> <ul class="menu-ul" :style="{background: background}">
<li class="menu-li" :class="elMenuClass" v-for="(el,i) in menus" :key="i"> <li class="menu-li" :class="elMenuClass" v-for="(el,i) in menus" :key="i">
<div v-if="el.isSeparation" class="menu-separation" /> <div v-if="el.isSeparation" class="menu-separation" />
<menu-item v-else :menu="el" :color="color" <menu-item v-else :menu="el"
:actived="false" :actived="false"
@click="onClick(el, i)" @click="onClick(el, i)"
@mouseenter="onMouseEnter(el, i)" @mouseenter="onMouseEnter(el, i)"
@mouseleave="onMouseLeave(el, i)"> @mouseleave="onMouseLeave(el, i)"
:background="background"
:color="color">
<template v-if="el.children&&el.children.length" slot="append"> <template v-if="el.children&&el.children.length" slot="append">
<span class="menu-arrow" /> <span class="menu-arrow" />
<menu-list class="menu-list" v-show="index==i" :background="background" :color="color" :menus="el.children" <menu-list class="menu-list" v-show="index==i" :background="background" :color="color" :menus="el.children"
@ -101,21 +103,15 @@ export default {
} }
&-list { &-list {
transform:translate(100%, -1px); transform: translate(calc(100% + 1px), -2px);
right: 0px; right: 0px;
top: 0; top: 0;
} }
&-separation { &-separation {
&::after { border-bottom: 1px solid #d5d5d5;
content:""; bottom: -1px;
position: absolute; width: 100%;
left: -50%;
bottom: -1px;
width: 200%;
border: 1px solid #d1d1d1;
transform: scale(0.5);
}
} }
} }
</style> </style>

View File

@ -1,12 +1,14 @@
<template> <template>
<div class="plan"> <div class="plan">
<div class="plan-glass"/>
<div class="plan__header"> <div class="plan__header">
<span class="title">运行图编辑工具</span> <span class="title">运行图编辑工具</span>
<span class="close" @click="doClose"/> <span class="close" @click="doClose"/>
</div> </div>
<div class="plan__layer" style="width: 100%; height: 100%;"> <div class="plan__layer" style="width: 100%; height: 100%;">
<nav-bar class="noselect" ref="bar"/> <div class="layer-glass" />
<nav-tool class="noselect" ref="tool"/> <nav-bar ref="bar"/>
<nav-tool ref="tool"/>
<nav-schedule ref="schedule" /> <nav-schedule ref="schedule" />
<nav-state ref="state" /> <nav-state ref="state" />
</div> </div>
@ -56,7 +58,6 @@ export default {
.plan { .plan {
padding: 40px 5px 5px 5px; padding: 40px 5px 5px 5px;
height: 100%; height: 100%;
background: #06c;
&__header { &__header {
position: absolute; position: absolute;
top: 0; top: 0;
@ -77,8 +78,8 @@ export default {
.close { .close {
position: absolute; position: absolute;
top: 10px; top: 11px;
right: 10px; right: 11px;
background: #ff4b4b; background: #ff4b4b;
color: #fff; color: #fff;
@ -98,6 +99,33 @@ export default {
} }
&__layer { &__layer {
position: relative; position: relative;
border: 2px solid #c0c4cc;
display: flex;
flex-direction: column;
justify-content: center;
align-items: flex-start;
} }
} }
.plan-glass{
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: linear-gradient(45deg, #0060cf, #000);
filter: blur(10px);
pointer-events: none;
}
.layer-glass {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: #fff;
filter: drop-shadow(2px 4px 6px black);
pointer-events: none;
}
</style> </style>

View File

@ -1,7 +1,7 @@
<template> <template>
<div class="nav"> <div class="bar">
<menu-nav :menus="menuList" background="#fff" color="#333" /> <menu-nav :menus="menuList" background="#fff" color="#303133" />
</div> </div>
</template> </template>
<script> <script>
import MenuNav from './component/menuNav/index'; import MenuNav from './component/menuNav/index';
@ -162,12 +162,9 @@ export default {
}; };
</script> </script>
<style scoped rel="stylesheet/scss" lang="scss"> <style scoped lang="scss">
@import "src/styles/mixin.scss"; .bar {
.nav { position: relative;
width: 100%; width: 100%
line-height: 40px;
position: absolute;
z-index: 100;
} }
</style> </style>

View File

@ -1,6 +1,10 @@
<template> <template>
<div class="schedule"> <div class="schedule">
context <div class="container">
<div class="context">
context
</div>
</div>
</div> </div>
</template> </template>
<script> <script>
@ -21,10 +25,23 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.schedule { .schedule {
flex: 1;
width: 100%; width: 100%;
height: 100%; position: relative;
padding-top: 70px; background: #ecf5ff;
padding-bottom: 30px; &::before {
background: #efefef; content: '';
position: absolute;
width: 100%;
height: 100%;
left: 0;
top: 0;
background-image: url(https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fwww.1fr.com.cn%2Fimg.php%3Fimgcdn.gz01.bdysite.com%2Fupfile%2Ft0101c94484b6ea8522.jpg&refer=http%3A%2F%2Fwww.1fr.com.cn&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1618136165&t=66e6bdb);
filter: blur(18px);
}
.container {
margin: 17px;
position: relative;
}
} }
</style> </style>

View File

@ -1,6 +1,9 @@
<template> <template>
<div class="state"> <div class="state">
<div class="state-glass"/>
<div class="container">
<span>就绪</span>
</div>
</div> </div>
</template> </template>
@ -21,14 +24,30 @@ export default {
@import "src/styles/mixin.scss"; @import "src/styles/mixin.scss";
.state { .state {
z-index: 10; position: relative;
position: absolute;
bottom: 0px;
background: #F6F6F6;
width: 100%; width: 100%;
height: 30px; height: 32px;
border: 1px solid #ffffee; border: 1px solid #ffffee;
box-shadow: 0 -2px 12px 0 rgba(0,0,0,.1); box-shadow: 0 -2px 12px 0 rgba(0,0,0,.1);
display: flex;
justify-content: flex-start;
align-items: center;
&-glass {
position: absolute;
top: 0px;
left: 0px;
width: 100%;
height: 100%;
background: #f4f4f5;
// filter: blur(3px);
}
.container {
position: absolute;
padding: 0 17px;
font-size: 16px;
color: #000;
}
} }
</style> </style>

View File

@ -1,5 +1,4 @@
<template> <template>
<!-- <div class="el-dialog__wrapper" v-dialogDrag> -->
<div class="el-dialog__wrapper"> <div class="el-dialog__wrapper">
<div class="bar el-dialog"> <div class="bar el-dialog">
<div class="tool el-dialog__header" style="padding: 0"> <div class="tool el-dialog__header" style="padding: 0">
@ -8,19 +7,20 @@
:class="{'__active': active == i, '__disable': el.disabled}" :class="{'__active': active == i, '__disable': el.disabled}"
@click="doClick(el, i)" > @click="doClick(el, i)" >
<img :src="el.src" /> <img :src="el.src" />
<span>{{ el.title }}</span> <!-- <span>{{ el.title }}</span> -->
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import logo_ from '@/assets/logo_.png'; import logo_ from '@/assets/voiceOpen.png';
export default { export default {
name: 'PlanNavTool', name: 'PlanNavTool',
data() { data() {
return { return {
isDrag: false,
active: -1, active: -1,
tools: [ tools: [
{ {
@ -52,8 +52,6 @@ export default {
] ]
}; };
}, },
mounted() {
},
methods: { methods: {
doClick(el, i) { doClick(el, i) {
if (!el.disabled) { if (!el.disabled) {
@ -66,26 +64,33 @@ export default {
<style scoped rel="stylesheet/scss" lang="scss"> <style scoped rel="stylesheet/scss" lang="scss">
@import "src/styles/mixin.scss"; @import "src/styles/mixin.scss";
$top: 40px; $size: 26px;
$height: 30px;
$size: 22px;
$background: #ffffee; $background: #ffffee;
$color: #0000; $color: #0000;
.el-dialog__wrapper { .el-dialog__wrapper {
position: relative;
width: 100%;
}
.frosted-glass{
position: absolute; position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: $background;
filter:drop-shadow(2px 4px 6px black);
filter: progid:DXImageTransform.Microsoft.Blur(PixelRadius=4, MakeShadow=false);
pointer-events: none;
} }
.bar { .bar {
z-index: 60; z-index: 60;
position: absolute; width: 100%;
top: $top;
height: $height;
line-height: $height;
background: $background;
color: $color; color: $color;
width: 100%;
box-shadow: 0 2px 12px 0 rgba(0,0,0,.1); box-shadow: 0 2px 12px 0 rgba(0,0,0,.1);
position: relative;
&::after { &::after {
position: absolute; position: absolute;
content: ""; content: "";
@ -102,14 +107,13 @@ export default {
align-items: center; align-items: center;
justify-content: flex-start; justify-content: flex-start;
list-style: none; list-style: none;
cursor: move;
&-move { &-move {
position: relative; position: relative;
margin: 0 12px; margin: 0 12px;
position: relative; position: relative;
height: $height - 2px; height: 32px;
border: 1px dashed #ccc; border: 1px dashed #b2b2b2;
} }
@ -119,7 +123,6 @@ export default {
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
padding: 0 5px;
border-right: 1px solid #d1d1d1; border-right: 1px solid #d1d1d1;
&:nth-child(2) { &:nth-child(2) {
border-left: 1px solid #d1d1d1; border-left: 1px solid #d1d1d1;
@ -140,15 +143,20 @@ export default {
.__disable { .__disable {
background: #f4f4f5 !important; background: #f4f4f5 !important;
border-left: 1px inset #d1d1d1!important;
border-right: 1px inset #d1d1d1!important;
cursor: not-allowed !important; cursor: not-allowed !important;
filter: opacity(0.5) !important;
span { span {
color: #bcbec2 !important; color: #bcbec2 !important;
} }
} }
.__active { .__active {
background: #cfe1f6 !important; background: #cdcdcd !important;
border-left: 1px inset #d1d1d1!important;
border-right: 1px outset #d1d1d1!important; border-right: 1px outset #d1d1d1!important;
filter: contrast(0.5) !important;
} }
} }
} }

View File

@ -37,9 +37,11 @@
<div class="menu-li-block" :disabled="child.disabled"> <div class="menu-li-block" :disabled="child.disabled">
<span class="menu-li-text"> <span class="menu-li-text">
<span class="label">{{ child.title }}</span> <span class="label">{{ child.title }}</span>
<i v-if="j!==classB" class="el-icon-arrow-right" style="float: right;height: 30px;line-height: 30px;" />
<i v-if="j===classB" class="el-icon-arrow-left" style="float: right;height: 30px;line-height: 30px;" />
</span> </span>
</div> </div>
<ul class="menu-ul" :class="{'active' :j==classB}"> <ul class="menu-ul" :class="{'children-active' :j==classB}">
<template v-for="(grandchild,k) in child.children"> <template v-for="(grandchild,k) in child.children">
<li v-if="grandchild.type === 'separator'" :key="k" class="menu-separator"> <li v-if="grandchild.type === 'separator'" :key="k" class="menu-separator">
<span class="separator">&ensp;</span> <span class="separator">&ensp;</span>
@ -110,6 +112,20 @@
<span class="nav-li-text">{{ dispaly?'关闭':$t('global.back') }}</span> <span class="nav-li-text">{{ dispaly?'关闭':$t('global.back') }}</span>
</div> </div>
</div> </div>
<el-dialog
title="运行图发布"
:visible.sync="publishVisible"
width="30%"
center
:modal="false"
:before-close="handleClose"
>
<el-input v-model="publishName"><template slot="prepend">运行图名称:</template></el-input>
<span slot="footer" class="dialog-footer">
<el-button @click="publishVisible = false"> </el-button>
<el-button type="primary" @click="confirmPublish"> </el-button>
</span>
</el-dialog>
<route-map ref="routeMap" /> <route-map ref="routeMap" />
<runplan-config ref="runplanConfig" /> <runplan-config ref="runplanConfig" />
</div> </div>
@ -118,11 +134,12 @@
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
import routeMap from '../components/routingoperate/routeMap'; import routeMap from '../components/routingoperate/routeMap';
import RunplanConfig from '../components/routingoperate/runplanConfig'; import RunplanConfig from '../components/routingoperate/runplanConfig';
import { planEffectiveCheck, runPlanNotify, clearPlaningData } from '@/api/runplan'; import { planEffectiveCheck, clearPlaningData } from '@/api/runplan';
import { launchFullscreen } from '@/utils/screen'; // import { launchFullscreen } from '@/utils/screen';
import { UrlConfig } from '@/scripts/ConstDic'; // import { UrlConfig } from '@/scripts/ConstDic';
import { EventBus } from '@/scripts/event-bus'; import { EventBus } from '@/scripts/event-bus';
import { publishRunPlan, deleteRunPlan } from '@/api/designPlatform'; import { publishRunPlanAllUser } from '@/api/designPlatform';
import { deleteRunPlan } from '@/api/runplan';
export default { export default {
name: 'PlanMenuBar', name: 'PlanMenuBar',
@ -134,11 +151,23 @@ export default {
return { }; return { };
} }
}, },
runPlanList: {
type: Array,
default: function() {
return [];
}
},
loadRunPlanId: { loadRunPlanId: {
type: String, type: String,
default: function() { default: function() {
return ''; return '';
} }
},
loadRunPlanName: {
type: String,
default: function() {
return '';
}
} }
}, },
data() { data() {
@ -150,13 +179,31 @@ export default {
tempClassB: -1, tempClassB: -1,
menus: [], menus: [],
loading: null, loading: null,
publishName: '',
publishVisible: false,
menuBase: [ menuBase: [
{ {
title: this.$t('planMonitor.file'), title: this.$t('planMonitor.file'),
children: [ children: [
{
title: '创建',
click: this.newRunPlan
},
{
title: '打开',
children: []
},
{
title: '删除',
click: this.deleteRunPlanOperate
},
{ {
title: '重命名', title: '重命名',
click: this.modifyRunPlanName click: this.modifyRunPlanName
},
{
title: '发布',
click: this.publishRunPlan
} }
// { // {
// title: '', // title: '',
@ -245,11 +292,11 @@ export default {
{ {
title: this.$t('planMonitor.validityCheck'), title: this.$t('planMonitor.validityCheck'),
click: this.handlePlanEffectiveCheck click: this.handlePlanEffectiveCheck
},
{
title: this.$t('planMonitor.testRunningDiagram'),
click: this.handleTestRunPlan
} }
// {
// title: this.$t('planMonitor.testRunningDiagram'),
// click: this.handleTestRunPlan
// }
] ]
} }
// { // {
@ -354,6 +401,19 @@ export default {
return menus; return menus;
}, },
initMenu() { initMenu() {
const menuLoading = [];
this.runPlanList.forEach(item => {
menuLoading.push({title: item.name, planId:item.id, planName: item.name, click: this.loadingRunPlan});
});
this.menuBase.forEach(item => {
if (item.title === this.$t('planMonitor.file')) {
item.children.forEach(elem => {
if (elem.title === '打开') {
elem.children = menuLoading;
}
});
}
});
this.menus = this.menuConvert(this.menuBase); this.menus = this.menuConvert(this.menuBase);
this.clickEvent(); this.clickEvent();
this.closeMenu(); this.closeMenu();
@ -434,41 +494,64 @@ export default {
}, },
// //
populatingGenericData() { populatingGenericData() {
this.$emit('dispatchDialog', { name: 'populatingGenericData', params: {} }); if (this.loadRunPlanId) {
this.$emit('dispatchDialog', { name: 'populatingGenericData', params: {} });
} else {
this.$messageBox(this.$t('tip.selectARunGraphFirst'));
}
},
newRunPlan() {
this.$emit('dispatchDialog', { name: 'createEmptyPlan', params: {}});
}, },
// newRunPlan() {
// this.$emit('dispatchDialog', { name: 'createEmptyPlan', params: {}});
// },
// //
handleAutoGenerate() { handleAutoGenerate() {
this.$emit('dispatchDialog', { name: 'editSmoothRunTime', params: {} }); this.$emit('dispatchDialog', { name: 'editSmoothRunTime', params: {} });
}, },
// //
handleRoutingSettings() { handleRoutingSettings() {
this.$refs.routeMap.doShow('routeMap'); if (this.loadRunPlanId) {
this.$refs.routeMap.doShow('routeMap');
} else {
this.$messageBox(this.$t('tip.selectARunGraphFirst'));
}
}, },
// //
handleRunplanParams() { handleRunplanParams() {
// this.$refs.routeMap.doShow('runplanParams'); // this.$refs.routeMap.doShow('runplanParams');
this.$refs.runplanConfig.doShow(); if (this.loadRunPlanId) {
this.$refs.runplanConfig.doShow();
} else {
this.$messageBox(this.$t('tip.selectARunGraphFirst'));
}
}, },
// //
handleDwellTime() { handleDwellTime() {
this.$emit('dispatchDialog', { name: 'modifyingStationStopTime', params: {} }); if (this.loadRunPlanId) {
this.$emit('dispatchDialog', { name: 'modifyingStationStopTime', params: {} });
} else {
this.$messageBox(this.$t('tip.selectARunGraphFirst'));
}
}, },
// //
handleRoutingLevel() { handleRoutingLevel() {
this.$emit('dispatchDialog', { name: 'modifyingStationIntervalTime', params: {} }); if (this.loadRunPlanId) {
this.$emit('dispatchDialog', { name: 'modifyingStationIntervalTime', params: {} });
} else {
this.$messageBox(this.$t('tip.selectARunGraphFirst'));
}
}, },
// //
handleGernaratePlanningTrain() { handleGernaratePlanningTrain() {
this.$emit('dispatchDialog', { name: 'gernaratePlanTrain', params: {} }); if (this.loadRunPlanId) {
this.$emit('dispatchDialog', { name: 'gernaratePlanTrain', params: {} });
} else {
this.$messageBox(this.$t('tip.selectARunGraphFirst'));
}
}, },
// //
handlePlanEffectiveCheck() { handlePlanEffectiveCheck() {
const planId = this.$route.query.planId; if (this.loadRunPlanId) {
if (planId) { planEffectiveCheck(this.loadRunPlanId).then(resp => {
planEffectiveCheck(planId).then(resp => {
this.$emit('dispatchDialog', { this.$emit('dispatchDialog', {
name: 'systermOut', name: 'systermOut',
params: { params: {
@ -483,24 +566,6 @@ export default {
this.$messageBox(this.$t('tip.selectARunGraphFirst')); this.$messageBox(this.$t('tip.selectARunGraphFirst'));
} }
}, },
//
async handleTestRunPlan() {
const data = { planId: this.$route.query.planId || this.loadRunPlanId };
runPlanNotify(data).then(resp => {
if (resp.data) {
const query = {
prdType: '01', group: resp.data, mapId: this.$route.query.mapId, planId: this.$route.query.planId
};
// this.$router.push({ path: `${UrlConfig.display}/plan`, query: query });
this.$router.push({ path: UrlConfig.design.testRunPlan, query: query });
launchFullscreen();
} else {
this.$messageBox(this.$t('error.checkTheValidityFirst'));
}
}).catch(error => {
this.$messageBox(this.$t('tip.createSimulationFaild') + this.$t('global.colon') + error.message);
});
},
// //
handleParameter() { handleParameter() {
this.$emit('dispatchDialog', { name: 'parameter', params: {} }); this.$emit('dispatchDialog', { name: 'parameter', params: {} });
@ -521,9 +586,9 @@ export default {
cancelButtonText: '取消', cancelButtonText: '取消',
center: true center: true
}).then(() => { }).then(() => {
clearPlaningData(this.$route.query.planId).then(resp => { clearPlaningData(this.loadRunPlanId).then(resp => {
console.log('清除数据成功!'); console.log('清除数据成功!');
this.$emit('refresh'); this.$emit('refresh', this.loadRunPlanId);
}).catch(() => { }).catch(() => {
this.$message.error('清除数据失败!'); this.$message.error('清除数据失败!');
}); });
@ -533,7 +598,7 @@ export default {
}, },
// //
handleDeletePlanningTrain() { handleDeletePlanningTrain() {
const serviceNumber = this.$store.state.runPlan.selected.serviceNumber; const serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
if (serviceNumber) { if (serviceNumber) {
this.$emit('dispatchDialog', { this.$emit('dispatchDialog', {
name: 'offLine', params: { name: 'offLine', params: {
@ -551,7 +616,7 @@ export default {
}, },
// //
handleEditPlanningTrain() { handleEditPlanningTrain() {
const serviceNumber = this.$store.state.runPlan.selected.serviceNumber; const serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
if (serviceNumber) { if (serviceNumber) {
this.$emit('dispatchDialog', { name: 'editPlanningTrain', params: { serviceNumber } }); this.$emit('dispatchDialog', { name: 'editPlanningTrain', params: { serviceNumber } });
} else { } else {
@ -560,7 +625,7 @@ export default {
}, },
// //
handleMovePlanningTrain() { handleMovePlanningTrain() {
const serviceNumber = this.$store.state.runPlan.selected.serviceNumber; const serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
if (serviceNumber) { if (serviceNumber) {
this.$emit('dispatchDialog', { name: 'movePlaningTrain', params: { serviceNumber } }); this.$emit('dispatchDialog', { name: 'movePlaningTrain', params: { serviceNumber } });
} else { } else {
@ -569,7 +634,7 @@ export default {
}, },
// //
handleDuplicateTrain() { handleDuplicateTrain() {
const serviceNumber = this.$store.state.runPlan.selected.serviceNumber; const serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
if (serviceNumber) { if (serviceNumber) {
this.$emit('dispatchDialog', { name: 'duplicateTrain', params: { serviceNumber } }); this.$emit('dispatchDialog', { name: 'duplicateTrain', params: { serviceNumber } });
} else { } else {
@ -578,7 +643,7 @@ export default {
}, },
// //
handleAddTask() { handleAddTask() {
const params = this.$store.state.runPlan.selected; const params = this.$store.state.runPlan.draftSelected;
if (params.serviceNumber && params.tripNumber) { if (params.serviceNumber && params.tripNumber) {
this.$emit('dispatchDialog', { name: 'addTask', params }); this.$emit('dispatchDialog', { name: 'addTask', params });
} else { } else {
@ -587,7 +652,7 @@ export default {
}, },
// //
handleDeleteTask() { handleDeleteTask() {
const params = this.$store.state.runPlan.selected; const params = this.$store.state.runPlan.draftSelected;
if (params.serviceNumber && params.tripNumber) { if (params.serviceNumber && params.tripNumber) {
this.$emit('dispatchDialog', { name: 'deleteTask', params }); this.$emit('dispatchDialog', { name: 'deleteTask', params });
} else { } else {
@ -596,7 +661,7 @@ export default {
}, },
// //
handleModifyingTask() { handleModifyingTask() {
const params = this.$store.state.runPlan.selected; const params = this.$store.state.runPlan.draftSelected;
if (params.serviceNumber && params.tripNumber) { if (params.serviceNumber && params.tripNumber) {
this.$emit('dispatchDialog', { name: 'modifyingTask', params }); this.$emit('dispatchDialog', { name: 'modifyingTask', params });
} else { } else {
@ -608,49 +673,51 @@ export default {
}, },
// //
handleModifyingRouting() { handleModifyingRouting() {
const params = this.$store.state.runPlan.selected; const params = this.$store.state.runPlan.draftSelected;
this.$emit('dispatchDialog', { name: 'modifyingRouting', params }); this.$emit('dispatchDialog', { name: 'modifyingRouting', params });
}, },
// //
handleModifyingStartTime() { handleModifyingStartTime() {
const params = this.$store.state.runPlan.selected; const params = this.$store.state.runPlan.draftSelected;
this.$emit('dispatchDialog', { name: 'modifyingBeginTime', params }); this.$emit('dispatchDialog', { name: 'modifyingBeginTime', params });
}, },
loadingRunPlan(param) { loadingRunPlan(param) {
this.$emit('loadingRunPlan', param); this.$emit('loadingRunPlan', param);
}, },
deleteRunPlanOperate(param) { deleteRunPlanOperate() {
// //
this.$confirm(this.$t('planMonitor.openRunPlan.confirmDeleteRunPlan'), this.$t('tip.hint'), { if (this.loadRunPlanId) {
confirmButtonText: this.$t('tip.confirm'), this.$confirm(this.$t('planMonitor.openRunPlan.confirmDeleteRunPlan'), this.$t('tip.hint'), {
cancelButtonText: this.$t('tip.cancel'), confirmButtonText: this.$t('tip.confirm'),
type: 'warning' cancelButtonText: this.$t('tip.cancel'),
}).then(() => { type: 'warning'
deleteRunPlan(param.planId).then(Response => { }).then(() => {
this.$message.success(this.$t('planMonitor.openRunPlan.deleteSuccess')); deleteRunPlan(this.loadRunPlanId).then(Response => {
this.$emit('checkIsLoadRunPlan', param.planId); this.$message.success(this.$t('planMonitor.openRunPlan.deleteSuccess'));
}).catch(() => { this.$emit('refresh');
this.$messageBox(this.$t('tip.deleteOperationGraphFailed')); }).catch(() => {
}); this.$messageBox(this.$t('tip.deleteOperationGraphFailed'));
}).catch(() => { });
this.$message.error('删除运行图失败!'); }).catch(() => { });
}); } else {
this.$message.error('请先打开运行图!');
}
}, },
publishRunPlan(param) { publishRunPlan() {
this.$confirm(this.$t('tip.publishRunPlanTips'), this.$t('tip.hint'), { if (this.loadRunPlanId) {
confirmButtonText: this.$t('tip.confirm'), this.publishVisible = true;
cancelButtonText: this.$t('tip.cancel'), this.publishName = this.loadRunPlanName;
type: 'warning' } else {
}).then(() => { this.$message.error('请先打开运行图!');
publishRunPlan(param.planId, {runPlanName: param.planName}).then(resp => { }
if (resp.data.length <= 0) { },
this.$message.success(this.$t('tip.publishRunPlanSuccess')); confirmPublish() {
} else { publishRunPlanAllUser(this.loadRunPlanId, this.publishName || this.loadRunPlanName).then(resp => {
this.$messageBox(`${this.$t('tip.publishRunPlanFail')}: ${resp.data[0]}`); this.$message.success(this.$t('tip.publishRunPlanSuccess'));
} this.publishVisible = false;
}).catch(() => { }).catch(() => {
this.$messageBox(this.$t('tip.publishRunPlanFail')); this.$messageBox(this.$t('tip.publishRunPlanFail'));
}); this.publishVisible = false;
}); });
} }
} }