宁波三号线操作
This commit is contained in:
parent
c297594128
commit
9114578e22
@ -132,6 +132,7 @@
|
|||||||
<all-train-detail ref="allTrainDetail" />
|
<all-train-detail ref="allTrainDetail" />
|
||||||
<route-detail ref="routeDetail" />
|
<route-detail ref="routeDetail" />
|
||||||
<init-section-open ref="initSectionOpen" />
|
<init-section-open ref="initSectionOpen" />
|
||||||
|
<init-section-limit-speed ref="initSectionLimitSpeed" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
@ -162,6 +163,7 @@ import SignalCanBlock from './menuDialog/signalCanBlock';
|
|||||||
import RouteCommand from './menuDialog/routeCommand';
|
import RouteCommand from './menuDialog/routeCommand';
|
||||||
import SectionOpen from './menuDialog/sectionOpen';
|
import SectionOpen from './menuDialog/sectionOpen';
|
||||||
import SectionLimitSpeed from './menuDialog/sectionLimitSpeed';
|
import SectionLimitSpeed from './menuDialog/sectionLimitSpeed';
|
||||||
|
import InitSectionLimitSpeed from './menuDialog/initSectionLimitSpeed';
|
||||||
import SectionShow from './menuDialog/sectionShow';
|
import SectionShow from './menuDialog/sectionShow';
|
||||||
import SectionLock from './menuDialog/sectionLock';
|
import SectionLock from './menuDialog/sectionLock';
|
||||||
import SignalModel from './menuDialog/signalModel';
|
import SignalModel from './menuDialog/signalModel';
|
||||||
@ -234,7 +236,8 @@ export default {
|
|||||||
TrainDetail,
|
TrainDetail,
|
||||||
AllTrainDetail,
|
AllTrainDetail,
|
||||||
RouteDetail,
|
RouteDetail,
|
||||||
InitSectionOpen
|
InitSectionOpen,
|
||||||
|
InitSectionLimitSpeed
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
selected: {
|
selected: {
|
||||||
@ -1599,7 +1602,7 @@ export default {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
this.closeMenu(true);
|
this.closeMenu(true);
|
||||||
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
|
this.$store.dispatch('menuOperation/handleBreakFlag', {break: true});
|
||||||
this.$refs.sectionLimitSpeed.doShow();
|
this.$refs.initSectionLimitSpeed.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -1,15 +1,15 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="1000px" :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="1000px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="18">
|
<el-col :span="20">
|
||||||
<el-table ref="singleTable1" :data="sectionList" highlight-current-row height="300px" @current-change="selectLine1">
|
<el-table ref="singleTable1" :data="tempData" highlight-current-row height="300px" @current-change="selectLine1">
|
||||||
<el-table-column prop="name" label="轨道" />
|
<el-table-column prop="name" width="100" label="轨道" />
|
||||||
<el-table-column prop="blockStatus" label="MAU">
|
<el-table-column prop="blockStatus" width="120" label="MAU">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span>{{ getStationName(scope.row) }}</span>
|
<span>{{ getStationName(scope.row) }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="blockProcess" label="临时限速">
|
<el-table-column prop="blockProcess" width="80" label="临时限速">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span>{{ getLimitSpeed(scope.row.code) }}</span>
|
<span>{{ getLimitSpeed(scope.row.code) }}</span>
|
||||||
</template>
|
</template>
|
||||||
@ -19,23 +19,27 @@
|
|||||||
<span>{{ getIsLimit(scope.row.code) }}</span>
|
<span>{{ getIsLimit(scope.row.code) }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="blockProcess" label="设置临时限速进程" width="140" />
|
<el-table-column prop="blockProcess" label="设置临时限速进程" width="140">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getProcess(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="unblockProcess" label="用户里程起点" width="110" />
|
<el-table-column prop="unblockProcess" label="用户里程起点" width="110" />
|
||||||
<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">
|
<el-col :span="4">
|
||||||
<el-table ref="singleTable1" :data="limitList" highlight-current-row height="300px" @current-change="selectLine2">
|
<el-table ref="singleTable2" :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>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row justify="center" class="button-group">
|
<el-row justify="center" class="button-group">
|
||||||
<el-col :span="4" :offset="1">
|
<el-col :span="4" :offset="1">
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定(O)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="!selected || speedLimitValue<=0" @click="commit">确定(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" :loading="loading" @click="commit">应用(A)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading">应用(A)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button :id="domIdCancel" @click="cancel">关闭(C)</el-button>
|
<el-button :id="domIdCancel" @click="cancel">关闭(C)</el-button>
|
||||||
@ -45,6 +49,7 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<notice-info ref="noticeInfo" pop-class="ningbo-01__systerm" />
|
<notice-info ref="noticeInfo" pop-class="ningbo-01__systerm" />
|
||||||
|
<section-limit-speed ref="sectionLimitSpeed" @commandSuccess="commandSuccess" @cancelCommand="cancelCommand" />
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -53,11 +58,13 @@ 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 {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
|
import SectionLimitSpeed from './sectionLimitSpeed';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'SwitchActive',
|
name: 'SwitchActive',
|
||||||
components: {
|
components: {
|
||||||
NoticeInfo
|
NoticeInfo,
|
||||||
|
SectionLimitSpeed
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -88,7 +95,10 @@ export default {
|
|||||||
{ name: '70', value: 70 },
|
{ name: '70', value: 70 },
|
||||||
{ name: '75', value: 75 },
|
{ name: '75', value: 75 },
|
||||||
{ name: '80', value: 80 }
|
{ name: '80', value: 80 }
|
||||||
]
|
],
|
||||||
|
initEle: null,
|
||||||
|
commandEleCode:null,
|
||||||
|
speedLimitValue: 0
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@ -108,7 +118,7 @@ export default {
|
|||||||
return this.dialogShow ? OperationEvent.Signal.arrangementRoute.menu.domId : '';
|
return this.dialogShow ? OperationEvent.Signal.arrangementRoute.menu.domId : '';
|
||||||
},
|
},
|
||||||
title() {
|
title() {
|
||||||
return '确认/取消设置临时限速区域';
|
return '初始化设置临时限速区域';
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
@ -125,8 +135,16 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
doShow(operate, selected) {
|
doShow(operate, selected) {
|
||||||
|
this.tempData = [];
|
||||||
|
this.sectionList.forEach(item => {
|
||||||
|
if (item.type === '01' || item.type === '04') {
|
||||||
|
this.tempData.push(item);
|
||||||
|
}
|
||||||
|
});
|
||||||
this.selected = selected;
|
this.selected = selected;
|
||||||
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
this.initEle = null;
|
||||||
|
this.commandEleCode = null;
|
||||||
|
this.speedLimitValue = 0;
|
||||||
this.dialogShow = true;
|
this.dialogShow = true;
|
||||||
this.$nextTick(function () {
|
this.$nextTick(function () {
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
@ -135,26 +153,104 @@ export default {
|
|||||||
doClose() {
|
doClose() {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
this.dialogShow = false;
|
||||||
|
this.$refs.singleTable1.setCurrentRow();
|
||||||
|
this.$refs.singleTable2.setCurrentRow();
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
},
|
},
|
||||||
selectLine1(val) {
|
selectLine1(val) {
|
||||||
|
if (!val) { return; }
|
||||||
|
this.initEle = null;
|
||||||
|
this.commandEleCode = null;
|
||||||
|
const step = {
|
||||||
|
code: `${val.code}`,
|
||||||
|
operation: OperationEvent.Section.setSpeed.choose.operation,
|
||||||
|
param: {}
|
||||||
|
};
|
||||||
|
this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
|
this.selected = val;
|
||||||
|
const sectionEle = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||||
|
this.speedLimitValue = sectionEle.speedUpLimit;
|
||||||
|
if (this.speedLimitValue > 0) {
|
||||||
|
this.$refs.singleTable2.setCurrentRow(this.limitList[this.speedLimitValue / 5 - 1]);
|
||||||
|
} else {
|
||||||
|
this.$refs.singleTable2.setCurrentRow();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
},
|
},
|
||||||
selectLine2(val) {
|
selectLine2(val) {
|
||||||
|
if (!val) { return; }
|
||||||
|
this.initEle = null;
|
||||||
|
this.commandEleCode = null;
|
||||||
|
const step = {
|
||||||
|
operation: OperationEvent.Section.setSpeed.choose1.operation,
|
||||||
|
param: {speedLimitValue: val.value}
|
||||||
|
};
|
||||||
|
this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
|
this.speedLimitValue = val.value;
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
},
|
},
|
||||||
getStationName(val) {
|
getStationName(val) {
|
||||||
const stationElm = this.$store.getters['map/getDeviceByCode'](val.stationCode);
|
const stationElm = this.$store.getters['map/getDeviceByCode'](val.stationCode);
|
||||||
return stationElm.name;
|
return stationElm.name;
|
||||||
},
|
},
|
||||||
getIsLimit(code) {
|
getIsLimit(code) {
|
||||||
|
if (this.commandEleCode === code) {
|
||||||
|
return this.speedLimitValue > 0 ? '开启' : '关闭';
|
||||||
|
}
|
||||||
const sectionEle = this.$store.getters['map/getDeviceByCode'](code);
|
const sectionEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
return sectionEle.speedUpLimit ? '开启' : '关闭';
|
return sectionEle.speedUpLimit > 0 ? '开启' : '关闭';
|
||||||
},
|
},
|
||||||
getLimitSpeed(code) {
|
getLimitSpeed(code) {
|
||||||
|
if (this.commandEleCode === code) {
|
||||||
|
return this.speedLimitValue > 0 ? this.speedLimitValue : 0;
|
||||||
|
}
|
||||||
const sectionEle = this.$store.getters['map/getDeviceByCode'](code);
|
const sectionEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
return sectionEle.speedUpLimit;
|
return sectionEle.speedUpLimit > 0 ? sectionEle.speedUpLimit : 0;
|
||||||
|
},
|
||||||
|
getProcess(code) {
|
||||||
|
if (this.commandEleCode && this.commandEleCode === code) {
|
||||||
|
return '完成';
|
||||||
|
} else if (this.initEle && this.initEle.code === code) {
|
||||||
|
return '已初始化';
|
||||||
|
} else {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
},
|
},
|
||||||
commit() {
|
commit() {
|
||||||
|
const step = {
|
||||||
|
code: `${this.selected.code}`,
|
||||||
|
operation: OperationEvent.Section.setSpeed.confirm.operation,
|
||||||
|
param: {}
|
||||||
|
};
|
||||||
|
this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
|
this.$refs.sectionLimitSpeed.doShow(step, this.selected, this.speedLimitValue);
|
||||||
|
this.initEle = this.selected;
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
commandSuccess(code, val) {
|
||||||
|
this.commandEleCode = code;
|
||||||
|
if (!val) {
|
||||||
|
this.speedLimitValue = 0;
|
||||||
|
this.$refs.singleTable2.setCurrentRow();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
cancelCommand() {
|
||||||
|
this.initEle = null;
|
||||||
},
|
},
|
||||||
handleClick() {
|
handleClick() {
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="700px" :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="700px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-table ref="singleTable" :data="sectionList" highlight-current-row height="300px" @current-change="selectLine">
|
<el-table ref="singleTable" :data="tempData" highlight-current-row height="300px" @current-change="selectLine">
|
||||||
<el-table-column prop="name" label="轨道" />
|
<el-table-column prop="name" label="轨道" />
|
||||||
<el-table-column prop="blockStatus" label="MAU">
|
<el-table-column prop="blockStatus" label="MAU">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@ -25,7 +25,7 @@
|
|||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="commitDisabled" @click="commit">确定(O)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="commitDisabled" @click="commit">确定(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" :loading="loading" @click="commit">应用(A)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading">应用(A)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button :id="domIdCancel" @click="cancel">关闭(C)</el-button>
|
<el-button :id="domIdCancel" @click="cancel">关闭(C)</el-button>
|
||||||
@ -93,7 +93,8 @@ export default {
|
|||||||
return this.isBlock ? '初始化关闭轨道' : '初始化开放轨道';
|
return this.isBlock ? '初始化关闭轨道' : '初始化开放轨道';
|
||||||
},
|
},
|
||||||
commitDisabled() {
|
commitDisabled() {
|
||||||
return !this.selected || (this.selected.blockade && this.isBlock) || (!this.selected.blockade && !this.isBlock);
|
const sectionEle = this.$store.getters['map/getDeviceByCode']((this.selected || {}).code);
|
||||||
|
return !this.selected || (sectionEle.blockade && this.isBlock) || (!sectionEle.blockade && !this.isBlock);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
@ -110,6 +111,12 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
doShow(operate, selected) {
|
doShow(operate, selected) {
|
||||||
|
this.tempData = [];
|
||||||
|
this.sectionList.forEach(item => {
|
||||||
|
if (item.type === '01' || item.type === '04') {
|
||||||
|
this.tempData.push(item);
|
||||||
|
}
|
||||||
|
});
|
||||||
this.initEle = null;
|
this.initEle = null;
|
||||||
this.commandEleCode = null;
|
this.commandEleCode = null;
|
||||||
this.selected = selected;
|
this.selected = selected;
|
||||||
@ -138,7 +145,7 @@ export default {
|
|||||||
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 });
|
||||||
this.selected = this.$store.getters['map/getDeviceByCode'](val.code);
|
this.selected = val;
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
|
@ -2,27 +2,43 @@
|
|||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="1000px" :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="1000px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="18">
|
<el-col :span="18">
|
||||||
<el-table :data="sectionList" highlight-current-row height="300px" @current-change="selectLine">
|
<el-table ref="singleTable1" :data="tempData" 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" label="MAU" />
|
<el-table-column prop="blockStatus" width="120" label="MAU">
|
||||||
<el-table-column prop="blockProcess" label="临时限速" />
|
<template slot-scope="scope">
|
||||||
<el-table-column prop="unblockProcess" label="PM临时限速" width="110" />
|
<span>{{ getStationName(scope.row) }}</span>
|
||||||
<el-table-column prop="blockProcess" label="设置临时限速进程" width="140" />
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="blockProcess" width="80" label="临时限速">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getLimitSpeed(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="unblockProcess" label="PM临时限速" width="110">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getIsLimit(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="blockProcess" label="设置临时限速进程" width="140">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getProcess(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="unblockProcess" label="用户里程起点" width="110" />
|
<el-table-column prop="unblockProcess" label="用户里程起点" width="110" />
|
||||||
<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">
|
<el-col :span="3">
|
||||||
<el-table :data="limitList" highlight-current-row height="300px" @current-change="selectLine">
|
<el-table ref="singleTable2" :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>
|
||||||
<el-col v-if="selectShow" :span="3">
|
<el-col :span="3">
|
||||||
<fieldset style="padding-left: 10px;">
|
<fieldset style="padding-left: 10px;">
|
||||||
<legend class="card_title">命令</legend>
|
<legend class="card_title">命令</legend>
|
||||||
<el-radio-group v-model="radio">
|
<el-radio-group v-model="command">
|
||||||
<el-radio label="1" style="margin-bottom: 10px;">确认(F)</el-radio>
|
<el-radio :label="true" style="margin-bottom: 10px;">确认(F)</el-radio>
|
||||||
<el-radio label="2">取消(N)</el-radio>
|
<el-radio :label="false">取消(N)</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
</el-col>
|
</el-col>
|
||||||
@ -32,7 +48,7 @@
|
|||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定(O)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定(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" :loading="loading" @click="commit">应用(A)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading">应用(A)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button :id="domIdCancel" @click="cancel">关闭(C)</el-button>
|
<el-button :id="domIdCancel" @click="cancel">关闭(C)</el-button>
|
||||||
@ -50,6 +66,7 @@ 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 {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
|
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'SwitchActive',
|
name: 'SwitchActive',
|
||||||
@ -65,10 +82,11 @@ export default {
|
|||||||
loading: false,
|
loading: false,
|
||||||
selected: null,
|
selected: null,
|
||||||
active: false,
|
active: false,
|
||||||
selectShow: false,
|
|
||||||
activeName: 'first',
|
activeName: 'first',
|
||||||
tempData: [],
|
tempData: [],
|
||||||
radio: '1',
|
command: true,
|
||||||
|
operate: null,
|
||||||
|
speedLimitValue: 0,
|
||||||
limitList: [
|
limitList: [
|
||||||
{ name: '5', value: 5 },
|
{ name: '5', value: 5 },
|
||||||
{ name: '10', value: 10 },
|
{ name: '10', value: 10 },
|
||||||
@ -122,11 +140,21 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
doShow(operate, selected) {
|
doShow(operate, selected, value) {
|
||||||
|
this.tempData = [];
|
||||||
|
this.sectionList.forEach(item => {
|
||||||
|
if (item.type === '01' || item.type === '04') {
|
||||||
|
this.tempData.push(item);
|
||||||
|
}
|
||||||
|
});
|
||||||
this.selected = selected;
|
this.selected = selected;
|
||||||
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
||||||
|
this.operate = operate;
|
||||||
|
this.speedLimitValue = value;
|
||||||
this.dialogShow = true;
|
this.dialogShow = true;
|
||||||
this.$nextTick(function () {
|
this.$nextTick(function () {
|
||||||
|
this.$refs.singleTable1.setCurrentRow(selected);
|
||||||
|
this.$refs.singleTable2.setCurrentRow(this.limitList[value / 5 - 1]);
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -135,14 +163,46 @@ export default {
|
|||||||
this.dialogShow = false;
|
this.dialogShow = false;
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
},
|
},
|
||||||
selectLine(val) {
|
selectLine1(val) {
|
||||||
// console.log(val);
|
this.$refs.singleTable1.setCurrentRow(this.selected);
|
||||||
this.selectShow = true;
|
},
|
||||||
|
selectLine2(val) {
|
||||||
|
this.$refs.singleTable2.setCurrentRow(this.limitList[this.speedLimitValue / 5 - 1]);
|
||||||
|
},
|
||||||
|
getStationName(val) {
|
||||||
|
const stationElm = this.$store.getters['map/getDeviceByCode'](val.stationCode);
|
||||||
|
return stationElm.name;
|
||||||
|
},
|
||||||
|
getIsLimit(code) {
|
||||||
|
const sectionEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
return sectionEle.speedUpLimit > 0 ? '开启' : '关闭';
|
||||||
|
},
|
||||||
|
getLimitSpeed(code) {
|
||||||
|
const sectionEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
return sectionEle.speedUpLimit > 0 ? sectionEle.speedUpLimit : 0;
|
||||||
|
},
|
||||||
|
getProcess(code) {
|
||||||
|
if (this.selected && this.selected.code === code) {
|
||||||
|
return '等待确认/取消';
|
||||||
|
} else {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
},
|
},
|
||||||
commit() {
|
commit() {
|
||||||
},
|
const operate = {
|
||||||
handleClick() {
|
cmdType: this.command ? CMD.Section.CMD_SECTION_SET_LIMIT_SPEED : CMD.Section.CMD_SECTION_CANCEL_LIMIT_SPEED,
|
||||||
|
operation: this.command ? OperationEvent.Section.setSpeed.confirm1.operation : OperationEvent.Section.cancelSpeed.confirm1.operation,
|
||||||
|
over: true,
|
||||||
|
param: {sectionCode: this.selected.code, speedLimitValue:this.speedLimitValue}
|
||||||
|
};
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
this.$emit('commandSuccess', this.selected.code, this.command ? this.speedLimitValue : 0);
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
const operate = {
|
const operate = {
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="700px" :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="700px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="18">
|
<el-col :span="18">
|
||||||
<el-table ref="singleTable" :data="sectionList" highlight-current-row height="300px" @current-change="selectLine">
|
<el-table ref="singleTable" :data="tempData" highlight-current-row height="300px" @current-change="selectLine">
|
||||||
<el-table-column prop="name" label="轨道" />
|
<el-table-column prop="name" label="轨道" />
|
||||||
<el-table-column prop="blockStatus" label="MAU">
|
<el-table-column prop="blockStatus" label="MAU">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@ -114,6 +114,12 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
doShow(operate, selected) {
|
doShow(operate, selected) {
|
||||||
|
this.tempData = [];
|
||||||
|
this.sectionList.forEach(item => {
|
||||||
|
if (item.type === '01' || item.type === '04') {
|
||||||
|
this.tempData.push(item);
|
||||||
|
}
|
||||||
|
});
|
||||||
this.selected = selected;
|
this.selected = selected;
|
||||||
this.operate = operate;
|
this.operate = operate;
|
||||||
this.dialogShow = true;
|
this.dialogShow = true;
|
||||||
|
@ -2,32 +2,48 @@
|
|||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="700px" :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="700px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="24">
|
<el-col :span="24">
|
||||||
<el-table :data="sectionList" highlight-current-row height="300px" @current-change="selectLine">
|
<el-table :data="tempData" highlight-current-row height="350px" @current-change="selectLine">
|
||||||
<el-table-column prop="name" label="轨道" />
|
<el-table-column prop="name" width="100" label="轨道" />
|
||||||
<el-table-column prop="blockStatus" label="MAU" />
|
<el-table-column prop="blockStatus" width="120" label="MAU">
|
||||||
<el-table-column prop="blockProcess" label="状态" />
|
<template slot-scope="scope">
|
||||||
<el-table-column prop="unblockProcess" label="临时限速" />
|
<span>{{ getStationName(scope.row) }}</span>
|
||||||
<el-table-column prop="unblockProcess" label="PM临时限速" />
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="blockProcess" width="150" label="状态">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getSectionStatus(scope.row) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="unblockProcess" label="临时限速">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getLimitSpeed(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="unblockProcess" width="100" label="PM临时限速">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getIsLimit(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="unblockProcess" label="站台" />
|
<el-table-column prop="unblockProcess" label="站台" />
|
||||||
<el-table-column prop="unblockProcess" label="闭塞区段" />
|
<el-table-column prop="unblockProcess" label="闭塞区段" />
|
||||||
<el-table-column prop="unblockProcess" label="打开进程" />
|
<el-table-column prop="unblockProcess" label="打开进程" />
|
||||||
<el-table-column prop="unblockProcess" label="关闭进程" />
|
<el-table-column prop="unblockProcess" label="关闭进程" />
|
||||||
<el-table-column prop="unblockProcess" label="设置临时限速进程" />
|
<el-table-column prop="unblockProcess" width="140" label="设置临时限速进程" />
|
||||||
<el-table-column prop="unblockProcess" label="清除临时限速进程" />
|
<el-table-column prop="unblockProcess" width="140" label="清除临时限速进程" />
|
||||||
<el-table-column prop="unblockProcess" label="用户里程起点" />
|
<el-table-column prop="unblockProcess" width="120" label="用户里程起点" />
|
||||||
<el-table-column prop="unblockProcess" label="用户里程终点" />
|
<el-table-column prop="unblockProcess" width="120" label="用户里程终点" />
|
||||||
</el-table>
|
</el-table>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row justify="center" class="button-group">
|
<el-row justify="center" class="button-group">
|
||||||
<el-col :span="4" :offset="5">
|
<el-col :span="4" :offset="5">
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">打印(P)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="true">打印(P)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button :id="domIdCancel" @click="cancel">关闭(C)</el-button>
|
<el-button :id="domIdCancel" @click="cancel">关闭(C)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button>帮助(H)</el-button>
|
<el-button :disabled="true">帮助(H)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<notice-info ref="noticeInfo" pop-class="ningbo-01__systerm" />
|
<notice-info ref="noticeInfo" pop-class="ningbo-01__systerm" />
|
||||||
@ -94,6 +110,12 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
doShow(operate, selected) {
|
doShow(operate, selected) {
|
||||||
|
this.tempData = [];
|
||||||
|
this.sectionList.forEach(item => {
|
||||||
|
if (item.type === '01' || item.type === '04') {
|
||||||
|
this.tempData.push(item);
|
||||||
|
}
|
||||||
|
});
|
||||||
this.selected = selected;
|
this.selected = selected;
|
||||||
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
||||||
this.dialogShow = true;
|
this.dialogShow = true;
|
||||||
@ -112,8 +134,21 @@ export default {
|
|||||||
},
|
},
|
||||||
commit() {
|
commit() {
|
||||||
},
|
},
|
||||||
handleClick() {
|
getStationName(val) {
|
||||||
|
const stationElm = this.$store.getters['map/getDeviceByCode'](val.stationCode);
|
||||||
|
return stationElm.name;
|
||||||
|
},
|
||||||
|
getLimitSpeed(code) {
|
||||||
|
const sectionEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
return sectionEle.speedUpLimit > 0 ? sectionEle.speedUpLimit : 0;
|
||||||
|
},
|
||||||
|
getSectionStatus(val) {
|
||||||
|
const sectionEle = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||||
|
return sectionEle.blockade ? '关闭双向:所有列车' : '打开';
|
||||||
|
},
|
||||||
|
getIsLimit(code) {
|
||||||
|
const sectionEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
return sectionEle.speedUpLimit > 0 ? '开启' : '关闭';
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
const operate = {
|
const operate = {
|
||||||
|
@ -1337,6 +1337,10 @@ export const OperationEvent = {
|
|||||||
menuButton: {
|
menuButton: {
|
||||||
operation: '4077',
|
operation: '4077',
|
||||||
domId: '_Tips-Section-SetSpeed-Menu{BOTTOM}'
|
domId: '_Tips-Section-SetSpeed-Menu{BOTTOM}'
|
||||||
|
},
|
||||||
|
choose1: {
|
||||||
|
operation: '4078',
|
||||||
|
domId: '_Tips-Section-SetSpeed-Choose1'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 取消速度
|
// 取消速度
|
||||||
|
Loading…
Reference in New Issue
Block a user