This commit is contained in:
fan 2020-03-20 15:01:22 +08:00
commit 471fac0499
22 changed files with 758 additions and 1085 deletions

View File

@ -1,7 +1,6 @@
/* /*
* 信号机 * 信号机
*/ */
import ESigPost from './ESigPost'; import ESigPost from './ESigPost';
import ESigLamp from './ESigLamp'; import ESigLamp from './ESigLamp';
import ESigAuto from './ESigAuto'; import ESigAuto from './ESigAuto';

View File

@ -36,13 +36,13 @@
</template> </template>
<script> <script>
// import { MapDeviceType, OperationEvent, getDomIdByOperation } from '@/scripts/ConstDic';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import OperationHandler from '@/scripts/cmdPlugin/OperationHandler'; import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import ConfirmControl from './childDialog/confirmControl'; import ConfirmControl from './childDialog/confirmControl';
import NoticeInfo from './childDialog/childDialog/noticeInfo'; import NoticeInfo from './childDialog/childDialog/noticeInfo';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import {menuOperate, commitOperate} from '../utils/menuOperate';
// import CMD from '@/scripts/cmdPlugin/CommandEnum';
export default { export default {
name: 'RouteControl', name: 'RouteControl',
@ -127,64 +127,35 @@ export default {
}, },
// //
cancelTrainRoute() { cancelTrainRoute() {
this.cancelTrainRouteFunc();
},
cancelTrainRouteFunc() {
const operate = {
over: true,
operation: OperationEvent.Signal.cancelTrainRoute.menu.operation,
cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_ROUTE
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.Signal.cancelTrainRoute, {}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) { }).catch((error) => {
this.doClose();
}
}).catch(error => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, error.message); this.$refs.noticeInfo.doShow({}, error.message);
}); });
}, },
// //
signalClose() { signalClose() {
const operate = {
operation: OperationEvent.Signal.signalClose.menu.operation,
messages: [`信号关灯: ${this.signalName}`]
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.Signal.signalClose, {}, 1).then((data)=>{
this.doClose();
this.$refs.confirmControl.doShow(data.operate);
}).catch(() => {
this.loading = false; this.loading = false;
if (valid) { this.doClose();
this.doClose();
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.confirmControl.doShow(operate);
}
}).catch((error) => {
this.loading = false;
this.$refs.noticeInfo.doShow(operate, error.message);
}); });
}, },
// //
reopenSignal() { reopenSignal() {
const operate = {
over: true,
operation: OperationEvent.Signal.reopenSignal.menu.operation,
cmdType: CMD.Signal.CMD_SIGNAL_REOPEN_SIGNAL
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.Signal.reopenSignal, {}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) { }).catch((error) => {
this.doClose();
}
}).catch(error => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, error.message); this.$refs.noticeInfo.doShow({}, error.message);
}); });
}, },
// //

View File

@ -1,53 +1,69 @@
<template> <template>
<div> <div>
<el-dialog class="beijing-01__systerm route-detail" :title="title" :visible.sync="show" width="340px" <el-dialog
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag> v-dialogDrag
<el-row class="header"> class="beijing-01__systerm route-detail"
<el-col :span="10"><span>车站</span></el-col> :title="title"
<el-col :span="10" :offset="2"><span>始端信号机</span></el-col> :visible.sync="show"
</el-row> width="340px"
<el-row> :before-close="doClose"
<el-col :span="10"> :z-index="2000"
<el-input v-model="stationName" size="small" disabled></el-input> :modal="false"
</el-col> :close-on-click-modal="false"
<el-col :span="10" :offset="2"> >
<el-input v-model="signalName" size="small" disabled></el-input> <el-row class="header">
</el-col> <el-col :span="10"><span>车站</span></el-col>
</el-row> <el-col :span="10" :offset="2"><span>始端信号机</span></el-col>
<div class="table"> </el-row>
<span>进路列表</span> <el-row>
<el-table ref="tempTable" :data="tempData" border style="width: 100%" size="mini" highlight-current-row <el-col :span="10">
:height="140"> <el-input v-model="stationName" size="small" disabled />
<el-table-column label="进路"> </el-col>
<template slot-scope="scope"> <el-col :span="10" :offset="2">
<span>{{scope.row.name}}</span> <el-input v-model="signalName" size="small" disabled />
</template> </el-col>
</el-table-column> </el-row>
<el-table-column prop="status" label="控制状态" width="180"> <div class="table">
<template slot-scope="scope"> <span>进路列表</span>
{{ scope.row.atsControl == '0' ? '人工' : '自动' }} <el-table
</template> ref="tempTable"
</el-table-column> :data="tempData"
</el-table> border
</div> style="width: 100%"
<el-row justify="center" class="button-group"> size="mini"
<el-col :span="10" :offset="2"> highlight-current-row
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button> :height="140"
</el-col> >
<el-col :span="8" :offset="4"> <el-table-column label="进路">
<el-button :id="domIdCancel" @click="cancel"> </el-button> <template slot-scope="scope">
</el-col> <span>{{ scope.row.name }}</span>
</el-row> </template>
<notice-info ref="noticeInfo"></notice-info> </el-table-column>
</el-dialog> <el-table-column prop="status" label="控制状态" width="180">
</div> <template slot-scope="scope">
{{ scope.row.atsControl == '0' ? '人工' : '自动' }}
</template>
</el-table-column>
</el-table>
</div>
<el-row justify="center" class="button-group">
<el-col :span="10" :offset="2">
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
</el-col>
<el-col :span="8" :offset="4">
<el-button :id="domIdCancel" @click="cancel"> </el-button>
</el-col>
</el-row>
<notice-info ref="noticeInfo" />
</el-dialog>
</div>
</template> </template>
<script> <script>
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
import { MapDeviceType, OperationEvent } from '@/scripts/ConstDic'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import NoticeInfo from './childDialog/childDialog/noticeInfo' import NoticeInfo from './childDialog/childDialog/noticeInfo';
export default { export default {
name: 'RouteDetail', name: 'RouteDetail',
@ -61,8 +77,8 @@ export default {
selected: null, selected: null,
tempData: [], tempData: [],
stationName: '', stationName: '',
signalName: '', signalName: ''
} };
}, },
computed: { computed: {
...mapGetters('map', [ ...mapGetters('map', [
@ -78,24 +94,24 @@ export default {
return this.dialogShow ? OperationEvent.Signal.detail.menu.domId : ''; return this.dialogShow ? OperationEvent.Signal.detail.menu.domId : '';
}, },
title() { title() {
return '查询进路状态' return '查询进路状态';
} }
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.$store.dispatch('training/tipReload'); this.$store.dispatch('training/tipReload');
}) });
}, },
methods: { methods: {
doShow(operate, selected, tempData) { doShow(operate, selected, tempData) {
this.selected = selected; this.selected = selected;
// //
if (!this.dialogShow) { if (!this.dialogShow) {
this.signalName = ''; this.signalName = '';
this.stationName = ''; this.stationName = '';
if (selected && selected._type.toUpperCase() === 'Signal'.toUpperCase()) { if (selected && selected._type.toUpperCase() === 'Signal'.toUpperCase()) {
this.signalName = selected.name this.signalName = selected.name;
let station = this.$store.getters['map/getDeviceByCode'](selected.stationCode); const station = this.$store.getters['map/getDeviceByCode'](selected.stationCode);
if (station) { if (station) {
this.stationName = station.name; this.stationName = station.name;
} }
@ -115,11 +131,10 @@ export default {
mouseCancelState(this.selected); mouseCancelState(this.selected);
}, },
commit() { commit() {
let operate = { const operate = {
send: true, send: true,
type: MapDeviceType.Signal.type,
operation: OperationEvent.Signal.detail.menu.operation operation: OperationEvent.Signal.detail.menu.operation
} };
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
@ -134,10 +149,9 @@ export default {
}); });
}, },
cancel() { cancel() {
let operate = { const operate = {
type: MapDeviceType.Signal.type, operation: OperationEvent.Command.cancel.menu.operation
operation: OperationEvent.Command.cancel.menu.operation, };
}
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
@ -148,5 +162,5 @@ export default {
}); });
} }
} }
} };
</script> </script>

View File

@ -80,7 +80,7 @@ import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import OperationHandler from '@/scripts/cmdPlugin/OperationHandler'; import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import NoticeInfo from './childDialog/childDialog/noticeInfo'; import NoticeInfo from './childDialog/childDialog/noticeInfo';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import {menuOperate, commitOperate} from '../utils/menuOperate';
export default { export default {
name: 'RouteHandControl', name: 'RouteHandControl',
@ -278,47 +278,24 @@ export default {
}, },
// //
humanControl() { humanControl() {
const operate = {
over: true,
operation: OperationEvent.Signal.humanControl.menu.operation,
cmdType: CMD.Signal.CMD_SIGNAL_CLOSE_AUTO_SETTING,
param:{
routeCodeList:this.selection
}
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.Signal.humanControl, {routeCodeList:this.selection}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, error.message); this.$refs.noticeInfo.doShow({}, error.message);
}); });
}, },
// //
atsAutoControl() { atsAutoControl() {
const operate = {
over: true,
operation: OperationEvent.Signal.atsAutoControl.menu.operation,
cmdType: CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING,
param:{
routeCodeList:this.selection
}
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.Signal.atsAutoControl, {routeCodeList:this.selection}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, error.message); this.$refs.noticeInfo.doShow({}, error.message);
}); });
}, },
cancel() { cancel() {

View File

@ -61,11 +61,11 @@
</template> </template>
<script> <script>
import { MapDeviceType, OperationEvent } from '@/scripts/ConstDic'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import NoticeInfo from './childDialog/childDialog/noticeInfo'; import NoticeInfo from './childDialog/childDialog/noticeInfo';
import { deepAssign } from '@/utils/index'; import { deepAssign } from '@/utils/index';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import {menuOperate, commitOperate} from '../utils/menuOperate';
export default { export default {
name: 'RouteSelection', name: 'RouteSelection',
@ -210,7 +210,6 @@ export default {
// //
const operate = { const operate = {
type: MapDeviceType.Signal.type,
operation: OperationEvent.Signal.arrangementRoute.choose.operation, operation: OperationEvent.Signal.arrangementRoute.choose.operation,
val: row.code val: row.code
}; };
@ -225,34 +224,20 @@ export default {
}, },
commit() { commit() {
if (this.row && this.row.canSetting) { if (this.row && this.row.canSetting) {
const operate = {
over: true,
operation: OperationEvent.Signal.arrangementRoute.menu.operation,
cmdType: CMD.Signal.CMD_SIGNAL_SET_ROUTE,
param: {
routeCode: this.row.code
}
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.Signal.arrangementRoute, {routeCode:this.row.code}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, error.message); this.$refs.noticeInfo.doShow({}, error.message);
}); });
} }
}, },
cancel() { cancel() {
const operate = { const operate = {
type: MapDeviceType.Signal.type,
operation: OperationEvent.Command.cancel.menu.operation operation: OperationEvent.Command.cancel.menu.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.doClose(); this.doClose();

View File

@ -45,10 +45,11 @@
</template> </template>
<script> <script>
import { MapDeviceType, OperationEvent, getDomIdByOperation } from '@/scripts/ConstDic'; import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import NoticeInfo from './childDialog/childDialog/noticeInfo'; import NoticeInfo from './childDialog/childDialog/noticeInfo';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import {menuOperate, commitOperate} from '../utils/menuOperate';
export default { export default {
name: 'SectionControl', name: 'SectionControl',
@ -75,12 +76,14 @@ export default {
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : ''; return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? getDomIdByOperation(this.operation) : ''; return this.dialogShow ? OperationHandler.getDomIdByOperation(this.operation) : '';
}, },
title() { title() {
if (this.operation == OperationEvent.Section.split.menu.operation) { if (this.operation == OperationEvent.Section.split.menu.operation) {
this.radio = '2';
return '区段控制'; return '区段控制';
} else if (this.operation == OperationEvent.Section.active.menu.operation) { } else if (this.operation == OperationEvent.Section.active.menu.operation) {
this.radio = '1';
return '区段控制'; return '区段控制';
} else if (this.operation == OperationEvent.Section.fault.menu.operation) { } else if (this.operation == OperationEvent.Section.fault.menu.operation) {
return '区故解'; return '区故解';
@ -157,48 +160,24 @@ export default {
}, },
// //
faultUnlock() { faultUnlock() {
const operate = { this.sendCommand(menuOperate.Section.fault);
over: true,
operation: OperationEvent.Section.fault.menu.operation,
cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK
};
this.sendCommand(operate);
}, },
// //
axlePreReset() { axlePreReset() {
const operate = { this.sendCommand(menuOperate.Section.axlePreReset);
over: true,
operation: OperationEvent.Section.axlePreReset.menu.operation,
cmdType: CMD.Section.CMD_SECTION_AXIS_PRE_RESET
};
this.sendCommand(operate);
}, },
// //
split() { split() {
const operate = { this.sendCommand(menuOperate.Section.split);
over: true,
operation: OperationEvent.Section.split.menu.operation,
cmdType: CMD.Section.CMD_SECTION_CUT_OFF
};
this.sendCommand(operate);
}, },
// //
active() { active() {
const operate = { this.sendCommand(menuOperate.Section.active);
over: true,
operation: OperationEvent.Section.active.menu.operation,
cmdType: CMD.Section.CMD_SECTION_ACTIVE
};
this.sendCommand(operate);
}, },
cancel() { cancel() {
const operate = { const operate = {
type: MapDeviceType.Section.type,
operation: OperationEvent.Command.cancel.menu.operation operation: OperationEvent.Command.cancel.menu.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
this.doClose(); this.doClose();
@ -207,18 +186,14 @@ export default {
this.doClose(); this.doClose();
}); });
}, },
sendCommand(operate) { // sendCommand(operate) { //
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(operate, {}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, error.message); this.$refs.noticeInfo.doShow({}, error.message);
}); });
} }
} }

View File

@ -1,78 +1,104 @@
<template> <template>
<div> <div>
<el-dialog class="beijing-01__systerm section-cmd-speed" :title="title" :visible.sync="show" width="800px" <el-dialog
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag> v-dialogDrag
<div style="padding: 10px 20px; border: 1px solid lightgray;"> class="beijing-01__systerm section-cmd-speed"
<span class="base-label">命令信息</span> :title="title"
<el-form label-position="center" size="mini"> :visible.sync="show"
<el-row> width="800px"
<el-col :span="6"> :before-close="doClose"
<el-form-item label="类型" label-width="40px"> :z-index="2000"
<el-select v-model="operation" size="small" disabled> :modal="false"
<el-option v-for="option in typeList" :key="option.code" :label="option.name" :close-on-click-modal="false"
:value="option.code"> >
</el-option> <div style="padding: 10px 20px; border: 1px solid lightgray;">
</el-select> <span class="base-label">命令信息</span>
</el-form-item> <el-form label-position="center" size="mini">
</el-col> <el-row>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="车站名称" label-width="80px"> <el-form-item label="类型" label-width="40px">
<el-input v-model="stationName" size="small" disabled></el-input> <el-select v-model="operation" size="small" disabled>
</el-form-item> <el-option
</el-col> v-for="option in typeList"
<el-col :span="6"> :key="option.code"
<el-form-item :label="nameLabel" label-width="80px"> :label="option.name"
<el-input v-model="name" size="small" disabled></el-input> :value="option.code"
</el-form-item> />
</el-col> </el-select>
<el-col :span="6"> </el-form-item>
<el-form-item label="限速值" label-width="80px"> </el-col>
<el-select v-model="speed" :id="domIdChoose" size="small" :disabled="spdDisabled" <el-col :span="6">
@change="speedSelectChange"> <el-form-item label="车站名称" label-width="80px">
<el-option v-for="item in speedList" :key="item.value" :label="item.name" <el-input v-model="stationName" size="small" disabled />
:value="item.value"> </el-form-item>
</el-option> </el-col>
</el-select> <el-col :span="6">
</el-form-item> <el-form-item :label="nameLabel" label-width="80px">
</el-col> <el-input v-model="name" size="small" disabled />
</el-row> </el-form-item>
</el-form> </el-col>
</div> <el-col :span="6">
<el-table class="table" ref="table" :data="tableData" border style="width: 100%" size="mini" <el-form-item label="限速值" label-width="80px">
highlight-current-row height="200"> <el-select
<el-table-column prop="order" :width="50" label="序号"> :id="domIdChoose"
</el-table-column> v-model="speed"
<el-table-column prop="date" :width="160" label="时间"> size="small"
</el-table-column> :disabled="spdDisabled"
<el-table-column prop="context" :width="180" label="执行过程"> @change="speedSelectChange"
</el-table-column> >
<el-table-column prop="result" label="执行结果"> <el-option
</el-table-column> v-for="item in speedList"
</el-table> :key="item.value"
<span class="notice">{{message}}</span> :label="item.name"
<el-row class="button-group"> :value="item.value"
<el-col :span="2" :offset="2"> />
<el-button :id="domIdCommand" type="primary" :disabled="cmdDisabled[0]" @click="command">下达<span </el-select>
v-show="timeCountCommand>0">({{timeCountCommand}})</span></el-button> </el-form-item>
</el-col> </el-col>
<el-col :span="2" :offset="2"> </el-row>
<el-button :id="domIdConfirm1" type="primary" :disabled="cmdDisabled[1]" @click="confirm1">确认1 </el-form>
</el-button> </div>
</el-col> <el-table
<el-col :span="2" :offset="2"> ref="table"
<el-button :id="domIdConfirm2" type="primary" :disabled="cmdDisabled[2]" @click="confirm2">确认2<span class="table"
v-show="timeCountConfirm>0">({{timeCountConfirm}})</span></el-button> :data="tableData"
</el-col> border
<el-col :span="2" :offset="2"> style="width: 100%"
<el-button :id="domIdStop" type="primary" :disabled="stpDisabled" @click="stop">中止</el-button> size="mini"
</el-col> highlight-current-row
<el-col :span="2" :offset="2"> height="200"
<el-button :id="domIdClose" @click="close">关闭</el-button> >
</el-col> <el-table-column prop="order" :width="50" label="序号" />
</el-row> <el-table-column prop="date" :width="160" label="时间" />
</el-dialog> <el-table-column prop="context" :width="180" label="执行过程" />
<confirm-control-speed ref="confirmControlSpeed" @setOperate="getOperate"></confirm-control-speed> <el-table-column prop="result" label="执行结果" />
</div> </el-table>
<span class="notice">{{ message }}</span>
<el-row class="button-group">
<el-col :span="2" :offset="2">
<el-button :id="domIdCommand" type="primary" :disabled="cmdDisabled[0]" @click="command">下达<span
v-show="timeCountCommand>0"
>({{ timeCountCommand }})</span></el-button>
</el-col>
<el-col :span="2" :offset="2">
<el-button :id="domIdConfirm1" type="primary" :disabled="cmdDisabled[1]" @click="confirm1">确认1
</el-button>
</el-col>
<el-col :span="2" :offset="2">
<el-button :id="domIdConfirm2" type="primary" :disabled="cmdDisabled[2]" @click="confirm2">确认2<span
v-show="timeCountConfirm>0"
>({{ timeCountConfirm }})</span></el-button>
</el-col>
<el-col :span="2" :offset="2">
<el-button :id="domIdStop" type="primary" :disabled="stpDisabled" @click="stop">中止</el-button>
</el-col>
<el-col :span="2" :offset="2">
<el-button :id="domIdClose" @click="close">关闭</el-button>
</el-col>
</el-row>
</el-dialog>
<confirm-control-speed ref="confirmControlSpeed" @setOperate="getOperate" />
</div>
</template> </template>
<script> <script>
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import CMD from '@/scripts/cmdPlugin/CommandEnum';
@ -107,7 +133,7 @@ export default {
stationName: '', stationName: '',
name: '', name: '',
speed: '' speed: ''
} };
}, },
computed: { computed: {
nameLabel() { nameLabel() {
@ -117,14 +143,14 @@ export default {
} else if (this.operation == OperationEvent.Switch.setSpeed.menu.operation || } else if (this.operation == OperationEvent.Switch.setSpeed.menu.operation ||
this.operation == OperationEvent.Switch.cancelSpeed.menu.operation) { this.operation == OperationEvent.Switch.cancelSpeed.menu.operation) {
return '道岔名称'; return '道岔名称';
}else{ } else {
return ''; return '';
} }
}, },
speedList() { speedList() {
let list = [{ name: '不限速', value: '-1' }]; const list = [{ name: '不限速', value: '-1' }];
for (var i = 0; i * this.speedSpace <= this.maxSpeed; i++) { for (var i = 0; i * this.speedSpace <= this.maxSpeed; i++) {
let speed = String(i * this.speedSpace); const speed = String(i * this.speedSpace);
list.push({ name: speed, value: speed }); list.push({ name: speed, value: speed });
} }
return list; return list;
@ -134,8 +160,8 @@ export default {
{ code: OperationEvent.Section.setSpeed.menu.operation, name: '区段设置限速' }, { code: OperationEvent.Section.setSpeed.menu.operation, name: '区段设置限速' },
{ code: OperationEvent.Section.cancelSpeed.menu.operation, name: '区段取消限速' }, { code: OperationEvent.Section.cancelSpeed.menu.operation, name: '区段取消限速' },
{ code: OperationEvent.Switch.setSpeed.menu.operation, name: '区段设置限速' }, { code: OperationEvent.Switch.setSpeed.menu.operation, name: '区段设置限速' },
{ code: OperationEvent.Switch.cancelSpeed.menu.operation, name: '区段取消限速' }, { code: OperationEvent.Switch.cancelSpeed.menu.operation, name: '区段取消限速' }
] ];
}, },
title() { title() {
if (this.dialogShow) { if (this.dialogShow) {
@ -264,9 +290,9 @@ export default {
} }
}, },
isCancelSpeed() { isCancelSpeed() {
return this.operation == OperationEvent.Section.cancelSpeed.menu.operation return this.operation == OperationEvent.Section.cancelSpeed.menu.operation ||
|| this.operation == OperationEvent.Switch.cancelSpeed.menu.operation this.operation == OperationEvent.Switch.cancelSpeed.menu.operation;
}, }
}, },
watch: { watch: {
cmdDisabled: { cmdDisabled: {
@ -294,7 +320,7 @@ export default {
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.$store.dispatch('training/tipReload'); this.$store.dispatch('training/tipReload');
}) });
this.timer = setInterval(() => { this.timer = setInterval(() => {
if (!this.$store.state.menuOperation.break) { if (!this.$store.state.menuOperation.break) {
if (this.timeCountCommand > 0) { if (this.timeCountCommand > 0) {
@ -310,7 +336,7 @@ export default {
this.timeCountConfirm = -1; this.timeCountConfirm = -1;
} }
} }
}, 1000) }, 1000);
}, },
beforeDestroy() { beforeDestroy() {
clearInterval(this.timer); clearInterval(this.timer);
@ -326,20 +352,20 @@ export default {
operate.operation == OperationEvent.Section.cancelSpeed.menu.operation) { operate.operation == OperationEvent.Section.cancelSpeed.menu.operation) {
if (selected && selected._type.toUpperCase() === 'Section'.toUpperCase()) { if (selected && selected._type.toUpperCase() === 'Section'.toUpperCase()) {
if (selected.type === '02') { if (selected.type === '02') {
let section = this.$store.getters['map/getDeviceByCode'](selected.parentCode); const section = this.$store.getters['map/getDeviceByCode'](selected.parentCode);
if (section) { if (section) {
this.name += section.name this.name += section.name;
} }
} }
this.name += selected.name this.name += selected.name;
} }
} else if (operate.operation == OperationEvent.Switch.setSpeed.menu.operation) { } else if (operate.operation == OperationEvent.Switch.setSpeed.menu.operation) {
if (selected._type.toUpperCase() === 'Switch'.toUpperCase()) { if (selected._type.toUpperCase() === 'Switch'.toUpperCase()) {
this.name = selected.name this.name = selected.name;
} }
} }
let station = this.$store.getters['map/getDeviceByCode'](selected.stationCode); const station = this.$store.getters['map/getDeviceByCode'](selected.stationCode);
if (station) { if (station) {
this.stationName = station.name; this.stationName = station.name;
} }
@ -373,17 +399,17 @@ export default {
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}, },
speedSelectChange(val) { speedSelectChange(val) {
let operate = { const operate = {
type: this.type, type: this.type,
val: val, val: val
} };
if (this.operation == OperationEvent.Section.setSpeed.menu.operation) { if (this.operation == OperationEvent.Section.setSpeed.menu.operation) {
/** 区段设置限速*/ /** 区段设置限速*/
operate.operation = OperationEvent.Section.setSpeed.choose.operation operate.operation = OperationEvent.Section.setSpeed.choose.operation;
} else if (this.operation == OperationEvent.Switch.setSpeed.menu.operation) { } else if (this.operation == OperationEvent.Switch.setSpeed.menu.operation) {
/** 道岔设置限速*/ /** 道岔设置限速*/
operate.operation = OperationEvent.Switch.setSpeed.choose.operation operate.operation = OperationEvent.Switch.setSpeed.choose.operation;
} }
this.setMessage('请点击“下达”按钮,下达命令!'); this.setMessage('请点击“下达”按钮,下达命令!');
@ -392,12 +418,12 @@ export default {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.setButtonEnable({ step: 0 }); this.setButtonEnable({ step: 0 });
} }
}) });
}, },
command() { command() {
let operate = { const operate = {
type: this.type, type: this.type
} };
if (this.operation == OperationEvent.Section.setSpeed.menu.operation) { if (this.operation == OperationEvent.Section.setSpeed.menu.operation) {
/** 区段设置限速*/ /** 区段设置限速*/
@ -429,12 +455,12 @@ export default {
} }
}).catch(() => { }).catch(() => {
this.editRecord({ order: this.order, date: now(), context: '点击下达命令', result: '执行异常' }); this.editRecord({ order: this.order, date: now(), context: '点击下达命令', result: '执行异常' });
}) });
}, },
confirm1() { confirm1() {
let operate = { const operate = {
type: this.type, type: this.type
} };
if (this.operation == OperationEvent.Section.setSpeed.menu.operation) { if (this.operation == OperationEvent.Section.setSpeed.menu.operation) {
/** 区段设置限速*/ /** 区段设置限速*/
@ -464,17 +490,17 @@ export default {
} }
}).catch(() => { }).catch(() => {
this.editRecord({ order: this.order, date: now(), context: '点击确认1', result: '执行异常' }); this.editRecord({ order: this.order, date: now(), context: '点击确认1', result: '执行异常' });
}) });
}, },
confirm2() { confirm2() {
let operate = { const operate = {
over:true, over:true,
type: this.type, type: this.type,
val: this.speed, val: this.speed,
param: { param: {
speedLimitValue: `${this.speed}` speedLimitValue: `${this.speed}`
} }
} };
if (this.operation == OperationEvent.Section.setSpeed.menu.operation) { if (this.operation == OperationEvent.Section.setSpeed.menu.operation) {
/** 区段设置限速*/ /** 区段设置限速*/
@ -509,12 +535,12 @@ export default {
this.timeCountConfirm = -1; this.timeCountConfirm = -1;
this.setButtonEnable({ step: -1 }); this.setButtonEnable({ step: -1 });
this.editRecord({ order: this.order, date: now(), context: '点击确认2', result: '执行异常' }); this.editRecord({ order: this.order, date: now(), context: '点击确认2', result: '执行异常' });
}) });
}, },
stop() { stop() {
let operate = { const operate = {
type: this.type, type: this.type
} };
if (this.operation == OperationEvent.Section.setSpeed.menu.operation) { if (this.operation == OperationEvent.Section.setSpeed.menu.operation) {
/** 区段设置限速*/ /** 区段设置限速*/
@ -541,13 +567,13 @@ export default {
} }
}).catch(() => { }).catch(() => {
this.editRecord({ order: this.order, date: now(), context: '点击终止', result: '执行异常' }); this.editRecord({ order: this.order, date: now(), context: '点击终止', result: '执行异常' });
}) });
}, },
close() { close() {
let operate = { const operate = {
type: this.type, type: this.type,
operation: OperationEvent.Command.close.menu.operation, operation: OperationEvent.Command.close.menu.operation
} };
this.writeRecord({ order: ++this.order, date: now(), context: '点击关闭', result: '' }); this.writeRecord({ order: ++this.order, date: now(), context: '点击关闭', result: '' });
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) { if (valid) {
@ -581,8 +607,8 @@ export default {
elem[prop] = param[prop]; elem[prop] = param[prop];
} }
} }
}) });
} }
} }
} };
</script> </script>

