延续保护 增加 保护区段ctc
This commit is contained in:
parent
7b854e717e
commit
afeec55025
@ -74,7 +74,7 @@
|
||||
</div>
|
||||
<div>
|
||||
<el-form ref="overlabForm" :model="addOverlapModel" :rules="overLapRules" label-width="135px" size="mini" style="margin-top: 15px">
|
||||
<el-form-item :label="$t('map.routeProtectsData') + ':'" prop="sectionList">
|
||||
<el-form-item label="保护区段(非CTC)" prop="sectionList">
|
||||
<el-select v-model="addOverlapModel.sectionList" multiple clearable :filterable="true">
|
||||
<el-option
|
||||
v-for="item in sectionList"
|
||||
@ -88,6 +88,17 @@
|
||||
@click="hover('routeOverlapSectionList')"
|
||||
>{{ $t('map.activate') }}</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item label="保护区段(CTC)" prop="logicList">
|
||||
<el-select v-model="addOverlapModel.logicList" multiple clearable :filterable="true">
|
||||
<el-option
|
||||
v-for="item in sectionList"
|
||||
:key="item.code"
|
||||
:label="item.name + ' (' + item.code + ')'"
|
||||
:value="item.code"
|
||||
/>
|
||||
</el-select>
|
||||
<el-button :type="field === 'routeOverlapLogicList'?'danger':'primary'" @click="hover('routeOverlapLogicList')">{{ $t('map.activate') }}</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item :label="$t('map.continueProtectSwitchData') + ':'" prop="switchPositionList">
|
||||
<el-select v-model="overlapCode" clearable :filterable="true" :placeholder="$t('map.pleaseSelect')">
|
||||
<el-option
|
||||
@ -188,7 +199,8 @@ export default {
|
||||
},
|
||||
addOverlapModel: {
|
||||
parentIndex: '',
|
||||
sectionList: [], // 进路延续保护区段数据列表
|
||||
logicList: [], // 保护区段ctc
|
||||
sectionList: [], // 进路延续保护区段非ctc数据列表
|
||||
switchPositionList: [] // 进路延续保护道岔数据列表
|
||||
},
|
||||
overlapType: '',
|
||||
@ -305,6 +317,13 @@ export default {
|
||||
} else if ( sectionIndex !== -1 ) {
|
||||
this.addOverlapModel.sectionList.splice(sectionIndex, 1);
|
||||
}
|
||||
} else if (selected._type.toUpperCase() === 'Section'.toUpperCase() && this.field.toUpperCase() === 'routeOverlapLogicList'.toUpperCase()) {
|
||||
const sectionIndex = this.addOverlapModel.logicList.indexOf(selected.code);
|
||||
if ((selected.type === '01' || selected.type === '03' || selected.type === '02') && sectionIndex === -1) {
|
||||
this.addOverlapModel.logicList.push(selected.code);
|
||||
} else if (sectionIndex !== -1) {
|
||||
this.addOverlapModel.logicList.splice(sectionIndex, 1);
|
||||
}
|
||||
} else if (selected._type.toUpperCase() === 'Switch'.toUpperCase() && this.field.toUpperCase() === 'switchPositionList'.toUpperCase()) {
|
||||
this.overlapCode = selected.code;
|
||||
}
|
||||
@ -385,6 +404,7 @@ export default {
|
||||
if (this.addOverlapModel.parentIndex || this.addOverlapModel.parentIndex === 0 ) {
|
||||
this.addModel.pathList[this.addOverlapModel.parentIndex] = {
|
||||
sectionList:this.addOverlapModel.sectionList,
|
||||
logicList: this.addOverlapModel.logicList,
|
||||
switchPositionList:this.addOverlapModel.switchPositionList
|
||||
};
|
||||
this.clearOverlab();
|
||||
@ -401,6 +421,7 @@ export default {
|
||||
} else {
|
||||
this.addModel.pathList.push({
|
||||
sectionList:this.addOverlapModel.sectionList,
|
||||
logicList: this.addOverlapModel.logicList,
|
||||
switchPositionList:this.addOverlapModel.switchPositionList
|
||||
});
|
||||
this.$refs.overlabForm.resetFields();
|
||||
@ -411,6 +432,7 @@ export default {
|
||||
this.addOverlapModel = {
|
||||
parentIndex: '',
|
||||
sectionList:[],
|
||||
logicList: [],
|
||||
switchPositionList:[]
|
||||
};
|
||||
this.overlapCode = '';
|
||||
|
Loading…
Reference in New Issue
Block a user