点位管理
This commit is contained in:
@@ -175,7 +175,7 @@ export default {
|
|||||||
this.val1 = this.optionNew1[i].label
|
this.val1 = this.optionNew1[i].label
|
||||||
this.val2 = ''
|
this.val2 = ''
|
||||||
this.active2 = ''
|
this.active2 = ''
|
||||||
this._getPointListByRegion(this.optionNew1[i].value)
|
this._getPointListByRegion(1, this.optionNew1[i].value)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
/** ---- */
|
/** ---- */
|
||||||
@@ -212,18 +212,27 @@ export default {
|
|||||||
this.val3 = this.optionNew3[i].label
|
this.val3 = this.optionNew3[i].label
|
||||||
this.val4 = ''
|
this.val4 = ''
|
||||||
this.active4 = ''
|
this.active4 = ''
|
||||||
this._getPointListByRegion(this.optionNew3[i].value)
|
this._getPointListByRegion(2, this.optionNew3[i].value)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
/** 查询点位 */
|
/** 查询点位 */
|
||||||
async _getPointListByRegion (code) {
|
async _getPointListByRegion (t, code) {
|
||||||
let res = await getPointListByRegion(code)
|
let res = await getPointListByRegion(code)
|
||||||
if (res.code === '1') {
|
if (res.code === '1') {
|
||||||
|
if (t === 1) {
|
||||||
this.option2 = [...res.result]
|
this.option2 = [...res.result]
|
||||||
this.option2.map(el => {
|
this.option2.map(el => {
|
||||||
this.$set(el, 'value', el.point_code)
|
this.$set(el, 'value', el.point_code)
|
||||||
this.$set(el, 'label', el.point_name)
|
this.$set(el, 'label', el.point_name)
|
||||||
})
|
})
|
||||||
|
}
|
||||||
|
if (t === 2) {
|
||||||
|
this.option4 = [...res.result]
|
||||||
|
this.option4.map(el => {
|
||||||
|
this.$set(el, 'value', el.point_code)
|
||||||
|
this.$set(el, 'label', el.point_name)
|
||||||
|
})
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
this.Dialog(res.desc)
|
this.Dialog(res.desc)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user