View File

@ -1,41 +1,58 @@
<template> <template>
<el-dialog class="beijing-01__systerm stand-run-level" :title="title" :visible.sync="show" width="320px" <el-dialog
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag> v-dialogDrag
<div style="font-size: 16px; margin-bottom: 5px;">变通节点</div> class="beijing-01__systerm stand-run-level"
<div style="margin-bottom: 5px;"> :title="title"
<el-input v-model="stationName" size="mini" disabled></el-input> :visible.sync="show"
</div> width="320px"
<div style="font-size: 16px; margin-bottom: 5px;">当前变通策略</div> :before-close="doClose"
<div style="margin-bottom: 5px;"> :z-index="2000"
<el-input v-model="stationStrategy" size="mini" disabled></el-input> :modal="false"
</div> :close-on-click-modal="false"
<div style="font-size: 16px; margin-bottom: 5px;">变通策略选项</div> >
<el-table ref="table" :data="strategyList" border :cell-style="tableStyle" style="width: 100%; margin-top:10px" <div style="font-size: 16px; margin-bottom: 5px;">变通节点</div>
size="mini" @row-click="clickEvent" height="120" highlight-current-row :show-header="false"> <div style="margin-bottom: 5px;">
<el-table-column prop="label" :id="domIdChoose" style="margin-left:30px"> <el-input v-model="stationName" size="mini" disabled />
</el-table-column> </div>
</el-table> <div style="font-size: 16px; margin-bottom: 5px;">当前变通策略</div>
<el-row justify="center" class="button-group"> <div style="margin-bottom: 5px;">
<el-col :span="10" :offset="2"> <el-input v-model="stationStrategy" size="mini" disabled />
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="!isConfirm" @click="commit"> </div>
确定</el-button> <div style="font-size: 16px; margin-bottom: 5px;">变通策略选项</div>
</el-col> <el-table
<el-col :span="8" :offset="4"> ref="table"
<el-button :id="domIdCancel" @click="cancel"> </el-button> :data="strategyList"
</el-col> border
</el-row> :cell-style="tableStyle"
<confirm-control ref="confirmControl"></confirm-control> style="width: 100%; margin-top:10px"
<notice-info ref="noticeInfo"></notice-info> size="mini"
</el-dialog> height="120"
highlight-current-row
:show-header="false"
@row-click="clickEvent"
>
<el-table-column :id="domIdChoose" prop="label" style="margin-left:30px" />
</el-table>
<el-row justify="center" class="button-group">
<el-col :span="10" :offset="2">
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="!isConfirm" @click="commit">
确定</el-button>
</el-col>
<el-col :span="8" :offset="4">
<el-button :id="domIdCancel" @click="cancel"> </el-button>
</el-col>
</el-row>
<confirm-control ref="confirmControl" />
<notice-info ref="noticeInfo" />
</el-dialog>
</template> </template>
<script> <script>
import ConfirmControl from './childDialog/confirmControl'; import ConfirmControl from './childDialog/confirmControl';
import NoticeInfo from './childDialog/childDialog/noticeInfo' import NoticeInfo from './childDialog/childDialog/noticeInfo';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import {menuOperate, commitOperate} from '../utils/menuOperate';
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
export default { export default {
@ -65,7 +82,7 @@ export default {
{ {
value: '04', value: '04',
label: '关闭' label: '关闭'
}, }
], ],
stationName: '', stationName: '',
stationStrategy: '', stationStrategy: '',
@ -73,13 +90,13 @@ export default {
isConfirm: false, isConfirm: false,
strategy: '', strategy: '',
tableStyle: { tableStyle: {
'border-bottom': 'none', 'border-bottom': 'none'
} }
} };
}, },
computed: { computed: {
...mapGetters('map', [ ...mapGetters('map', [
'stationList', 'stationList'
]), ]),
show() { show() {
return this.dialogShow && !this.$store.state.menuOperation.break; return this.dialogShow && !this.$store.state.menuOperation.break;
@ -100,17 +117,17 @@ export default {
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.$store.dispatch('training/tipReload'); this.$store.dispatch('training/tipReload');
}) });
}, },
methods: { methods: {
loadInitData(selected, opts) { loadInitData(selected, opts) {
this.tempData = []; this.tempData = [];
let stationList = [...this.stationList]; const stationList = [...this.stationList];
const station = this.stationList.find(n => n.code == selected.stationCode) const station = this.stationList.find(n => n.code == selected.stationCode);
this.tempData.push({ name: station.name, station: selected.name, strategy: opts.reentryStrategy }); this.tempData.push({ name: station.name, station: selected.name, strategy: opts.reentryStrategy });
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.table.setCurrentRow(null); this.$refs.table.setCurrentRow(null);
}) });
}, },
doShow(operate, selected, opts) { doShow(operate, selected, opts) {
this.selected = selected; this.selected = selected;
@ -125,7 +142,7 @@ export default {
if (item.value == opts.reentryStrategy) { if (item.value == opts.reentryStrategy) {
this.stationStrategy = item.label; this.stationStrategy = item.label;
} }
}) });
} }
} }
this.loadInitData(selected, opts); this.loadInitData(selected, opts);
@ -138,7 +155,7 @@ export default {
}, },
clickEvent(row, column, event) { clickEvent(row, column, event) {
const operate = { const operate = {
operation: OperationEvent.StationStand.setBackStrategy.choose.operation, operation: OperationEvent.StationStand.setBackStrategy.choose.operation
}; };
this.strategy = row.value; this.strategy = row.value;
this.isConfirm = true; this.isConfirm = true;
@ -146,7 +163,7 @@ export default {
if (valid) { if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
} }
}) });
}, },
checkTableDataSelction(data) { checkTableDataSelction(data) {
const selection = []; const selection = [];
@ -155,10 +172,10 @@ export default {
if (row.check && !row.disabled) { if (row.check && !row.disabled) {
selection.push(row); selection.push(row);
} }
}) });
} }
this.disabledSend = selection.length ? false : true; this.disabledSend = !selection.length;
if (JSON.stringify(selection) !== JSON.stringify(this.selection)) { if (JSON.stringify(selection) !== JSON.stringify(this.selection)) {
this.selection = selection; this.selection = selection;
} }
@ -171,25 +188,13 @@ export default {
}, },
commit() { commit() {
if (this.isConfirm) { if (this.isConfirm) {
const operate = {
over:true,
operation: OperationEvent.StationStand.setBackStrategy.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_REENTRY_STRATEGY,
param:{
standReentryStrategy: this.strategy
}
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.StationStand.setBackStrategy, {standReentryStrategy: this.strategy}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, [error.message]); this.$refs.noticeInfo.doShow({}, error.message);
}); });
} else { } else {
this.doClose(); this.doClose();
@ -197,7 +202,7 @@ export default {
}, },
cancel() { cancel() {
const operate = { const operate = {
operation: OperationEvent.Command.cancel.menu.operation, operation: OperationEvent.Command.cancel.menu.operation
}; };
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
@ -209,5 +214,5 @@ export default {
}); });
} }
} }
} };
</script> </script>

