watch: {activeTab: {
handler: function (val, oldVal) { if (val === '1') { this._getPayBillHouseList()
} else { this._getAppReceiveBillList()
}
},
immediate: true}}created () {this.hourseId = this.$route.params.id},methods: {async _getPayBillHouseList () { let result = await getPayBillHouseList(this.hourseId) this.payArr = result.rData
},async _getAppReceiveBillList () { let result = await getAppReceiveBillList(this.hourseId) this.overPayArr = result.rData
}},
1 回答
小唯快跑啊
TA贡献1863条经验 获得超2个赞
在created
里面再进行watch
this.$watch('activeTab', (val, oldVal) => { if (val === '1') { this._getPayBillHouseList() } else { this._getAppReceiveBillList() } })
添加回答
举报
0/150
提交
取消