信号添加属性
This commit is contained in:
parent
ec7be523ba
commit
057aee45fc
@ -195,12 +195,13 @@ export default {
|
||||
namePosition: { x: 0, y: 0 },
|
||||
positionPoint: { x: 0, y: 0 },
|
||||
buttonShow: true,
|
||||
useType: '01',
|
||||
potLampType: '01',
|
||||
lampPostType: '01',
|
||||
lampPositionType: '01',
|
||||
guideShow: false,
|
||||
stationCode: this.addModel.stationCode
|
||||
stationCode: this.addModel.stationCode,
|
||||
callOn: true,
|
||||
turnBack: false
|
||||
};
|
||||
|
||||
this.sectionList.forEach(elem => {
|
||||
@ -236,8 +237,8 @@ export default {
|
||||
});
|
||||
},
|
||||
hover(field) {
|
||||
this.field = field === this.field ? '' : field;
|
||||
this.$emit('signalSectionCode', this.field);
|
||||
field = field === this.field ? '' : field;
|
||||
this.$emit('signalSectionCode', field);
|
||||
},
|
||||
setSectionCode(code) {
|
||||
this.addModel.sectionCode = code;
|
||||
|
@ -68,7 +68,7 @@ export default {
|
||||
SignalLampPostTypeList: [],
|
||||
SignalLampPositionTypeList: [],
|
||||
SignalPositionTypeList: [],
|
||||
SignalUseTypeList: [],
|
||||
// SignalUseTypeList: [],
|
||||
failTypes: [
|
||||
{ code: '00', name: this.$t('map.normal') },
|
||||
{ code: '01', name: this.$t('map.signalFilamentAlarm') }
|
||||
@ -93,7 +93,6 @@ export default {
|
||||
virtual: false, // 是否虚拟信号机
|
||||
positionType: '',
|
||||
namePosition: { x: 0, y: 0 },
|
||||
useType: '',
|
||||
stationCode: '',
|
||||
sectionOffset: 0,
|
||||
rotate: 0,
|
||||
@ -105,7 +104,9 @@ export default {
|
||||
positionPoint: { x: 0, y: 0 },
|
||||
buttonPosition: { x: 0, y: 0 },
|
||||
guidePosition: { x: 0, y: 0 },
|
||||
interlockStationCode: ''
|
||||
interlockStationCode: '',
|
||||
callOn: true,
|
||||
turnBack: false
|
||||
},
|
||||
addModel: {
|
||||
number: 2
|
||||
@ -167,21 +168,23 @@ export default {
|
||||
{ prop: 'positionType', label: this.$t('map.signalPositionType'), type: 'radio', optionLabel: 'name', optionValue: 'code', border: true, radioList: this.SignalPositionTypeList },
|
||||
{ prop: 'rotate', label: this.$t('map.rotateAngle'), type: 'number', min: -180, max: 180, placeholder: this.$t('tip.angle') },
|
||||
{ prop: 'nameRotated', label: this.$t('map.signalNameRotated'), type: 'checkbox' },
|
||||
{ prop: 'virtual', label: '是否虚拟信号机:', type: 'checkbox' },
|
||||
{ prop: 'virtual', label: '是否虚拟信号机:', type: 'checkbox', change: true, deviceChange: this.virtualChange },
|
||||
{ prop: 'namePosition', label: this.$t('map.signalNamePosition'), type: 'coordinate', width: '140px', children: [
|
||||
{ prop: 'namePosition.x', firstLevel: 'namePosition', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '25px' },
|
||||
{ prop: 'namePosition.y', firstLevel: 'namePosition', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '25px' }
|
||||
] },
|
||||
{ prop: 'buttonShow', label: this.$t('map.signalButtonShow'), type: 'checkbox' },
|
||||
{ prop: 'buttonPosition', label: this.$t('map.signalButtonPosition'), type: 'coordinate', width: '140px', children: [
|
||||
{ prop: 'buttonPosition', label: this.$t('map.signalButtonPosition'), type: 'coordinate', width: '140px', isHidden: !this.editModel.buttonShow, children: [
|
||||
{ prop: 'buttonPosition.x', firstLevel: 'buttonPosition', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '25px' },
|
||||
{ prop: 'buttonPosition.y', firstLevel: 'buttonPosition', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '25px' }
|
||||
] },
|
||||
{ prop: 'guideShow', label: this.$t('map.signalGuideShow'), type: 'checkbox' },
|
||||
{ prop: 'guidePosition', label: this.$t('map.signalGuidePosition'), type: 'coordinate', width: '140px', children: [
|
||||
{ prop: 'guidePosition', label: this.$t('map.signalGuidePosition'), type: 'coordinate', width: '140px', isHidden: !this.editModel.guideShow, children: [
|
||||
{ prop: 'guidePosition.x', firstLevel: 'guidePosition', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '25px' },
|
||||
{ prop: 'guidePosition.y', firstLevel: 'guidePosition', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '25px' }
|
||||
] }
|
||||
] },
|
||||
{ prop: 'callOn', label: '是否引导信号', type: 'checkbox', isHidden: this.editModel.virtual},
|
||||
{ prop: 'turnBack', label: '是否折返进路始端', type: 'checkbox', isHidden: this.editModel.virtual}
|
||||
]
|
||||
},
|
||||
map: {
|
||||
@ -190,7 +193,7 @@ export default {
|
||||
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.centralizedStationList },
|
||||
{ prop: 'interlockStationCode', label: '所属联锁站', type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.centralizedStationList},
|
||||
{ prop: 'uniqueName', label: this.$t('map.signalUniqueName'), type: 'input' },
|
||||
{ prop: 'useType', label: this.$t('map.signalUseType'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.SignalUseTypeList },
|
||||
// { prop: 'useType', label: this.$t('map.signalUseType'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.SignalUseTypeList },
|
||||
{ prop: 'sectionCode', label: this.$t('map.belongsSection'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.signalSectionList },
|
||||
{ prop: 'sectionOffset', label: this.$t('map.signalOffset'), type: 'number', min: 0, placeholder: this.$t('tip.meter') }
|
||||
|
||||
@ -254,9 +257,9 @@ export default {
|
||||
this.SignalPositionTypeList = list;
|
||||
});
|
||||
|
||||
this.$Dictionary.signalUseType().then(list => {
|
||||
this.SignalUseTypeList = list;
|
||||
});
|
||||
// this.$Dictionary.signalUseType().then(list => {
|
||||
// this.SignalUseTypeList = list;
|
||||
// });
|
||||
},
|
||||
methods: {
|
||||
deviceChange(code) {
|
||||
@ -353,6 +356,15 @@ export default {
|
||||
this.$message('请输入偏移量');
|
||||
}
|
||||
},
|
||||
virtualChange(val) {
|
||||
if (val) {
|
||||
this.editModel.callOn = false;
|
||||
this.editModel.turnBack = false;
|
||||
} else {
|
||||
this.editModel.callOn = true;
|
||||
this.editModel.turnBack = false;
|
||||
}
|
||||
},
|
||||
// 寻找信号机关联区段
|
||||
findSection(signal) {
|
||||
// 01 向左 02 向右
|
||||
|
Loading…
Reference in New Issue
Block a user