Commit fff6b53a authored by 旭艳's avatar 旭艳

修改指令维护自定义搜索组件1

parent b7e47258
...@@ -50,11 +50,20 @@ export default { ...@@ -50,11 +50,20 @@ export default {
'form.sorties': { 'form.sorties': {
immediate: true, immediate: true,
handler(val) { handler(val) {
const sorties = this.sortiesData.find(r => r.value === val)
this.$set(this.form, 'sortiesName', sorties && sorties.sortiesName || '')
this.$utils.getDicListByCode('SoriteType').then(res => { this.$utils.getDicListByCode('SoriteType').then(res => {
this.SoriteTypeOptions = res this.SoriteTypeOptions = res
this.getStation(val) this.getStation(val)
}) })
} }
},
'form.postion': {
immediate: true,
handler(val) {
const postion = this.postionList.find(r => r.value === val)
this.$set(this.form, 'postionName', postion && postion.label || '')
}
} }
}, },
created() { created() {
...@@ -87,6 +96,7 @@ export default { ...@@ -87,6 +96,7 @@ export default {
} }
}) })
this.$set(this.form, 'postion', this.postionList[0].value) this.$set(this.form, 'postion', this.postionList[0].value)
this.$set(this.form, 'postionName', this.postionList[0].label)
} }
}) })
} }
...@@ -100,10 +110,12 @@ export default { ...@@ -100,10 +110,12 @@ export default {
this.sortiesData = res.items.content.map(row => { this.sortiesData = res.items.content.map(row => {
return { return {
value: `${row.sourceId}:${row.targetId}`, value: `${row.sourceId}:${row.targetId}`,
label: this.getSoritesLabel(row) label: this.getSoritesLabel(row),
sortiesName: row.source.defName
} }
}) })
this.$set(this.form, 'sorties', this.sortiesData[0].value) this.$set(this.form, 'sorties', this.sortiesData[0].value)
this.$set(this.form, 'sortiesName', this.sortiesData[0].sortiesName)
} }
}) })
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment