|
@@ -14,6 +14,7 @@ Page({
|
|
|
showDialog: false,
|
|
|
cacheArea: [] as { cityCode: string, shiftCityCode: string }[], // 临时存储的对应关系
|
|
|
showArea: false,
|
|
|
+ showAreaAfterLeave: false,
|
|
|
areaList: [] as any,
|
|
|
currentValues: [] as any,
|
|
|
|
|
@@ -22,9 +23,9 @@ Page({
|
|
|
name: '',
|
|
|
phoneNumber: '',
|
|
|
detailAddress: '',
|
|
|
- cityCode: 0,
|
|
|
+ cityCode: null,
|
|
|
cityName: "",
|
|
|
- provinceCode: 0,
|
|
|
+ provinceCode: null,
|
|
|
provinceName: "",
|
|
|
regionCode: '',
|
|
|
regionName: "",
|
|
@@ -158,6 +159,16 @@ Page({
|
|
|
showArea: false
|
|
|
})
|
|
|
},
|
|
|
+ onAreaBeforeEnter() {
|
|
|
+ this.setData({
|
|
|
+ showAreaAfterLeave: false
|
|
|
+ })
|
|
|
+ },
|
|
|
+ onAreaAfterLeave() {
|
|
|
+ this.setData({
|
|
|
+ showAreaAfterLeave: true
|
|
|
+ })
|
|
|
+ },
|
|
|
/** 确定选择地区 */
|
|
|
submitArea(e: any) {
|
|
|
const selectedOptions: any = e.detail.values
|
|
@@ -185,14 +196,15 @@ Page({
|
|
|
onAddressAfterLeave() {
|
|
|
this.setData({
|
|
|
addressAfterLeave: true,
|
|
|
+ selectAddressId: '',
|
|
|
name: '',
|
|
|
phoneNumber: '',
|
|
|
detailAddress: '',
|
|
|
- cityCode: 0,
|
|
|
+ cityCode: null,
|
|
|
cityName: "",
|
|
|
provinceCode: 0,
|
|
|
provinceName: "",
|
|
|
- regionCode: '',
|
|
|
+ regionCode: null,
|
|
|
regionName: "",
|
|
|
})
|
|
|
},
|