View File

@ -110,10 +110,11 @@
</template> </template>
<script> <script>
import { MapDeviceType, OperationEvent, getDomIdByOperation } from '@/scripts/ConstDic'; import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import NoticeInfo from './childDialog/childDialog/noticeInfo'; import NoticeInfo from './childDialog/childDialog/noticeInfo';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import {menuOperate, commitOperate} from '../utils/menuOperate';
export default { export default {
name: 'StandDetainTrain', name: 'StandDetainTrain',
@ -142,7 +143,7 @@ export default {
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : ''; return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? getDomIdByOperation(this.operation) : ''; return this.dialogShow ? OperationHandler.getDomIdByOperation(this.operation) : '';
}, },
upRadioId() { upRadioId() {
return this.dialogShow ? OperationEvent.StationStand.earlyDeparture.upSelect.domId : ''; return this.dialogShow ? OperationEvent.StationStand.earlyDeparture.upSelect.domId : '';
@ -252,65 +253,25 @@ export default {
}, },
// //
setDetainTrain() { setDetainTrain() {
const operate = { this.sendCommand(menuOperate.StationStand.setDetainTrain);
over: true,
operation: OperationEvent.StationStand.setDetainTrain.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_HOLD_TRAIN
};
this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
this.loading = false;
this.doClose();
if (!valid) {
this.$refs.noticeInfo.doShow(operate);
}
}).catch((error) => {
this.loading = false;
this.doClose();
this.$refs.noticeInfo.doShow(operate, [error.message]);
});
}, },
// //
cancelDetainTrain() { cancelDetainTrain() {
const operate = { this.sendCommand(menuOperate.StationStand.cancelDetainTrain);
over: true,
operation: OperationEvent.StationStand.cancelDetainTrain.menu.operation,
cmdType: CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN
};
this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
this.loading = false;
this.doClose();
if (!valid) {
this.$refs.noticeInfo.doShow(operate);
}
}).catch((error) => {
this.loading = false;
this.doClose();
this.$refs.noticeInfo.doShow(operate, [error.message]);
});
}, },
// //
earlyDeparture() { earlyDeparture() {
const operate = { this.sendCommand(menuOperate.StationStand.earlyDeparture);
over: true, },
operation: OperationEvent.StationStand.earlyDeparture.menu.operation, sendCommand(operate) { //
cmdType: CMD.Stand.CMD_STAND_EARLY_DEPART
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(operate, {}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, [error.message]); this.$refs.noticeInfo.doShow({}, error.message);
}); });
}, },
cancel() { cancel() {

View File

@ -103,9 +103,10 @@
<script> <script>
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
import { MapDeviceType, OperationEvent, getDomIdByOperation } from '@/scripts/ConstDic'; import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import {menuOperate, commitOperate} from '../utils/menuOperate';
import NoticeInfo from './childDialog/childDialog/noticeInfo'; import NoticeInfo from './childDialog/childDialog/noticeInfo';
export default { export default {
@ -163,7 +164,7 @@ export default {
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : ''; return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
}, },
domIdConfirm() { domIdConfirm() {
return this.dialogShow ? getDomIdByOperation(this.operation) : ''; return this.dialogShow ? OperationHandler.getDomIdByOperation(this.operation) : '';
}, },
title() { title() {
return '跳停'; return '跳停';
@ -243,65 +244,29 @@ export default {
}, },
// //
setJumpStop() { setJumpStop() {
// let val = this.model.val1;
// if (this.model.val2) {
// val = this.model.val2 + '::' + this.model.tripNumber;
// }
const operate = {
over: true,
cmdType: CMD.Stand.CMD_STAND_SET_JUMP_STOP,
operation: OperationEvent.StationStand.setJumpStop.menu.operation,
param:{
trainGroupNumber:this.model.tripNumber
}
// val: this.selected.direction //, 01: /02:
// val: val
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.StationStand.setJumpStop, {trainGroupNumber:this.model.tripNumber}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, [error.message]); this.$refs.noticeInfo.doShow({}, error.message);
}); });
}, },
// //
cancelJumpStop() { cancelJumpStop() {
// let val = this.model.val1;
// if (this.model.val2) {
// val = this.model.val2 + '::' + this.model.tripNumber;
// }
const operate = {
over: true,
cmdType: CMD.Stand.CMD_STAND_CANCEL_JUMP_STOP,
operation: OperationEvent.StationStand.cancelJumpStop.menu.operation,
param:{
trainGroupNumber:this.model.tripNumber
}
// val: val // , 01: /02:
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.StationStand.cancelJumpStop, {trainGroupNumber:this.model.tripNumber}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, [error.message]); this.$refs.noticeInfo.doShow({}, error.message);
}); });
}, },
cancel() { cancel() {
const operate = { const operate = {
type: MapDeviceType.StationStand.type,
operation: OperationEvent.Command.cancel.menu.operation operation: OperationEvent.Command.cancel.menu.operation
}; };

View File

@ -89,7 +89,7 @@
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import {menuOperate, commitOperate} from '../utils/menuOperate';
import NoticeInfo from './childDialog/childDialog/noticeInfo'; import NoticeInfo from './childDialog/childDialog/noticeInfo';
export default { export default {
@ -311,27 +311,13 @@ export default {
}, },
commit() { commit() {
if (this.isConfirm) { if (this.isConfirm) {
const operate = {
over: true,
operation: OperationEvent.StationStand.setRunLevel.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_RUN_TIME,
param: {
runLevelTime: this.time,
runLevelTimeForever: !!this.tempData[0].check
}
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.StationStand.setRunLevel, {runLevelTime: this.time, runLevelTimeForever: !!this.tempData[0].check}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, [error.message]); this.$refs.noticeInfo.doShow({}, error.message);
}); });
} else { } else {
this.doClose(); this.doClose();

View File

@ -69,7 +69,7 @@
import { mouseCancelState } from '../utils/menuItemStatus'; import { mouseCancelState } from '../utils/menuItemStatus';
import NoticeInfo from './childDialog/childDialog/noticeInfo'; import NoticeInfo from './childDialog/childDialog/noticeInfo';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import {menuOperate, commitOperate} from '../utils/menuOperate';
export default { export default {
name: 'StandStopTime', name: 'StandStopTime',
@ -210,28 +210,13 @@ export default {
// }); // });
// }, // },
commit() { commit() {
const operate = {
send: true,
operation: OperationEvent.StationStand.setStopTime.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_PARK_TIME,
param: {
parkingTime: this.control == '01' ? -1 : 1,
parkingAlwaysValid: this.effective == '1'
}
// messages: [`: ${this.stationName} - ${this.standName}, ${this.control == '01' ? '' : this.time + ''}, ${this.effective == false ? '' : ''}`]
};
this.loading = true; this.loading = true;
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => { commitOperate(menuOperate.StationStand.setStopTime, {parkingTime: this.control == '01' ? -1 : 1, parkingAlwaysValid: this.effective == '1'}, 2).then((data)=>{
this.loading = false; this.doClose();
if (valid) {
this.doClose();
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
}
}).catch((error) => { }).catch((error) => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow(operate, [error.message]); this.$refs.noticeInfo.doShow({}, error.message);
}); });
}, },
cancel() { cancel() {

View File

@ -173,7 +173,7 @@ export default {
// }, // },
// //
faultUnlock(selectType) { faultUnlock(selectType) {
commitOperate(menuOperate.Section.fault, selectType, [selectType.code]).then((data)=>{ commitOperate(menuOperate.Section.fault, {sectionCode:selectType.code}, 0).then((data)=>{
this.$refs.sectionControl.doShow(data.operate, data.selected); this.$refs.sectionControl.doShow(data.operate, data.selected);
}); });
}, },

View File

@ -333,13 +333,7 @@ export default {
// //
arrangementRoute() { arrangementRoute() {
commitOperate(menuOperate.Signal.arrangementRoute, {signalCode:this.selected.code}, 0).then((data)=>{ commitOperate(menuOperate.Signal.arrangementRoute, {signalCode:this.selected.code}, 0).then((data)=>{
const routes = []; this.$refs.routeSelection.doShow(data.operate, this.selected, this.getRouteList(this.selected));
this.routeList.forEach(elem => {
if (elem.startSignalCode === this.selected.code) {
routes.push(elem);
}
});
this.$refs.routeSelection.doShow(data.operate, this.selected, routes);
}); });
}, },
// //
@ -399,25 +393,13 @@ export default {
// //
humanControl() { humanControl() {
commitOperate(menuOperate.Signal.humanControl, {signalCode:this.selected.code}, 0).then((data)=>{ commitOperate(menuOperate.Signal.humanControl, {signalCode:this.selected.code}, 0).then((data)=>{
const routes = []; this.$refs.routeHandControl.doShow(data.operate, this.selected, this.getRouteList(this.selected));
this.routeList.forEach(elem => {
if (elem.startSignalCode === this.selected.code) {
routes.push(elem);
}
});
this.$refs.routeHandControl.doShow(data.operate, this.selected, routes);
}); });
}, },
// //
atsAutoControl() { atsAutoControl() {
commitOperate(menuOperate.Signal.atsAutoControl, {signalCode:this.selected.code}, 0).then((data)=>{ commitOperate(menuOperate.Signal.atsAutoControl, {signalCode:this.selected.code}, 0).then((data)=>{
const routes = []; this.$refs.routeHandControl.doShow(data.operate, this.selected, this.getRouteList(this.selected));
this.routeList.forEach(elem => {
if (elem.startSignalCode === this.selected.code) {
routes.push(elem);
}
});
this.$refs.routeHandControl.doShow(data.operate, this.selected, routes);
}); });
}, },
// //
@ -437,15 +419,19 @@ export default {
// //
detail() { detail() {
commitOperate(menuOperate.Signal.detail, {signalCode:this.selected.code}, 0).then((data)=>{ commitOperate(menuOperate.Signal.detail, {signalCode:this.selected.code}, 0).then((data)=>{
const routes = []; this.$refs.routeDetail.doShow(data.operate, this.selected, this.getRouteList(this.selected));
this.routeList.forEach(elem => {
if (elem.startSignalCode === this.selected.code) {
routes.push(elem);
}
});
this.$refs.routeDetail.doShow(data.operate, this.selected, routes);
}); });
}, },
//
getRouteList(selectType) {
const routes = [];
this.routeList.forEach(elem => {
if (elem.startSignalCode === selectType.code) {
routes.push(elem);
}
});
return routes;
},
passWordCommit(data) { passWordCommit(data) {
const operate = { const operate = {
operation: data.operation, operation: data.operation,

View File

@ -27,6 +27,7 @@ import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import MenuContextHandler from '@/scripts/cmdPlugin/MenuContextHandler'; import MenuContextHandler from '@/scripts/cmdPlugin/MenuContextHandler';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import CMD from '@/scripts/cmdPlugin/CommandEnum';
import { mouseCancelState } from './utils/menuItemStatus'; import { mouseCancelState } from './utils/menuItemStatus';
import {menuOperate, commitOperate} from './utils/menuOperate';
export default { export default {
name: 'StationStandMenu', name: 'StationStandMenu',
@ -242,75 +243,28 @@ export default {
}, },
// //
setDetainTrainByLow(selectType) { setDetainTrainByLow(selectType) {
const operate = { commitOperate(menuOperate.StationStand.setDetainTrain, {standCode:selectType.code}, 3).then((data)=>{
start: true, }).catch(error=>{
operation: OperationEvent.StationStand.setDetainTrain.menu.operation, this.$refs.noticeInfo.doShow({}, error.message);
param:{
standCode:selectType.code
},
cmdType: CMD.Stand.CMD_STAND_SET_HOLD_TRAIN
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
}
}).catch(error => {
this.$refs.noticeInfo.doShow(operate, error.message);
}); });
}, },
/** 取消扣车 */ /** 取消扣车 */
cancleDetainTrainByLow(selectType) { cancleDetainTrainByLow(selectType) {
const operate = { commitOperate(menuOperate.StationStand.cancelDetainTrain, {standCode:selectType.code}, 3).then((data)=>{
start: true, }).catch(error=>{
over: true, this.$refs.noticeInfo.doShow({}, error.message);
operation: OperationEvent.StationStand.cancelDetainTrain.menu.operation,
param:{
standCode:selectType.code
},
cmdType: CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
}
}).catch(error => {
this.$refs.noticeInfo.doShow(operate, error.message);
}); });
}, },
// //
setDetainTrain() { setDetainTrain() {
const operate = { commitOperate(menuOperate.StationStand.setDetainTrain, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standControl.doShow(data.operate, this.selected);
code: this.selected.code,
operation: OperationEvent.StationStand.setDetainTrain.menu.operation,
param:{
standCode:this.selected.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standControl.doShow(operate, this.selected);
}
}); });
}, },
// //
cancelDetainTrain() { cancelDetainTrain() {
const operate = { commitOperate(menuOperate.StationStand.cancelDetainTrain, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standControl.doShow(data.operate, this.selected);
code: this.selected.code,
operation: OperationEvent.StationStand.cancelDetainTrain.menu.operation,
param:{
standCode:this.selected.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standControl.doShow(operate, this.selected);
}
}); });
}, },
// //
@ -331,131 +285,44 @@ export default {
// }, // },
// //
setJumpStop() { setJumpStop() {
const operate = { commitOperate(menuOperate.StationStand.setJumpStop, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standJumpStopControl.doShow(data.operate, this.selected);
code: `${this.selected.code}`,
operation: OperationEvent.StationStand.setJumpStop.menu.operation,
param:{
standCode:this.selected.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standJumpStopControl.doShow(operate, this.selected);
}
}); });
}, },
// //
cancelJumpStop() { cancelJumpStop() {
const operate = { commitOperate(menuOperate.StationStand.cancelJumpStop, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standJumpStopControl.doShow(data.operate, this.selected);
code: `${this.selected.code}`,
operation: OperationEvent.StationStand.cancelJumpStop.menu.operation,
param:{
standCode:this.selected.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standJumpStopControl.doShow(operate, this.selected);
}
}); });
}, },
// //
setStopTime() { setStopTime() {
const operate = { commitOperate(menuOperate.StationStand.setStopTime, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standStopTime.doShow(data.operate, this.selected, []);
code: this.selected.code,
operation: OperationEvent.StationStand.setStopTime.menu.operation,
param:{
standCode:this.selected.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
const tempData = [];
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standStopTime.doShow(operate, this.selected, tempData);
}
}).catch(() => {
this.$refs.noticeInfo.doShow(operate);
}); });
}, },
// //
setRunLevel() { setRunLevel() {
const operate = { commitOperate(menuOperate.StationStand.setRunLevel, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standRunLevel.doShow(data.operate, this.selected, []);
code: this.selected.code,
operation: OperationEvent.StationStand.setRunLevel.menu.operation,
param:{
standCode:this.selected.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
const tempData = [];
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standRunLevel.doShow(operate, this.selected, tempData);
}
}).catch(() => {
this.$refs.noticeInfo.doShow(operate);
}); });
}, },
// //
earlyDeparture() { earlyDeparture() {
const operate = { commitOperate(menuOperate.StationStand.earlyDeparture, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standControl.doShow(data.operate, this.selected);
code: `${this.selected.code}`,
operation: OperationEvent.StationStand.earlyDeparture.menu.operation,
param:{
standCode:this.selected.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standControl.doShow(operate, this.selected);
}
}); });
}, },
// //
setBackStrategy() { setBackStrategy() {
const operate = { commitOperate(menuOperate.StationStand.setBackStrategy, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standBackStrategy.doShow(data.operate, this.selected);
code: this.selected.code,
operation: OperationEvent.StationStand.setBackStrategy.menu.operation,
param:{
standCode:this.selected.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
const tempData = [];
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standBackStrategy.doShow(operate, this.selected, tempData);
}
}).catch(() => {
this.$refs.noticeInfo.doShow(operate);
}); });
}, },
// //
detail() { detail() {
const operate = { commitOperate(menuOperate.StationStand.detail, {standCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.standDetail.doShow(data.operate, this.selected, []);
code: this.selected.code,
operation: OperationEvent.StationStand.detail.menu.operation
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
const tempData = [];
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.standDetail.doShow(operate, this.selected, tempData);
}
}).catch(() => {
this.$refs.noticeInfo.doShow(operate);
}); });
} }
} }

