Merge branch 'test_dispaly' of https://git.code.tencent.com/lian-cbtc/jl-client into test_dispaly1
This commit is contained in:
commit
2aadaaf100
@ -74,6 +74,16 @@ export const menuOperate = {
|
||||
// 添加备用车 (大铁线路 车次号 非车组号)
|
||||
operation: OperationEvent.Section.addSpareTrain.menu.operation,
|
||||
cmdType: CMD.Section.CMD_TRAIN_LOAD_TRIP_NUMBER_TRAIN
|
||||
},
|
||||
defectiveShunting:{
|
||||
// 分路不良
|
||||
operation: OperationEvent.Section.defectiveShunting.menu.operation,
|
||||
cmdType: CMD.Section.CMD_SECTION_DEFECTIVE_SHUNTING
|
||||
},
|
||||
cancelDefectiveShunting:{
|
||||
// 取消分路不良
|
||||
operation: OperationEvent.Section.cancelDefectiveShunting.menu.operation,
|
||||
cmdType: CMD.Section.CMD_SECTION_DEFECTIVE_SHUNTING
|
||||
}
|
||||
},
|
||||
Signal:{
|
||||
|
@ -33,6 +33,7 @@
|
||||
</template>
|
||||
<script>
|
||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
|
||||
export default {
|
||||
name: 'DefectivePasswordBox',
|
||||
components: {
|
||||
@ -60,13 +61,16 @@ export default {
|
||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||
},
|
||||
domIdConfirm() {
|
||||
return this.dialogShow ? OperationEvent.Switch.defectiveShunting.twoConfirm.domId : '';
|
||||
const domId = OperationHandler.getDomIdByOperation(this.operation);
|
||||
return this.dialogShow ? domId : '';
|
||||
}
|
||||
},
|
||||
methods:{
|
||||
doShow(operate) {
|
||||
this.operation = operate.operation;
|
||||
if (operate.operation == OperationEvent.Switch.cancelDefectiveShunting.menu.operation) {
|
||||
if (operate.operation == OperationEvent.Section.cancelDefectiveShunting.menu.operation) {
|
||||
this.name = '取消分路不良';
|
||||
} else if (operate.operation == OperationEvent.Switch.cancelDefectiveShunting.menu.operation) {
|
||||
this.name = '取消分路不良';
|
||||
} else {
|
||||
this.name = '分路不良';
|
||||
|
@ -63,7 +63,9 @@ export default {
|
||||
doShow(operate, selected) {
|
||||
this.selected = selected;
|
||||
this.operation = operate.operation;
|
||||
if (operate.operation == OperationEvent.Switch.cancelDefectiveShunting.menu.operation) {
|
||||
if (operate.operation == OperationEvent.Section.cancelDefectiveShunting.menu.operation) {
|
||||
this.title = '取消分路不良';
|
||||
} else if (operate.operation == OperationEvent.Switch.cancelDefectiveShunting.menu.operation) {
|
||||
this.title = '取消分路不良';
|
||||
} else {
|
||||
this.title = '分路不良';
|
||||
@ -118,6 +120,10 @@ export default {
|
||||
operate.cmdType = CMD.Section.CMD_SECTION_DEFECTIVE_SHUNTING;
|
||||
break;
|
||||
}
|
||||
case OperationEvent.Section.cancelDefectiveShunting.menu.operation: {
|
||||
operate.cmdType = CMD.Section.CMD_SECTION_DEFECTIVE_SHUNTING;
|
||||
break;
|
||||
}
|
||||
case OperationEvent.Switch.cancelDefectiveShunting.menu.operation: {
|
||||
operate.cmdType = CMD.Section.CMD_SECTION_CANCEL_DEFECTIVE_SHUNTING;
|
||||
break;
|
||||
|
@ -6,6 +6,7 @@
|
||||
<set-fault ref="setFault" pop-class="datie-02__systerm" />
|
||||
<add-spare-train ref="addSpareTrain" />
|
||||
<draw-select ref="drawSelect" />
|
||||
<fork-directive ref="forkDirective" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@ -20,6 +21,7 @@ import { DeviceMenu, OperateMode } from '@/scripts/ConstDic';
|
||||
import { menuOperate, commitOperate } from '@/jmapNew/theme/components/utils/menuOperate';
|
||||
import AddSpareTrain from './dialog/addSpareTrain';
|
||||
import DrawSelect from './dialog/drawSelect';
|
||||
import ForkDirective from './dialog/forkDirective';
|
||||
|
||||
export default {
|
||||
name: 'SectionMenu',
|
||||
@ -29,7 +31,8 @@ export default {
|
||||
TrainAddPlan,
|
||||
SetFault,
|
||||
AddSpareTrain,
|
||||
DrawSelect
|
||||
DrawSelect,
|
||||
ForkDirective
|
||||
},
|
||||
props: {
|
||||
selected: {
|
||||
@ -50,11 +53,25 @@ export default {
|
||||
menu: [],
|
||||
menuNormal: [
|
||||
{
|
||||
label: ' 增加车次',
|
||||
label: '增加车次',
|
||||
handler: this.addSpare,
|
||||
cmdType: CMD.Section.CMD_TRAIN_LOAD_TRIP_NUMBER_TRAIN,
|
||||
isDisabled: (section, station, work) => station.controlMode === 'Interlock' && work === 'ctcWork',
|
||||
isShow: (section, work) => ['01', '02', '03'].includes(section.type)
|
||||
},
|
||||
{
|
||||
label: '分路不良',
|
||||
handler: this.forkDirective,
|
||||
cmdType: CMD.Section.CMD_SECTION_DEFECTIVE_SHUNTING,
|
||||
isDisabled: (section, station, work) => station.controlMode === 'Interlock' && work === 'ctcWork',
|
||||
isShow: (section, work) => ['01', '02', '03'].includes(section.type) && work === 'ctcWork'
|
||||
},
|
||||
{
|
||||
label: '空闲',
|
||||
handler: this.cancleForkDirective,
|
||||
cmdType: CMD.Section.CMD_SECTION_DEFECTIVE_SHUNTING,
|
||||
isDisabled: (section, station, work) => station.controlMode === 'Interlock' && work === 'ctcWork',
|
||||
isShow: (section, work) => ['01', '02', '03'].includes(section.type) && work === 'ctcWork'
|
||||
}
|
||||
],
|
||||
menuForce: [
|
||||
@ -138,6 +155,22 @@ export default {
|
||||
}
|
||||
});
|
||||
},
|
||||
// 分路不良
|
||||
forkDirective() {
|
||||
commitOperate(menuOperate.Section.defectiveShunting, {sectionCode:this.selected.code, shuntingTypeList: ['SECTION_SHUNTING']}, 0).then(({valid, operate})=>{
|
||||
if (valid) {
|
||||
this.$refs.forkDirective.doShow(operate, this.selected);
|
||||
}
|
||||
});
|
||||
},
|
||||
// 区段确认空闲,取消分路不良
|
||||
cancleForkDirective() {
|
||||
commitOperate(menuOperate.Section.cancelDefectiveShunting, {sectionCode:this.selected.code, shuntingTypeList: []}, 0).then(({valid, operate})=>{
|
||||
if (valid) {
|
||||
this.$refs.forkDirective.doShow(operate, this.selected);
|
||||
}
|
||||
});
|
||||
},
|
||||
// 设置故障
|
||||
setStoppage() {
|
||||
commitOperate(menuOperate.Common.setFault, { code: this.selected.code }, 0).then(({valid, operate})=>{
|
||||
|
@ -2482,6 +2482,13 @@ export const OperationEvent = {
|
||||
// operation: '428',
|
||||
// domId: '_Tips-Section-Defective-Shunting-MenuButton'
|
||||
// },
|
||||
},
|
||||
// 取消分路不良 大铁线路
|
||||
cancelDefectiveShunting:{
|
||||
menu: {
|
||||
operation: '429',
|
||||
domId: '_Tips-Section-CancelDefectiveShunting-Menu{TOP}'
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user