Merge branch 'test' of https://git.code.tencent.com/lian-cbtc/jl-client into test
This commit is contained in:
commit
e7d5a85b4f
@ -414,8 +414,9 @@ class SkinCode extends defaultStyle {
|
|||||||
position: 1, // 扣车标识在站台上显示方向
|
position: 1, // 扣车标识在站台上显示方向
|
||||||
text: 'H', // 扣车显示内容
|
text: 'H', // 扣车显示内容
|
||||||
offset: { x: -8, y: 10 }, // 扣车偏移量
|
offset: { x: -8, y: 10 }, // 扣车偏移量
|
||||||
centerTrainColor: '#00FF00', // 中心扣车颜色
|
centerTrainColor: ['#FFFF00', '#0000FF'], // 中心扣车颜色
|
||||||
andCenterTrainColor: '#00FF00', // 车站+中心扣车颜色
|
localTrainColor: ['#FFFF00', '#0000FF'], // 车站扣车颜色
|
||||||
|
andCenterTrainColor: ['#FFFF00', '#0000FF'], // 车站+中心扣车颜色
|
||||||
detainTrainTextColor: '#FFFF00', // 车站扣除文字颜色
|
detainTrainTextColor: '#FFFF00', // 车站扣除文字颜色
|
||||||
spareStrokeColor: '#000000', // 扣车描边颜色
|
spareStrokeColor: '#000000', // 扣车描边颜色
|
||||||
lineWidth: 3, // 扣车线宽
|
lineWidth: 3, // 扣车线宽
|
||||||
@ -566,7 +567,7 @@ class SkinCode extends defaultStyle {
|
|||||||
|
|
||||||
this[deviceType.ZcControl] = {
|
this[deviceType.ZcControl] = {
|
||||||
// 是否显示
|
// 是否显示
|
||||||
visible: true,
|
visible: false,
|
||||||
text: {
|
text: {
|
||||||
fontSize: 11, // 字体大小
|
fontSize: 11, // 字体大小
|
||||||
fontWeight: 'normal', // 字体粗细
|
fontWeight: 'normal', // 字体粗细
|
||||||
|
@ -15,22 +15,27 @@ class EDetainCircle extends Group {
|
|||||||
const standX = model.position.x - model.width / 2;
|
const standX = model.position.x - model.width / 2;
|
||||||
const standY = model.position.y - model.height / 2;
|
const standY = model.position.y - model.height / 2;
|
||||||
|
|
||||||
let y;
|
let y1;
|
||||||
|
let y2;
|
||||||
if (model.right && model.inside) {
|
if (model.right && model.inside) {
|
||||||
y = standY + model.height / 2;
|
y1 = standY + model.height / 2;
|
||||||
|
y2 = standY;
|
||||||
} else if (model.right && !model.inside) {
|
} else if (model.right && !model.inside) {
|
||||||
y = standY;
|
y1 = standY;
|
||||||
|
y2 = standY + model.height / 2;
|
||||||
} else if (!model.right && model.inside) {
|
} else if (!model.right && model.inside) {
|
||||||
y = standY;
|
y1 = standY;
|
||||||
|
y2 = standY + model.height / 2;
|
||||||
} else if (!model.right && !model.inside) {
|
} else if (!model.right && !model.inside) {
|
||||||
y = standY + model.height / 2;
|
y1 = standY + model.height / 2;
|
||||||
|
y2 = standY;
|
||||||
}
|
}
|
||||||
this.detainRect = new Rect({
|
this.detainRectTop = new Rect({
|
||||||
zlevel: this.model.zlevel,
|
zlevel: this.model.zlevel,
|
||||||
z: this.model.z + 1,
|
z: this.model.z + 1,
|
||||||
shape: {
|
shape: {
|
||||||
x: standX,
|
x: standX,
|
||||||
y: y,
|
y: y1,
|
||||||
width: model.width,
|
width: model.width,
|
||||||
height: model.height / 2
|
height: model.height / 2
|
||||||
},
|
},
|
||||||
@ -40,18 +45,38 @@ class EDetainCircle extends Group {
|
|||||||
fill: '#000'
|
fill: '#000'
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.add(this.detainRect);
|
this.detainRectBottom = new Rect({
|
||||||
this.detainRect.hide();
|
zlevel: this.model.zlevel,
|
||||||
|
z: this.model.z + 1,
|
||||||
|
shape: {
|
||||||
|
x: standX,
|
||||||
|
y: y2,
|
||||||
|
width: model.width,
|
||||||
|
height: model.height / 2
|
||||||
|
},
|
||||||
|
style: {
|
||||||
|
lineWidth: style.StationStand.detainRect.lineWidth || 0,
|
||||||
|
stroke: style.StationStand.detainRect.spareStrokeColor,
|
||||||
|
fill: '#000'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
this.add(this.detainRectTop);
|
||||||
|
this.add(this.detainRectBottom);
|
||||||
|
this.detainRectTop.hide();
|
||||||
|
this.detainRectBottom.hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
setColor(color) {
|
setColor(color1, color2) {
|
||||||
this.detainRect.setStyle('stroke', color);
|
this.detainRectTop.setStyle('fill', color1);
|
||||||
|
this.detainRectBottom.setStyle('fill', color2);
|
||||||
}
|
}
|
||||||
setShow() {
|
setShow() {
|
||||||
this.detainRect.show();
|
this.detainRectTop.show();
|
||||||
|
this.detainRectBottom.show();
|
||||||
}
|
}
|
||||||
setHide() {
|
setHide() {
|
||||||
this.detainRect.hide();
|
this.detainRectTop.hide();
|
||||||
|
this.detainRectBottom.hide();
|
||||||
}
|
}
|
||||||
recover() {
|
recover() {
|
||||||
this.setHide();
|
this.setHide();
|
||||||
@ -61,14 +86,14 @@ class EDetainCircle extends Group {
|
|||||||
const style = this.model.style;
|
const style = this.model.style;
|
||||||
/** 设置扣车*/
|
/** 设置扣车*/
|
||||||
if (model.stationHoldTrain && model.centerHoldTrain) {
|
if (model.stationHoldTrain && model.centerHoldTrain) {
|
||||||
this.showMode();
|
this.setShow();
|
||||||
this.setColor(style.StationStand.detainRect.centerTrainColor);
|
this.setColor(...style.StationStand.detainRect.centerTrainColor);
|
||||||
} else if (model.stationHoldTrain) {
|
} else if (model.stationHoldTrain) {
|
||||||
this.showMode();
|
this.setShow();
|
||||||
this.setColor(style.StationStand.detainRect.detainTrainTextColor);
|
this.setColor(...style.StationStand.detainRect.localTrainColor);
|
||||||
} else if (model.centerHoldTrain) {
|
} else if (model.centerHoldTrain) {
|
||||||
this.showMode();
|
this.setShow();
|
||||||
this.setColor(style.StationStand.detainRect.centerTrainColor);
|
this.setColor(...style.StationStand.detainRect.centerTrainColor);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,13 +1,23 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="800px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="800px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-table :data="stationStandList" height="150px">
|
<el-table
|
||||||
|
ref="singleTable"
|
||||||
|
:data="stationStandList"
|
||||||
|
highlight-current-row
|
||||||
|
height="150px"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
>
|
||||||
<el-table-column prop="name" label="站台" />
|
<el-table-column prop="name" label="站台" />
|
||||||
<el-table-column prop="minTime" label="最小停站时间" />
|
<el-table-column prop="minTime" label="最小停站时间" />
|
||||||
<el-table-column prop="time" label="规定停站时间" />
|
<el-table-column prop="parkingTime" label="规定停站时间">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getParkingTime(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="maxTime" label="最大停站时间" />
|
<el-table-column prop="maxTime" label="最大停站时间" />
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-checkbox v-model="checkAll">所有站台(L)</el-checkbox>
|
<el-checkbox v-model="checkAll" :disabled="true">所有站台(L)</el-checkbox>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
@ -20,19 +30,19 @@
|
|||||||
<el-row style="text-align: center">
|
<el-row style="text-align: center">
|
||||||
<el-col :span="8">最小值</el-col>
|
<el-col :span="8">最小值</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-input-number v-model="minTime" controls-position="right" size="mini" :min="0" :max="999" style="width: 100px;" />
|
<el-input-number v-model="minTime" :disabled="true" controls-position="right" size="mini" :min="0" :max="999" style="width: 100px;" />
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-input v-model="minTimeValue" size="mini" style="width: 80px;" />
|
<el-input v-model="minTimeValue" size="mini" :disabled="true" style="width: 80px;" />
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row style="text-align: center">
|
<el-row style="text-align: center">
|
||||||
<el-col :span="8">最大值</el-col>
|
<el-col :span="8">最大值</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-input-number v-model="maxTime" controls-position="right" size="mini" :min="0" :max="999" style="width: 100px;" />
|
<el-input-number v-model="maxTime" :disabled="true" controls-position="right" size="mini" :min="0" :max="999" style="width: 100px;" />
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-input v-model="maxTimeValue" size="mini" style="width: 80px;" />
|
<el-input v-model="maxTimeValue" size="mini" :disabled="true" style="width: 80px;" />
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</div>
|
</div>
|
||||||
@ -53,15 +63,15 @@
|
|||||||
<el-row style="text-align: center;">
|
<el-row style="text-align: center;">
|
||||||
<el-col :span="8">额定值</el-col>
|
<el-col :span="8">额定值</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-input-number v-model="ratedValue" controls-position="right" size="mini" :min="0" :max="999" style="width: 100px;" />
|
<el-input-number v-model="ratedValue" :disabled="true" controls-position="right" size="mini" :min="0" :max="999" style="width: 100px;" />
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-input v-model="ratedValue11" size="mini" style="width: 80px;" />
|
<el-input v-model="ratedValue11" :disabled="true" size="mini" style="width: 80px;" />
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</div>
|
</div>
|
||||||
<el-row style="padding: 10px 0;">
|
<el-row style="padding: 10px 0;">
|
||||||
<el-button @click="handleReset">复位</el-button>
|
<el-button @click="handleReset">复位(R)</el-button>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row>
|
<el-row>
|
||||||
<div style="padding: 2px 20px;border: 1px solid #ADADAD;width: 180px;text-align: center;">停站时间范围:1-999</div>
|
<div style="padding: 2px 20px;border: 1px solid #ADADAD;width: 180px;text-align: center;">停站时间范围:1-999</div>
|
||||||
@ -70,7 +80,7 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
<el-row justify="center" class="button-group">
|
<el-row justify="center" class="button-group">
|
||||||
<el-col :span="4" :offset="1">
|
<el-col :span="4" :offset="1">
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定(O)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="!selected" @click="commit">确定(O)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button>应用(A)</el-button>
|
<el-button>应用(A)</el-button>
|
||||||
@ -89,7 +99,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
||||||
// import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
export default {
|
export default {
|
||||||
name: 'AllocateTime',
|
name: 'AllocateTime',
|
||||||
@ -156,9 +166,29 @@ export default {
|
|||||||
doClose() {
|
doClose() {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
this.dialogShow = false;
|
||||||
|
this.$refs.singleTable.setCurrentRow();
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
},
|
},
|
||||||
commit() {
|
commit() {
|
||||||
|
commitOperate(menuOperate.StationStand.setStopTime, {standCode: this.selected.code, parkingTime: this.currentTime, parkingAlwaysValid: false}, 3).then(({valid})=>{
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleCurrentChange(val) {
|
||||||
|
if (!val) { return; }
|
||||||
|
commitOperate(menuOperate.StationStand.setStopTime, {code:val.code}).then(({valid, operate})=>{
|
||||||
|
if (valid) {
|
||||||
|
const stand = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||||
|
this.currentTime = stand.parkingTime;
|
||||||
|
this.selected = val;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
getParkingTime(code) {
|
||||||
|
const stand = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
return stand.parkingTime;
|
||||||
},
|
},
|
||||||
handleReset() {
|
handleReset() {
|
||||||
},
|
},
|
||||||
|
@ -1,16 +1,30 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="600px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="600px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-table :data="switchList" height="350px">
|
<el-table
|
||||||
|
ref="singleTable"
|
||||||
|
:data="switchList"
|
||||||
|
highlight-current-row
|
||||||
|
height="350px"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
>
|
||||||
<el-table-column prop="name" label="道岔" />
|
<el-table-column prop="name" label="道岔" />
|
||||||
<el-table-column prop="blockStatus" label="道岔封锁状态" />
|
<el-table-column prop="blockStatus" label="道岔封锁状态">
|
||||||
<el-table-column prop="blockProcess" label="设置封锁进程" />
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getSwitchStatus(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="blockProcess" label="设置封锁进程">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getProcess(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="unblockProcess" label="解除封锁进程" />
|
<el-table-column prop="unblockProcess" label="解除封锁进程" />
|
||||||
</el-table>
|
</el-table>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row justify="center" class="button-group">
|
<el-row justify="center" class="button-group">
|
||||||
<el-col :span="4" :offset="1">
|
<el-col :span="4" :offset="1">
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定(O)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="!selected || !!initEle" @click="commit">确定(O)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">应用(A)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">应用(A)</el-button>
|
||||||
@ -23,19 +37,22 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<notice-info ref="noticeInfo" pop-class="ningbo-01__systerm" />
|
<notice-info ref="noticeInfo" pop-class="ningbo-01__systerm" />
|
||||||
|
<switch-block ref="switchBlock" @commandSuccess="commandSuccess" />
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
||||||
// import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
|
import SwitchBlock from './switchBlock';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'StandDetain',
|
name: 'StandDetain',
|
||||||
components: {
|
components: {
|
||||||
NoticeInfo
|
NoticeInfo,
|
||||||
|
SwitchBlock
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -48,7 +65,9 @@ export default {
|
|||||||
mode: '',
|
mode: '',
|
||||||
position: '',
|
position: '',
|
||||||
reserved: '',
|
reserved: '',
|
||||||
operate: ''
|
operate: '',
|
||||||
|
initEle: null,
|
||||||
|
commandEleCode: null
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@ -88,6 +107,8 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
doShow(operate, selected) {
|
doShow(operate, selected) {
|
||||||
|
this.initEle = null;
|
||||||
|
this.commandEleCode = null;
|
||||||
this.selected = selected;
|
this.selected = selected;
|
||||||
this.operate = operate;
|
this.operate = operate;
|
||||||
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
||||||
@ -99,12 +120,54 @@ export default {
|
|||||||
doClose() {
|
doClose() {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
this.dialogShow = false;
|
||||||
|
this.$refs.singleTable.setCurrentRow();
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
},
|
},
|
||||||
commit() {
|
commit() {
|
||||||
|
const step = {
|
||||||
|
code: `${this.selected.code}`,
|
||||||
|
operation: OperationEvent.Switch.block.menu.init,
|
||||||
|
param: {}
|
||||||
|
};
|
||||||
|
this.$store.dispatch('training/nextNew', step).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
|
this.$refs.switchBlock.doShow(step, this.selected);
|
||||||
|
this.initEle = this.selected;
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
},
|
},
|
||||||
handleClick() {
|
handleCurrentChange(val) {
|
||||||
|
if (!val) { return; }
|
||||||
|
this.initEle = null;
|
||||||
|
commitOperate(menuOperate.Switch.block, {code:val.code}, 1).then(({valid})=>{
|
||||||
|
if (valid) {
|
||||||
|
this.selected = val;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
getSwitchStatus(code) {
|
||||||
|
const switchEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
if (switchEle.blockade) {
|
||||||
|
return '锁闭的';
|
||||||
|
} else {
|
||||||
|
return '未锁闭的';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getProcess(code) {
|
||||||
|
if (this.commandEleCode && this.commandEleCode === code) {
|
||||||
|
return '已完成封锁';
|
||||||
|
} else if (this.initEle && this.initEle.code === code) {
|
||||||
|
return '已初始化';
|
||||||
|
} else {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
commandSuccess(code) {
|
||||||
|
this.commandEleCode = code;
|
||||||
|
this.$refs.singleTable.setCurrentRow();
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
const operate = {
|
const operate = {
|
||||||
|
@ -2,7 +2,13 @@
|
|||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="600px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="600px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="16">
|
<el-col :span="16">
|
||||||
<el-table :data="stationStandList" height="350px">
|
<el-table
|
||||||
|
ref="singleTable"
|
||||||
|
:data="stationStandList"
|
||||||
|
highlight-current-row
|
||||||
|
height="350px"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
>
|
||||||
<el-table-column prop="name" label="站台" />
|
<el-table-column prop="name" label="站台" />
|
||||||
<el-table-column prop="groupNumber" label="状态">
|
<el-table-column prop="groupNumber" label="状态">
|
||||||
<span>打开</span>
|
<span>打开</span>
|
||||||
@ -40,7 +46,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
||||||
// import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@ -105,8 +111,11 @@ export default {
|
|||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
},
|
},
|
||||||
commit() {
|
commit() {
|
||||||
|
// commitOperate(menuOperate.StationStand.setDetainTrain, {stationCodes:[this.stationCode]}, 0).then((data)=>{
|
||||||
|
// this.doClose();
|
||||||
|
// });
|
||||||
},
|
},
|
||||||
handleClick() {
|
handleCurrentChange(val) {
|
||||||
|
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -1,15 +1,23 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="600px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="800px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row style="width: 100%;overflow-x: auto;">
|
<el-row style="width: 100%;overflow-x: auto;">
|
||||||
<el-table :data="stationStandList" border height="350px">
|
<el-table :data="stationStandList" height="350px">
|
||||||
<el-table-column prop="name" width="80" label="站台" />
|
<el-table-column prop="name" width="80" label="站台" />
|
||||||
<el-table-column prop="status" width="80" label="状态" />
|
<el-table-column prop="status" width="80" label="状态">打开</el-table-column>
|
||||||
<el-table-column prop="minTime" width="130" label="最小停站时间" />
|
<el-table-column prop="minTime" width="110" label="最小停站时间" />
|
||||||
<el-table-column prop="time" width="130" label="规定停站时间" />
|
<el-table-column prop="parkingTime" width="110" label="规定停站时间">
|
||||||
<el-table-column prop="maxTime" width="130" label="最大停站时间" />
|
<template slot-scope="scope">
|
||||||
<el-table-column prop="hold" width="80" label="扣车" />
|
<span>{{ getParkingTime(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="maxTime" width="110" label="最大停站时间" />
|
||||||
|
<el-table-column prop="detain" label="扣车">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getDetainStatus(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="section" width="80" label="轨道" />
|
<el-table-column prop="section" width="80" label="轨道" />
|
||||||
<el-table-column prop="parkTime" width="130" label="当前停站时间" />
|
<el-table-column prop="parkTime" width="110" label="当前停站时间" />
|
||||||
<el-table-column prop="emergencyButton" width="80" label="紧急按钮" />
|
<el-table-column prop="emergencyButton" width="80" label="紧急按钮" />
|
||||||
<el-table-column prop="setting" width="80" label="门设置" />
|
<el-table-column prop="setting" width="80" label="门设置" />
|
||||||
<el-table-column prop="bypass" width="80" label="门旁路" />
|
<el-table-column prop="bypass" width="80" label="门旁路" />
|
||||||
@ -101,6 +109,18 @@ export default {
|
|||||||
},
|
},
|
||||||
handleClick() {
|
handleClick() {
|
||||||
|
|
||||||
|
},
|
||||||
|
getDetainStatus(code) {
|
||||||
|
const stand = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
if (!stand.stationHoldTrain && !stand.centerHoldTrain) {
|
||||||
|
return '未扣车';
|
||||||
|
} else {
|
||||||
|
return '扣车';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getParkingTime(code) {
|
||||||
|
const stand = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
return stand.parkingTime;
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
const operate = {
|
const operate = {
|
||||||
|
@ -4,7 +4,13 @@
|
|||||||
<el-col :span="16">
|
<el-col :span="16">
|
||||||
<el-tabs type="border-card">
|
<el-tabs type="border-card">
|
||||||
<el-tab-pane label="站台">
|
<el-tab-pane label="站台">
|
||||||
<el-table :data="stationStandList" height="350px">
|
<el-table
|
||||||
|
ref="singleTable"
|
||||||
|
:data="stationStandList"
|
||||||
|
highlight-current-row
|
||||||
|
height="350px"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
>
|
||||||
<el-table-column prop="name" label="站台" />
|
<el-table-column prop="name" label="站台" />
|
||||||
<el-table-column prop="detain" label="扣车">
|
<el-table-column prop="detain" label="扣车">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@ -19,7 +25,7 @@
|
|||||||
<!--</template>-->
|
<!--</template>-->
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-checkbox v-model="allChecked">所有站台(F)</el-checkbox>
|
<el-checkbox v-model="allChecked" :disabled="true">所有站台(F)</el-checkbox>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="系统">系统</el-tab-pane>
|
<el-tab-pane label="系统">系统</el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
@ -35,7 +41,7 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
<el-row justify="center" class="button-group">
|
<el-row justify="center" class="button-group">
|
||||||
<el-col :span="4" :offset="1">
|
<el-col :span="4" :offset="1">
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定(O)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" :disabled="!selected" @click="commit">确定(O)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button>应用(A)</el-button>
|
<el-button>应用(A)</el-button>
|
||||||
@ -54,7 +60,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
||||||
// import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@ -97,6 +103,18 @@ export default {
|
|||||||
if (this.show) {
|
if (this.show) {
|
||||||
this.commit();
|
this.commit();
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
selected(val) {
|
||||||
|
if (val) {
|
||||||
|
const stand = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||||
|
if (stand && !stand.stationHoldTrain && !stand.centerHoldTrain) {
|
||||||
|
this.status = true;
|
||||||
|
this.standStatus = false;
|
||||||
|
} else {
|
||||||
|
this.status = false;
|
||||||
|
this.standStatus = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@ -119,12 +137,32 @@ export default {
|
|||||||
doClose() {
|
doClose() {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
this.dialogShow = false;
|
||||||
|
this.$refs.singleTable.setCurrentRow();
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
},
|
},
|
||||||
commit() {
|
commit() {
|
||||||
|
let cmdCommand = menuOperate.StationStand.setDetainTrain;
|
||||||
|
if (this.standStatus) {
|
||||||
|
cmdCommand = menuOperate.StationStand.cancelDetainTrain;
|
||||||
|
}
|
||||||
|
commitOperate(cmdCommand, {standCode: this.selected.code}, 3).then((valid)=>{
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
handleClick() {
|
handleCurrentChange(val) {
|
||||||
|
if (!val) { return; }
|
||||||
|
const stand = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||||
|
let cmdCommand = menuOperate.StationStand.cancelDetainTrain;
|
||||||
|
if (stand && !stand.stationHoldTrain && !stand.centerHoldTrain) {
|
||||||
|
cmdCommand = menuOperate.StationStand.setDetainTrain;
|
||||||
|
}
|
||||||
|
commitOperate(cmdCommand, {code:val.code}).then(({valid, operate})=>{
|
||||||
|
if (valid) {
|
||||||
|
this.selected = val;
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
getDetainStatus(code) {
|
getDetainStatus(code) {
|
||||||
const stand = this.$store.getters['map/getDeviceByCode'](code);
|
const stand = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
@ -2,18 +2,32 @@
|
|||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="600px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="600px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="18">
|
<el-col :span="18">
|
||||||
<el-table :data="switchList" height="350px">
|
<el-table
|
||||||
|
ref="singleTable"
|
||||||
|
:data="switchList"
|
||||||
|
highlight-current-row
|
||||||
|
height="350px"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
>
|
||||||
<el-table-column prop="name" width="80" label="道岔" />
|
<el-table-column prop="name" width="80" label="道岔" />
|
||||||
<el-table-column prop="blockStatus" label="道岔封锁状态" />
|
<el-table-column prop="blockStatus" label="道岔封锁状态">
|
||||||
<el-table-column prop="blockProcess" label="设置封锁进程" />
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getSwitchStatus(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="blockProcess" label="设置封锁进程">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getProcess(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="unblockProcess" label="解除封锁进程" />
|
<el-table-column prop="unblockProcess" label="解除封锁进程" />
|
||||||
</el-table>
|
</el-table>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="6">
|
<el-col :span="6">
|
||||||
<div class="radio-box-title">命令</div>
|
<div class="radio-box-title">命令</div>
|
||||||
<div class="radio-box">
|
<div class="radio-box">
|
||||||
<el-radio v-model="command" label="normal" style="display: block;margin-bottom: 10px;">确认</el-radio>
|
<el-radio v-model="command" :label="true" style="display: block;margin-bottom: 10px;">确认</el-radio>
|
||||||
<el-radio v-model="command" label="reverse" style="display: block;">取消</el-radio>
|
<el-radio v-model="command" :label="false" style="display: block;">取消</el-radio>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
@ -40,6 +54,7 @@ import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
|||||||
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
||||||
// import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
// import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
|
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'StandDetain',
|
name: 'StandDetain',
|
||||||
@ -54,7 +69,7 @@ export default {
|
|||||||
dialogShow: false,
|
dialogShow: false,
|
||||||
loading: false,
|
loading: false,
|
||||||
selected: null,
|
selected: null,
|
||||||
command: '',
|
command: true
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@ -98,6 +113,7 @@ export default {
|
|||||||
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
// 如果不是断点激活,而是第一次显示,则需要设置初始值
|
||||||
this.dialogShow = true;
|
this.dialogShow = true;
|
||||||
this.$nextTick(function () {
|
this.$nextTick(function () {
|
||||||
|
this.$refs.singleTable.setCurrentRow(selected);
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -106,10 +122,43 @@ export default {
|
|||||||
this.dialogShow = false;
|
this.dialogShow = false;
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
},
|
},
|
||||||
commit() {
|
getSwitchStatus(code) {
|
||||||
|
const switchEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
if (switchEle.blockade) {
|
||||||
|
return '锁闭的';
|
||||||
|
} else {
|
||||||
|
return '未锁闭的';
|
||||||
|
}
|
||||||
},
|
},
|
||||||
handleClick() {
|
commit() {
|
||||||
|
if (this.command) {
|
||||||
|
const operate = {
|
||||||
|
cmdType: CMD.Switch.CMD_SWITCH_BLOCK,
|
||||||
|
operation: OperationEvent.Switch.block.confirm.operation,
|
||||||
|
over: true,
|
||||||
|
param: {switchCode: this.selected.code}
|
||||||
|
};
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
this.$emit('commandSuccess', this.selected.code);
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
this.doClose();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
this.cancel();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
handleCurrentChange(val) {
|
||||||
|
this.$refs.singleTable.setCurrentRow(this.selected);
|
||||||
|
},
|
||||||
|
getProcess(code) {
|
||||||
|
if (this.selected.code === code) {
|
||||||
|
return '等待确认/取消';
|
||||||
|
} else {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
const operate = {
|
const operate = {
|
||||||
|
@ -2,36 +2,51 @@
|
|||||||
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="650px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
<el-dialog v-dialogDrag class="ningbo-01__systerm route-setting" :title="title" :visible.sync="show" width="650px" :before-close="doClose" :z-index="2000" :modal="false" :close-on-click-modal="false">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="18">
|
<el-col :span="18">
|
||||||
<el-table :data="stationStandList" height="350px">
|
<!--<el-table :data="switchList" height="350px">-->
|
||||||
|
<el-table
|
||||||
|
ref="singleTable"
|
||||||
|
:data="switchList"
|
||||||
|
highlight-current-row
|
||||||
|
height="350px"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
>
|
||||||
<el-table-column prop="name" label="道岔" />
|
<el-table-column prop="name" label="道岔" />
|
||||||
<el-table-column prop="mode" label="模式" />
|
<el-table-column prop="mode" label="模式" />
|
||||||
<el-table-column prop="position" label="位置" />
|
<el-table-column prop="position" label="位置">
|
||||||
<el-table-column prop="reserved" label="预留" />
|
<template slot-scope="scope">
|
||||||
<el-table-column prop="status" label="状态" />
|
<span>{{ getSwitchPosition(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="reserved" label="预留">未预留</el-table-column>
|
||||||
|
<el-table-column prop="status" label="状态">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ getSwitchStatus(scope.row.code) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="6">
|
<el-col :span="6">
|
||||||
<div class="radio-box-title">设置模式</div>
|
<div class="radio-box-title">设置模式</div>
|
||||||
<div class="radio-box">
|
<div class="radio-box">
|
||||||
<el-radio v-model="mode" label="auto" style="display: block;margin-bottom: 10px;">自动</el-radio>
|
<el-radio v-model="mode" label="auto" :disabled="true" style="display: block;margin-bottom: 10px;">自动</el-radio>
|
||||||
<el-radio v-model="mode" label="artificial" style="display: block;">人工</el-radio>
|
<el-radio v-model="mode" label="artificial" :disabled="true" style="display: block;">人工</el-radio>
|
||||||
</div>
|
</div>
|
||||||
<div class="radio-box-title">设置位置</div>
|
<div class="radio-box-title">设置位置</div>
|
||||||
<div class="radio-box">
|
<div class="radio-box">
|
||||||
<el-radio v-model="position" label="normal" style="display: block;margin-bottom: 10px;">定位</el-radio>
|
<el-radio v-model="position" label="normal" :disabled="!selected" style="display: block;margin-bottom: 10px;">定位</el-radio>
|
||||||
<el-radio v-model="position" label="reverse" style="display: block;">反位</el-radio>
|
<el-radio v-model="position" label="reverse" :disabled="!selected" style="display: block;">反位</el-radio>
|
||||||
</div>
|
</div>
|
||||||
<div class="radio-box-title">设置预留</div>
|
<div class="radio-box-title">设置预留</div>
|
||||||
<div class="radio-box">
|
<div class="radio-box">
|
||||||
<el-radio v-model="position" label="normal" style="display: block;margin-bottom: 10px;">自动与预留</el-radio>
|
<el-radio v-model="reserved" label="auto" :disabled="true" style="display: block;margin-bottom: 10px;">自动与预留</el-radio>
|
||||||
<el-radio v-model="position" label="reverse" style="display: block;margin-bottom: 10px;">预留</el-radio>
|
<el-radio v-model="reserved" label="reversed" :disabled="true" style="display: block;margin-bottom: 10px;">预留</el-radio>
|
||||||
<el-radio v-model="position" label="reverse" style="display: block;">释放</el-radio>
|
<el-radio v-model="reserved" label="release" :disabled="true" style="display: block;">释放</el-radio>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row justify="center" class="button-group">
|
<el-row justify="center" class="button-group">
|
||||||
<el-col :span="4" :offset="1">
|
<el-col :span="4" :offset="1">
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定(O)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :disabled="!selected" :loading="loading" :selected="true" @click="commit">确定(O)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">应用(A)</el-button>
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">应用(A)</el-button>
|
||||||
@ -50,7 +65,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
||||||
// import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuOperate';
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@ -68,12 +83,13 @@ export default {
|
|||||||
selected: null,
|
selected: null,
|
||||||
mode: '',
|
mode: '',
|
||||||
position: '',
|
position: '',
|
||||||
reserved: ''
|
reserved: 'reversed'
|
||||||
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
...mapGetters('map', [
|
...mapGetters('map', [
|
||||||
'stationStandList'
|
'switchList'
|
||||||
]),
|
]),
|
||||||
show() {
|
show() {
|
||||||
return this.dialogShow && !this.$store.state.menuOperation.break;
|
return this.dialogShow && !this.$store.state.menuOperation.break;
|
||||||
@ -115,12 +131,48 @@ export default {
|
|||||||
doClose() {
|
doClose() {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
this.dialogShow = false;
|
||||||
|
this.$refs.singleTable.setCurrentRow();
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
},
|
},
|
||||||
commit() {
|
commit() {
|
||||||
|
commitOperate(menuOperate.Switch.turnout, {switchCode: this.selected.code}, 3).then(({valid})=>{
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
handleClick() {
|
handleCurrentChange(val) {
|
||||||
|
if (!val) { return; }
|
||||||
|
commitOperate(menuOperate.Switch.turnout, {code:val.code}).then(({valid, operate})=>{
|
||||||
|
if (valid) {
|
||||||
|
const switchEle = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||||
|
this.position = '';
|
||||||
|
if (switchEle.normalPosition) {
|
||||||
|
this.position = 'reverse';
|
||||||
|
} else if (switchEle.reversePosition) {
|
||||||
|
this.position = 'normal';
|
||||||
|
}
|
||||||
|
this.selected = val;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
getSwitchPosition(code) {
|
||||||
|
const switchEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
if (switchEle.normalPosition) {
|
||||||
|
return '定位';
|
||||||
|
} else if (switchEle.reversePosition) {
|
||||||
|
return '反位';
|
||||||
|
} else {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getSwitchStatus(code) {
|
||||||
|
const switchEle = this.$store.getters['map/getDeviceByCode'](code);
|
||||||
|
if (switchEle.blockade) {
|
||||||
|
return '锁闭的';
|
||||||
|
} else {
|
||||||
|
return '未锁闭的';
|
||||||
|
}
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
const operate = {
|
const operate = {
|
||||||
|
@ -57,15 +57,14 @@ service.interceptors.response.use(
|
|||||||
// eslint-disable-next-line no-undef
|
// eslint-disable-next-line no-undef
|
||||||
EventBus.$emit('clearCheckLogin');
|
EventBus.$emit('clearCheckLogin');
|
||||||
// 断开连接
|
// 断开连接
|
||||||
store.dispatch('disconnect').then(()=>{
|
store.dispatch('disconnect');
|
||||||
MessageBox.confirm(i18n.t('tip.logoutTips'), i18n.t('tip.hint'), {
|
MessageBox.confirm(i18n.t('tip.logoutTips'), i18n.t('tip.hint'), {
|
||||||
confirmButtonText: i18n.t('tip.confirmLogin'),
|
confirmButtonText: i18n.t('tip.confirmLogin'),
|
||||||
showCancelButton: false,
|
showCancelButton: false,
|
||||||
type: 'warning'
|
type: 'warning'
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
store.dispatch('FedLogOut').then(() => {
|
store.dispatch('FedLogOut').then(() => {
|
||||||
location.reload();// 为了重新实例化vue-router对象 避免bug
|
location.reload();// 为了重新实例化vue-router对象 避免bug
|
||||||
});
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
return response.data;
|
return response.data;
|
||||||
|
@ -108,7 +108,7 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="18" style="text-align: left">
|
<el-col :span="18" style="text-align: left">
|
||||||
<div style="margin-top: 10px">服务电话:13289398171</div>
|
<div style="margin-top: 10px">服务电话:13289398171</div>
|
||||||
<div style="margin-top: 10px">截止日期:2020年12月31日</div>
|
<!--<div style="margin-top: 10px">截止日期:2020年12月31日</div>-->
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user