View File

@ -23,6 +23,7 @@ import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import MenuContextHandler from '@/scripts/cmdPlugin/MenuContextHandler'; import MenuContextHandler from '@/scripts/cmdPlugin/MenuContextHandler';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import CMD from '@/scripts/cmdPlugin/CommandEnum';
import { mouseCancelState } from './utils/menuItemStatus'; import { mouseCancelState } from './utils/menuItemStatus';
import {menuOperate, commitOperate} from './utils/menuOperate';
export default { export default {
name: 'SwitchMenu', name: 'SwitchMenu',
@ -237,167 +238,63 @@ export default {
}, },
// //
lock(selectType) { lock(selectType) {
const operate = { commitOperate(menuOperate.Switch.lock, {switchCode:selectType.code}, 3).then((data)=>{
start: true, }).catch(error=>{
over: true, this.$refs.noticeInfo.doShow({}, error.message);
operation: OperationEvent.Switch.lock.menu.operation,
param: {
switchCode: selectType.code
},
cmdType: CMD.Switch.CMD_SWITCH_SINGLE_LOCK
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
}
}).catch(error => {
this.$refs.noticeInfo.doShow(operate, error.message);
}); });
}, },
// //
unlock(selectType) { unlock(selectType) {
const operate = { commitOperate(menuOperate.Switch.unlock, {switchCode:selectType.code}, 0).then((data)=>{
start: true, this.$refs.switchControl.doShow(data.operate, selectType);
code: this.selected.code, }).catch(error=>{
operation: OperationEvent.Switch.unlock.menu.operation, this.$refs.noticeInfo.doShow({}, error.message);
param: {
switchCode: selectType.code
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.switchControl.doShow(operate, selectType);
}
}).catch(error => {
this.$refs.noticeInfo.doShow(operate, error.message);
}); });
}, },
// //
switchTurnoutForce(selectType) { switchTurnoutForce(selectType) {
const operate = { commitOperate(menuOperate.Switch.turnoutForce, {switchCode:selectType.code}, 0).then((data)=>{
start: true, this.$refs.switchControl.doShow(data.operate, selectType);
code: this.selected.code, }).catch(error=>{
operation: OperationEvent.Switch.turnoutForce.menu.operation, this.$refs.noticeInfo.doShow({}, error.message);
param:{
switchCode:selectType.code
}
};
this.$store.dispatch('training/next', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.switchControl.doShow(operate, this.selected);
}
}); });
}, },
// //
locate(selectType) { locate(selectType) {
const operate = { commitOperate(menuOperate.Switch.locate, {switchCode:selectType.code}, 3).then((data)=>{
start: true, }).catch(error=>{
over: true, this.$refs.noticeInfo.doShow({}, error.message);
operation: OperationEvent.Switch.locate.menu.operation,
param: {
switchCode: selectType.code
},
cmdType: CMD.Switch.CMD_SWITCH_NORMAL_POSITION
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
}
}).catch(error => {
this.$refs.noticeInfo.doShow(operate, error.message);
}); });
}, },
// //
reverse(selectType) { reverse(selectType) {
const operate = { commitOperate(menuOperate.Switch.reverse, {switchCode:selectType.code}, 3).then((data)=>{
start: true, }).catch(error=>{
over: true, this.$refs.noticeInfo.doShow({}, error.message);
operation: OperationEvent.Switch.reverse.menu.operation,
param: {
switchCode: selectType.code
},
cmdType: CMD.Switch.CMD_SWITCH_REVERSE_POSITION
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
}
}).catch(error => {
this.$refs.noticeInfo.doShow(operate, error.message);
}); });
}, },
// //
split() { split() {
const operate = { commitOperate(menuOperate.Switch.split, {switchCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.switchControl.doShow(data.operate, this.selected);
code: this.selected.code,
operation: OperationEvent.Switch.split.menu.operation,
param: {
switchCode: `${this.selected.code}`
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.switchControl.doShow(operate, this.selected);
}
}); });
}, },
// //
active() { active() {
const operate = { commitOperate(menuOperate.Switch.active, {switchCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.switchControl.doShow(data.operate, this.selected);
code: this.selected.code,
operation: OperationEvent.Switch.active.menu.operation,
param: {
switchCode: `${this.selected.code}`
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.switchControl.doShow(operate, this.selected);
}
}); });
}, },
// //
setSpeed() { setSpeed() {
const operate = { commitOperate(menuOperate.Switch.setSpeed, {switchCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.speedLimitControl.doShow(data.operate, this.selected);
code: this.selected.code,
operation: OperationEvent.Switch.setSpeed.menu.operation,
param: {
switchCode: `${this.selected.code}`
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.speedLimitControl.doShow(operate, this.selected);
}
}); });
}, },
// //
alxeEffective() { alxeEffective() {
const operate = { commitOperate(menuOperate.Switch.alxeEffective, {switchCode:this.selected.code}, 0).then((data)=>{
start: true, this.$refs.alxeEffective.doShow(data.operate, this.selected);
code: this.selected.code,
operation: OperationEvent.Switch.alxeEffective.menu.operation,
param: {
switchCode: `${this.selected.code}`
}
};
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.alxeEffective.doShow(operate, this.selected);
}
}); });
}, },
undeveloped() { undeveloped() {

View File

@ -2,43 +2,37 @@ import store from '@/store';
import CMD from '@/scripts/cmdPlugin/CommandEnum'; import CMD from '@/scripts/cmdPlugin/CommandEnum';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
// 控制禁用 // 操作
export const menuOperate = { export const menuOperate = {
Section:{ Section:{
active:{ active:{
// 区段激活 // 区段激活
operation: OperationEvent.Section.active.menu.operation, operation: OperationEvent.Section.active.menu.operation,
param:['sectionCode'],
cmdType: CMD.Section.CMD_SECTION_ACTIVE cmdType: CMD.Section.CMD_SECTION_ACTIVE
}, },
alxeEffective:{ alxeEffective:{
// 确认计轴有效 // 确认计轴有效
operation: OperationEvent.Section.alxeEffective.menu.operation, operation: OperationEvent.Section.alxeEffective.menu.operation,
param:['sectionCode'],
cmdType: CMD.Section.CMD_SECTION_COMFIRMATION_AXLE cmdType: CMD.Section.CMD_SECTION_COMFIRMATION_AXLE
}, },
split:{ split:{
// 区段切除 // 区段切除
operation: OperationEvent.Section.split.menu.operation, operation: OperationEvent.Section.split.menu.operation,
param:['sectionCode'],
cmdType: CMD.Section.CMD_SECTION_CUT_OFF cmdType: CMD.Section.CMD_SECTION_CUT_OFF
}, },
setSpeed:{ setSpeed:{
// 设置速度 // 设置速度
operation: OperationEvent.Section.setSpeed.menu.operation, operation: OperationEvent.Section.setSpeed.menu.operation,
param:['sectionCode'],
cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED
}, },
axlePreReset:{ axlePreReset:{
// 区段计轴预复位 // 区段计轴预复位
operation: OperationEvent.Section.axlePreReset.menu.operation, operation: OperationEvent.Section.axlePreReset.menu.operation,
param:['sectionCode'],
cmdType: CMD.Section.CMD_SECTION_AXIS_PRE_RESET cmdType: CMD.Section.CMD_SECTION_AXIS_PRE_RESET
}, },
fault:{ fault:{
// 区段故障解锁 // 区段故障解锁
operation: OperationEvent.Section.fault.menu.operation, operation: OperationEvent.Section.fault.menu.operation,
param:['sectionCode'],
cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK
} }
}, },
@ -92,6 +86,100 @@ export const menuOperate = {
// 查询进路状态 // 查询进路状态
operation: OperationEvent.Signal.detail.menu.operation operation: OperationEvent.Signal.detail.menu.operation
} }
},
Switch:{
lock:{
// 道岔单锁
operation: OperationEvent.Switch.lock.menu.operation,
cmdType: CMD.Switch.CMD_SWITCH_SINGLE_LOCK
},
unlock:{
// 道岔解锁
operation: OperationEvent.Switch.unlock.menu.operation,
cmdType: CMD.Switch.CMD_SWITCH_SINGLE_UNLOCK
},
turnoutForce:{
// 道岔强扳
operation: OperationEvent.Switch.turnoutForce.menu.operation
},
locate:{
// 单操到定位
operation: OperationEvent.Switch.locate.menu.operation,
cmdType: CMD.Switch.CMD_SWITCH_NORMAL_POSITION
},
reverse:{
// 单操到反位
operation: OperationEvent.Switch.reverse.menu.operation,
cmdType: CMD.Switch.CMD_SWITCH_REVERSE_POSITION
},
split:{
// 区段切除
operation: OperationEvent.Switch.split.menu.operation,
cmdType: CMD.Switch.CMD_SWITCH_CUT_OFF
},
active:{
// 区段激活
operation: OperationEvent.Switch.active.menu.operation,
cmdType: CMD.Switch.CMD_SWITCH_ACTIVE
},
setSpeed:{
// 设置临时限速
operation: OperationEvent.Switch.setSpeed.menu.operation,
cmdType:CMD.Switch.CMD_SWITCH_SET_LIMIT_SPEED
},
alxeEffective:{
// 确认计轴有效
operation: OperationEvent.Switch.alxeEffective.menu.operation,
cmdType: CMD.Switch.CMD_SWITCH_COMFIRMATION_AXLE
}
},
StationStand:{
setDetainTrain:{
// 设置扣车
operation: OperationEvent.StationStand.setDetainTrain.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_HOLD_TRAIN
},
cancelDetainTrain:{
// 取消扣车
operation: OperationEvent.StationStand.cancelDetainTrain.menu.operation,
cmdType: CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN
},
setJumpStop:{
// 设置跳停
operation: OperationEvent.StationStand.setJumpStop.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_JUMP_STOP
},
cancelJumpStop:{
// 取消跳停
operation: OperationEvent.StationStand.cancelJumpStop.menu.operation,
cmdType: CMD.Stand.CMD_STAND_CANCEL_JUMP_STOP
},
setStopTime:{
// 停站时间控制
operation: OperationEvent.StationStand.setStopTime.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_PARK_TIME
},
setRunLevel:{
// 运行时间控制
operation: OperationEvent.StationStand.setRunLevel.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_RUN_TIME
},
earlyDeparture:{
// 设置提前发车
operation: OperationEvent.StationStand.earlyDeparture.menu.operation,
cmdType: CMD.Stand.CMD_STAND_EARLY_DEPART
},
setBackStrategy:{
// 设置折返策略
operation: OperationEvent.StationStand.setBackStrategy.menu.operation,
cmdType: CMD.Stand.CMD_STAND_SET_REENTRY_STRATEGY
},
detail:{
// 查询站台状态
operation: OperationEvent.StationStand.detail.menu.operation
}
} }
}; };
@ -102,8 +190,8 @@ export function commitOperate(operate, paramList, over) {
param:{} param:{}
}; };
step.param = paramList; step.param = paramList;
// isOnce 0为首次操作1为中间操作2为最后操作3为直接一次性操作 // over 0为首次操作1为中间操作2为最后操作3为直接一次性操作
if (over != 0) { if (over != 0 && over != 3) {
delete step.start; delete step.start;
} }
if (over == 2 || over == 3) { if (over == 2 || over == 3) {

View File

@ -39,7 +39,7 @@
<div v-if="scope.$index == 9" class="table-9-top">状态比较</div> <div v-if="scope.$index == 9" class="table-9-top">状态比较</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="province" width="120"> <el-table-column prop="code" width="120">
<template slot="header"> <template slot="header">
<div style="width: 100%">模式</div> <div style="width: 100%">模式</div>
<div style="width: 100%">编号</div> <div style="width: 100%">编号</div>
@ -47,31 +47,31 @@
</el-table-column> </el-table-column>
<el-table-column label="大系统模式表"> <el-table-column label="大系统模式表">
<el-table-column label="新风机"> <el-table-column label="新风机">
<el-table-column prop="province" label="FAF-1" width="120" /> <el-table-column prop="faf1" label="FAF-1" width="120" />
<el-table-column prop="city" label="FAF-2" width="120" /> <el-table-column prop="faf2" label="FAF-2" width="120" />
</el-table-column> </el-table-column>
<el-table-column label="组合式空调器"> <el-table-column label="组合式空调器">
<el-table-column prop="province" label="AHU-1" width="120" /> <el-table-column prop="ahu1" label="AHU-1" width="120" />
<el-table-column prop="city" label="AHU-2" width="120" /> <el-table-column prop="ahu2" label="AHU-2" width="120" />
</el-table-column> </el-table-column>
<el-table-column label="回排风机"> <el-table-column label="回排风机">
<el-table-column prop="province" label="RAF/SEF-1" width="120" /> <el-table-column prop="raf1" label="RAF/SEF-1" width="120" />
<el-table-column prop="city" label="RAF/SEF-2" width="120" /> <el-table-column prop="raf2" label="RAF/SEF-2" width="120" />
</el-table-column> </el-table-column>
<el-table-column label="风机1"> <el-table-column label="风机1">
<el-table-column prop="province" label="MD-1" width="120" /> <el-table-column prop="md1" label="MD-1" width="120" />
<el-table-column prop="province" label="MD-2" width="120" /> <el-table-column prop="md1" label="MD-2" width="120" />
<el-table-column prop="province" label="MD-3" width="120" /> <el-table-column prop="md1" label="MD-3" width="120" />
<el-table-column prop="province" label="MD-4" width="120" /> <el-table-column prop="md1" label="MD-4" width="120" />
<el-table-column prop="province" label="MD-5" width="120" /> <el-table-column prop="md1" label="MD-5" width="120" />
<el-table-column prop="province" label="MD-6" width="120" /> <el-table-column prop="md1" label="MD-6" width="120" />
<el-table-column prop="province" label="MD-7" width="120" /> <el-table-column prop="md1" label="MD-7" width="120" />
<el-table-column prop="province" label="MD-8" width="120" /> <el-table-column prop="md1" label="MD-8" width="120" />
<el-table-column prop="province" label="MD-9" width="120" /> <el-table-column prop="md1" label="MD-9" width="120" />
<el-table-column prop="province" label="MD-10" width="120" /> <el-table-column prop="md1" label="MD-10" width="120" />
<el-table-column prop="province" label="MD-11" width="120" /> <el-table-column prop="md1" label="MD-11" width="120" />
<el-table-column prop="province" label="MD-12" width="120" /> <el-table-column prop="md1" label="MD-12" width="120" />
<el-table-column prop="province" label="MD-13" width="120" /> <el-table-column prop="md1" label="MD-13" width="120" />
</el-table-column> </el-table-column>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -107,65 +107,95 @@ export default {
tableTitleStyle: 'text-align: center; height: 28px; padding: 0;background: #45607B;', tableTitleStyle: 'text-align: center; height: 28px; padding: 0;background: #45607B;',
rowStyle: 'text-align: center;height: 28px; padding: 0; background: #45607B;', rowStyle: 'text-align: center;height: 28px; padding: 0; background: #45607B;',
tableData: [{ tableData: [{
date: '2016-05-03', code: '101',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '打开',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '关闭'
}, { }, {
date: '2016-05-02', code: '102',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '打开',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '打开'
}, { }, {
date: '2016-05-04', code: '103',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '打开',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '关闭'
}, { }, {
date: '2016-05-01', code: '104',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '关闭',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '打开'
}, { }, {
date: '2016-05-08', code: '105',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '打开',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '关闭'
}, { }, {
date: '2016-05-06', code: '106',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '关闭',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '打开'
}, { }, {
date: '2016-05-07', code: '107',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '打开',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '打开'
}, { }, {
date: '2016-05-07', code: '108',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '关闭',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '打开'
}, { }, {
date: '2016-05-07', code: '',
name: '王小虎', faf1: '打开',
province: '上海', faf2: '打开',
city: '普陀区', ahu1: '打开',
zip: 200333 ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '打开'
}, { }, {
date: '', code: '',
name: '', faf1: '打开',
province: '', faf2: '打开',
city: '', ahu1: '打开',
zip: '' ahu2: '打开',
raf1: '打开',
raf2: '打开',
md1: '打开'
}] }]
}; };
}, },

