Commit 95bee80c by 匡雅琴

紧急版本bug修复

1 parent 6b0f9f12
......@@ -89,7 +89,6 @@ export default {
params ? (params.subdistrict ? '' : (params.subdistrict = this.subdistrict)) : (params.subdistrict = this.subdistrict)
let data = ''
for (let key in params) {
console.log(params[key])
data += '&' + key + '=' + params[key]
}
let path = `https://restapi.amap.com/v3/config/district?key=d22348363c34c266f772ae9b635eef2a`
......@@ -117,21 +116,23 @@ export default {
this.provinceForm.provinceName = item.name
this.cityList = item.districts
this.provinceForm.provinceCode = item.adcode
this.cityList.map(itm => {
if (itm.name.indexOf(city) != -1) {
this.provinceForm.cityCode = itm.adcode
this.provinceForm.cityName = itm.name
this.townList = itm.districts
if (town) {
this.townList.map(itmx => {
if (itmx.name.indexOf(town) != -1) {
this.provinceForm.townCode = itmx.adcode
this.provinceForm.townName = itmx.name
}
})
if (city) {
this.cityList.map(itm => {
if (itm.name.indexOf(city) != -1) {
this.provinceForm.cityCode = itm.adcode
this.provinceForm.cityName = itm.name
this.townList = itm.districts
if (town) {
this.townList.map(itmx => {
if (itmx.name.indexOf(town) != -1) {
this.provinceForm.townCode = itmx.adcode
this.provinceForm.townName = itmx.name
}
})
}
}
}
})
})
}
}
})
}
......
......@@ -353,6 +353,7 @@ export default {
this.$set(this.accountAddForm, 'merchantAddress', '')
// 强制更新 merchantAddress
this.$forceUpdate()
this.accountAddForm.cityName = ''
this.accountAddForm.provinceName = provinceName
this.accountAddForm.provinceCode = provinceCode
},
......
......@@ -230,6 +230,7 @@ export default {
// 获取省
selectProvince(provinceName, provinceCode) {
this.infoForm.merchantAddress = ''
this.infoForm.cityName = ''
this.infoForm.provinceName = provinceName
this.infoForm.provinceCode = provinceCode
},
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!