Commit a4ddf618 by 前端

修复BUG

1 parent fc872363
......@@ -147,6 +147,7 @@
<!-- 选择门店弹窗 -->
<select-store-dialog v-if="selectStoreVisible"
:select-store-visible="selectStoreVisible"
:supervisor-uuid="supervisorTableData[0].uuid"
@handleSelectStoreConfirm="handleSelectStoreConfirm"
@handleSelectStoreClose="handleSelectStoreClose"></select-store-dialog>
</d2-container>
......@@ -222,13 +223,19 @@ export default {
// 选择门店
handleStoreMerchant() {
this.selectStoreVisible = true
if (this.infoForm.flightSupervisorId) {
this.selectStoreVisible = true
} else {
this.$message.warning('请先选择督导')
}
},
handleSelectSupervisorConfirm(selectedData) {
const _valueObj = deepClone(selectedData)
console.log("_valueObj", _valueObj)
this.infoForm.flightSupervisorId = _valueObj.id
this.supervisorTableData = []
this.storeTableData = [] // 选择督导后,门店清空
this.supervisorTableData.push(_valueObj)
this.$refs.supervisorFormRef.clearValidate()
this.handleSelectSupervisorClose()
......@@ -241,6 +248,7 @@ export default {
const _valueObj = deepClone(selectedData)
console.log("_valueObj", _valueObj)
this.infoForm.merchantId = _valueObj.merchantId
this.storeTableData = []
this.storeTableData.push(_valueObj)
this.$refs.merchantFormRef.clearValidate()
this.handleSelectStoreClose()
......@@ -253,6 +261,8 @@ export default {
handleDeleteSupervisor(subIndex) {
this.infoForm.flightSupervisorId = null
this.supervisorTableData.splice(subIndex, 1)
// 删除督导后,门店清空
this.handleDeleteStore(0)
},
// 删除门店
......
......@@ -70,6 +70,10 @@ export default {
selectStoreVisible: {
type: Boolean,
default: false
},
supervisorUuid: {
type: String,
default: ""
}
},
data() {
......@@ -121,6 +125,7 @@ export default {
beforeSearchFn() {
return new Promise(resolve => {
this.searchForm.supervisorUuid = this.supervisorUuid
resolve()
})
},
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!