View File

@ -1,82 +1,93 @@
<template> <template>
<div> <div>
<div style="position: absolute; left: 48%; top: 15%;font-size: 20px;color: #9EEBEF;">语音广播</div> <div style="margin: 20px auto 0;text-align: center;font-size: 20px;color: #9EEBEF;">语音广播</div>
<div class="area-selection"> <div style="overflow: hidden;">
<el-row><div style="margin-top: 10px;margin-bottom: 5px; color: #9EEBEF;">特定区域</div></el-row> <div class="area-selection">
<el-row><div class="area-selection-button" @click="selectedAll">全线</div></el-row> <el-row><div style="margin-top: 10px;margin-bottom: 5px; color: #9EEBEF;">特定区域</div></el-row>
<el-row><div class="area-selection-button" @click="selectedBatch('站厅')">全站厅</div></el-row> <el-row><div class="area-selection-button" @click="selectedAll">全线</div></el-row>
<el-row><div class="area-selection-button" @click="selectedBatch('上行站台')">全上行站台</div></el-row> <el-row><div class="area-selection-button" @click="selectedBatch('站厅')">全站厅</div></el-row>
<el-row><div class="area-selection-button" @click="selectedBatch('下行站台')">全下行站台</div></el-row> <el-row><div class="area-selection-button" @click="selectedBatch('上行站台')">全上行站台</div></el-row>
<el-row><div class="area-selection-button" @click="selectedBatch('办公区')">全办公区</div></el-row> <el-row><div class="area-selection-button" @click="selectedBatch('下行站台')">全下行站台</div></el-row>
<el-row><div class="area-selection-button" @click="selectedBatch('出入口')">全出入口</div></el-row> <el-row><div class="area-selection-button" @click="selectedBatch('办公区')">全办公区</div></el-row>
<el-row><div class="area-selection-button" @click="selectedBatch('换乘通道')">全换乘通道</div></el-row> <el-row><div class="area-selection-button" @click="selectedBatch('出入口')">全出入口</div></el-row>
</div> <el-row><div class="area-selection-button" @click="selectedBatch('换乘通道')">全换乘通道</div></el-row>
<div class="broadcast-form"> </div>
<div v-for="(item,i) in verticalHeader" :key="i" :style="{width: tableWidth+'px'}" class="iscs-pa-table"> <div class="broadcast-form">
<div class="left-header">{{ item.name }}</div> <div style="width: 120px; height: 300px; float: left; position: absolute; top: 20px;">
<div style="position: relative; left: 5%;"> <div v-for="(item,i) in verticalHeader" :key="i" :style="{top: i * 31.5 +'px'}" class="left-header">{{ item.name }}</div>
<div v-for="(it, j) in stationList" :key="j" class="table-grid"> </div>
<div v-if="item.type==='header'" class="pa-table-header" @click="selectedStation(it)"> <div style="float: left; overflow-x: auto; width: 100%; height: 314px;">
<div style="cursor: default;">{{ it }}</div> <div v-for="(item,i) in verticalHeader" :key="i" :style="{width: tableWidth+'px'}" class="iscs-pa-table">
</div> <div style="position: relative; left: 80px;">
<div v-else> <div v-for="(it, j) in stationList" :key="j" class="table-grid">
<div class="pa-table-content" @click="clickArea(i,j)"> <div v-if="item.type==='header'" class="pa-table-header" @click="selectedStation(it)">
<div class="pa-table-content-inside" :style="{background: selectedAreaList.includes(i + '-' + j)? '#2EFF74':'#CDCDCD'}" /> <div style="cursor: default;">{{ it }}</div>
</div>
<div v-else>
<div class="pa-table-content" @click="clickArea(i,j)">
<div class="pa-table-content-inside" :style="{background: selectedAreaList.includes(i + '-' + j)? '#2EFF74':'#CDCDCD'}" />
</div>
<div style="display: inline-block;margin-left: 5px;height: 18px;line-height: 18px;transform: translateY(-25%);color: #192780;">0</div>
</div>
</div> </div>
<div style="display: inline-block;margin-left: 5px;height: 18px;line-height: 18px;transform: translateY(-25%);color: #192780;">0</div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<div style="float: right; width: 11%; margin-right: 1%;margin-top: 63px;">
<div class="broadcast-mode">
<el-row>
<el-col :span="12"><div style="height: 40px;text-align: center; background: #000088;color: #fff;line-height: 40px">实时广播</div></el-col>
<el-col :span="12"><div class="broadcast-mode-button">广播</div></el-col>
</el-row>
</div>
<div class="broadcast-operations">
<el-row>
<el-col :span="12"><div style="height: 80px;text-align: center; background: #000088;color: #fff;padding-top: 30px">预备<br>广播</div></el-col>
<el-col :span="12">
<div class="broadcast-mode-button" @click="selectedVideoMode('common')">
<div class="pa-check-box" :style="{background: videoMode==='common'?'#2EFF74':'#CDCDCD'}" />
<div style="position: relative; left: 5px;display: inline-block;">普通预录</div>
</div>
<br>
<div class="broadcast-mode-button" @click="selectedVideoMode('emergency')">
<div class="pa-check-box" :style="{background: videoMode==='emergency'?'#2EFF74':'#CDCDCD'}" />
<div style="position: relative; left: 5px;display: inline-block; color: #f00;">紧急预录</div>
</div>
</el-col>
</el-row>
<el-row style="padding-bottom: 10px">
<el-col :span="12">
<div class="broadcast-mode-button" @click="showBroadcastContent">广播内容</div>
</el-col>
<el-col :span="12">
<div class="broadcast-mode-button">广播停止</div>
</el-col>
</el-row>
</div>
<div class="background-music">
<el-row>
<el-col :span="12"><div style="height: 40px;text-align: center; background: #000088;color: #fff;line-height: 40px">背景音乐</div></el-col>
</el-row>
<el-row style="padding-bottom: 10px">
<el-col :span="12"><div class="broadcast-mode-button">播放音乐</div></el-col>
<el-col :span="12"><div class="broadcast-mode-button">停止音乐</div></el-col>
</el-row>
</div>
</div>
</div> </div>
<div class="broadcast-mode"> <div>
<el-row> <div class="pa-grey-box" />
<el-col :span="12"><div style="height: 40px;text-align: center; background: #000088;color: #fff;line-height: 40px">实时广播</div></el-col> <div class="pa-statements">
<el-col :span="12"><div class="broadcast-mode-button">广播</div></el-col> <state-table />
</el-row> </div>
</div>
<div class="broadcast-operations">
<el-row>
<el-col :span="12"><div style="height: 80px;text-align: center; background: #000088;color: #fff;padding-top: 30px">预备<br>广播</div></el-col>
<el-col :span="12">
<div class="broadcast-mode-button" @click="selectedVideoMode('common')">
<div class="pa-check-box" :style="{background: videoMode==='common'?'#2EFF74':'#CDCDCD'}" />
<div style="position: relative; left: 5px;display: inline-block;">普通预录</div>
</div>
<br>
<div class="broadcast-mode-button" @click="selectedVideoMode('emergency')">
<div class="pa-check-box" :style="{background: videoMode==='emergency'?'#2EFF74':'#CDCDCD'}" />
<div style="position: relative; left: 5px;display: inline-block; color: #f00;">紧急预录</div>
</div>
</el-col>
</el-row>
<el-row style="padding-bottom: 10px">
<el-col :span="12">
<div class="broadcast-mode-button" @click="showBroadcastContent">广播内容</div>
</el-col>
<el-col :span="12">
<div class="broadcast-mode-button">广播停止</div>
</el-col>
</el-row>
</div>
<div class="background-music">
<el-row>
<el-col :span="12"><div style="height: 40px;text-align: center; background: #000088;color: #fff;line-height: 40px">背景音乐</div></el-col>
</el-row>
<el-row style="padding-bottom: 10px">
<el-col :span="12"><div class="broadcast-mode-button">播放音乐</div></el-col>
<el-col :span="12"><div class="broadcast-mode-button">停止音乐</div></el-col>
</el-row>
</div>
<div class="pa-grey-box" />
<div class="pa-statements">
<state-table />
</div> </div>
<voice-broadcast ref="voiceBroadcast" /> <voice-broadcast ref="voiceBroadcast" />
</div> </div>
</template> </template>
<script> <script>
import { getByGroupStationList } from '@/api/jmap/map';
import MusicIcon from '@/assets/iscs_icon/music_icon.png'; import MusicIcon from '@/assets/iscs_icon/music_icon.png';
import StateTable from './stateTable'; import StateTable from './stateTable';
import VoiceBroadcast from './voiceBroadcast'; import VoiceBroadcast from './voiceBroadcast';
@ -100,7 +111,7 @@ export default {
], ],
musicIcon: MusicIcon, musicIcon: MusicIcon,
selectedAreaList: [], selectedAreaList: [],
stationList: ['会展中心站', '世纪大道站', '交通大学站', '市图书馆站', '中心医院站', '未来路站', '火车站', '人民广场站', '体育中心站'], stationList: [],
videoMode: 'common' videoMode: 'common'
}; };
}, },
@ -109,6 +120,18 @@ export default {
return this.stationList.length * 120 + 80; return this.stationList.length * 120 + 80;
} }
}, },
async created () {
// 线
const res = await getByGroupStationList(this.$route.query.group);
if (res.code == 200) {
this.stationList = [];
res.data.forEach(station => {
if (!station.depot) {
this.stationList.push(station.name);
}
});
}
},
methods: { methods: {
clickArea(i, j) { clickArea(i, j) {
if (this.selectedAreaList.includes(i + '-' + j)) { if (this.selectedAreaList.includes(i + '-' + j)) {
@ -210,9 +233,9 @@ export default {
border-right: 3px solid #fff; border-right: 3px solid #fff;
border-bottom: 3px solid #fff; border-bottom: 3px solid #fff;
width: 5%; width: 5%;
position: absolute; float: left;
top: 200px; margin-top: 63px;
left: 1%; margin-left: 1%;
} }
.area-selection-button{ .area-selection-button{
width: 90%; width: 90%;
@ -242,12 +265,13 @@ export default {
border-right: 3px solid #fff; border-right: 3px solid #fff;
border-bottom: 3px solid #fff; border-bottom: 3px solid #fff;
width: 80%; width: 80%;
height: 40%; height: 340px;
top: 200px; margin-left: 10px;
position: absolute; float: left;
left: 7%; margin-top: 63px;
overflow-x: auto; overflow-x: auto;
padding-top: 20px; padding-top: 20px;
position: relative;
} }
.table-grid{ .table-grid{
width: 120px; width: 120px;
@ -258,14 +282,15 @@ export default {
} }
.left-header{ .left-header{
width: 120px; width: 120px;
height: 30px; height: 32px;
display: inline-block; display: inline-block;
padding-left: 20px; padding-left: 20px;
font-size: 14px; font-size: 14px;
text-align: left; text-align: left;
color: #A2E8EB; color: #A2E8EB;
position:fixed; position: absolute;
left: 7.15%; top: 0;
left: 0;
background: #45607B; background: #45607B;
z-index: 10; z-index: 10;
} }
@ -309,11 +334,12 @@ export default {
border-bottom: 2px solid #898888; border-bottom: 2px solid #898888;
} }
.pa-grey-box{ .pa-grey-box{
position: absolute; float: left;
left: 4%; margin-left: 5%;
top: 64%; margin-top: 10px;
width: 81%; top: 500px;
height: 30%; width: 78%;
height: 240px;
background: #DDDDDD; background: #DDDDDD;
border-top: 3px solid #898888; border-top: 3px solid #898888;
border-left: 3px solid #898888; border-left: 3px solid #898888;
@ -321,24 +347,21 @@ export default {
border-bottom: 3px solid #fff; border-bottom: 3px solid #fff;
} }
.pa-statements{ .pa-statements{
position: absolute; float: right;
left: 86%; margin-right: 1%;
top: 64%; margin-top: 50px;
width: 13%; width: 15%;
height: 30%; height: 30%;
font-size: 12px; font-size: 12px;
color: #fff; color: #fff;
} }
.broadcast-mode{ .broadcast-mode{
position: absolute;
left: 88%;
top: 25%;
border-top: 3px solid #898888; border-top: 3px solid #898888;
border-left: 3px solid #898888; border-left: 3px solid #898888;
border-right: 3px solid #fff; border-right: 3px solid #fff;
border-bottom: 3px solid #fff; border-bottom: 3px solid #fff;
width: 11%;
font-size: 12px; font-size: 12px;
margin-bottom: 13px;
} }
.broadcast-mode-button{ .broadcast-mode-button{
height: 30px; height: 30px;
@ -364,16 +387,13 @@ export default {
} }
} }
.broadcast-operations{ .broadcast-operations{
position: absolute;
left: 88%;
top: 32%;
border-top: 3px solid #898888; border-top: 3px solid #898888;
border-left: 3px solid #898888; border-left: 3px solid #898888;
border-right: 3px solid #fff; border-right: 3px solid #fff;
border-bottom: 3px solid #fff; border-bottom: 3px solid #fff;
width: 11%;
font-size: 12px; font-size: 12px;
background: #778899; background: #778899;
margin-bottom: 13px;
} }
.pa-check-box{ .pa-check-box{
position: relative; position: relative;
@ -388,14 +408,10 @@ export default {
border-bottom: 2px solid #fff; border-bottom: 2px solid #fff;
} }
.background-music{ .background-music{
position: absolute;
left: 88%;
top: 48%;
border-top: 3px solid #898888; border-top: 3px solid #898888;
border-left: 3px solid #898888; border-left: 3px solid #898888;
border-right: 3px solid #fff; border-right: 3px solid #fff;
border-bottom: 3px solid #fff; border-bottom: 3px solid #fff;
width: 11%;
font-size: 12px; font-size: 12px;
background: #778899; background: #778899;
} }

View File

@ -1,5 +1,5 @@
<template> <template>
<div> <div style="height: 100%; overflow-y: auto;">
<center-home v-if="currentSystem === 'center'" /> <center-home v-if="currentSystem === 'center'" />
<station-home v-else-if="currentSystem === 'local'" /> <station-home v-else-if="currentSystem === 'local'" />
</div> </div>

View File

@ -11,7 +11,7 @@
<emergency-release v-else-if="mode === 'EmergencyRelease'" /> <emergency-release v-else-if="mode === 'EmergencyRelease'" />
<controlBAS v-else-if="mode === 'controlBAS'" /> <controlBAS v-else-if="mode === 'controlBAS'" />
<controlPermissionBAS v-else-if="mode === 'controlPermissionBAS'" /> <controlPermissionBAS v-else-if="mode === 'controlPermissionBAS'" />
<mainScreenPA v-else-if="mode === 'mainScreenPA'" /> <!-- <mainScreenPA v-else-if="mode === 'mainScreenPA'" /> -->
<radioListeningPA v-else-if="mode === 'radioListeningPA'" /> <radioListeningPA v-else-if="mode === 'radioListeningPA'" />
<timePreviewPA v-else-if="mode === 'timePreviewPA'" /> <timePreviewPA v-else-if="mode === 'timePreviewPA'" />
<controlCCTV v-else-if="mode === 'controlCCTV'" /> <controlCCTV v-else-if="mode === 'controlCCTV'" />
@ -39,7 +39,7 @@ import StationNetwork from './pis/stationNetwork';
import EmergencyRelease from './pis/emergencyRelease'; import EmergencyRelease from './pis/emergencyRelease';
import controlBAS from './bas/controlBAS'; import controlBAS from './bas/controlBAS';
import controlPermissionBAS from './bas/controlPermissionBAS'; import controlPermissionBAS from './bas/controlPermissionBAS';
import mainScreenPA from './pa/mainScreenPA'; // import mainScreenPA from './pa/mainScreenPA';
import radioListeningPA from './pa/radioListeningPA'; import radioListeningPA from './pa/radioListeningPA';
import timePreviewPA from './pa/timePreviewPA'; import timePreviewPA from './pa/timePreviewPA';
import controlCCTV from './cctv/controlCCTV'; import controlCCTV from './cctv/controlCCTV';
@ -66,7 +66,7 @@ export default {
EmergencyRelease, EmergencyRelease,
controlBAS, controlBAS,
controlPermissionBAS, controlPermissionBAS,
mainScreenPA, // mainScreenPA,
radioListeningPA, radioListeningPA,
timePreviewPA, timePreviewPA,
controlCCTV, controlCCTV,

View File

@ -84,6 +84,7 @@
</div> </div>
</template> </template>
<script> <script>
import { getByGroupStationList } from '@/api/jmap/map';
import InfoBroadcast from './infoBroadcast'; import InfoBroadcast from './infoBroadcast';
export default { export default {
name:'MainScreen', name:'MainScreen',
@ -92,92 +93,31 @@ export default {
}, },
data() { data() {
return { return {
stationList:[ stationList:[],
{
stationName:'会展中心站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
},
{
stationName:'世纪大道站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
},
{
stationName:'交通大学站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
},
{
stationName:'市图书馆站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
},
{
stationName:'中心医院站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
},
{
stationName:'未来路站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
},
{
stationName:'火车站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
},
{
stationName:'人民广场站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
},
{
stationName:'体育中心站',
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
}
],
selectedAreaList: [] selectedAreaList: []
}; };
}, },
async created () {
// 线
const res = await getByGroupStationList(this.$route.query.group);
if (res.code == 200) {
this.stationList = [];
res.data.forEach(station => {
if (!station.depot) {
const param = {
stationName: station.name,
children:[
{status:'none'}, {status:'default'},
{status:'default'}, {status:'default'},
{status:'none'}, {status:'none'},
{status:'none'}, {status:'default'}
]
};
this.stationList.push(param);
}
});
}
},
methods:{ methods:{
showInfoBrroadcast() { showInfoBrroadcast() {
this.$refs.infoBroadcast.doShow(); this.$refs.infoBroadcast.doShow();
@ -318,7 +258,7 @@ border-top: 2px solid #8c8a89;border-left: 2px solid #8c8a89;border-right: 2px s
vertical-align: top; vertical-align: top;
} }
.screen_status_active::after{content:'';border-top: 2px solid #a6a2a6;border-left: 2px solid #a5aca5;border-right: 2px solid #ececec;border-bottom: 2px solid #e4e4e4;background: #00ff00;min-width: 10px;height: 10px;display: inline-block;vertical-align: top;} .screen_status_active::after{content:'';border-top: 2px solid #a6a2a6;border-left: 2px solid #a5aca5;border-right: 2px solid #ececec;border-bottom: 2px solid #e4e4e4;background: #00ff00;min-width: 10px;height: 10px;display: inline-block;vertical-align: top;}
.screen_left_text_group{width:180px;padding: 0px 10px 10px 10px;font-size: 14px;color: #9de4e8;display: inline-block;} .screen_left_text_group{width:210px;padding: 0px 10px 10px 10px;font-size: 14px;color: #9de4e8;display: inline-block;}
.each_data_info{margin-top:10px;height:20px;} .each_data_info{margin-top:10px;height:20px;}
.screen_right_group{display: inline-block;vertical-align: top;font-size:0;overflow-x: auto;min-height:100%;} .screen_right_group{display: inline-block;vertical-align: top;font-size:0;overflow-x: auto;min-height:100%;}
.each_station_info{width:130px;display: inline-block;vertical-align:top;padding-right: 10px;} .each_station_info{width:130px;display: inline-block;vertical-align:top;padding-right: 10px;}