Browse Source

修改默认地址checked格式错误的问题;修改编辑地址不回显的问题

zyh
Gao xiaosong 4 years ago
parent
commit
87d0717f78
  1. 8
      components/CitySelect.vue
  2. 6
      manifest.json
  3. 2
      pages/user/address/AddAddress/index.vue
  4. 2
      pages/user/address/AddressManagement/index.vue

8
components/CitySelect.vue

@ -107,14 +107,16 @@ export default {
},
watch: {
items(nextItem) {
console.log(nextItem);
this.province = nextItem;
},
defaultValue(next){
this.value=next
}
},
mounted() {
console.log(this);
if (this.defaultValue) {
this.value = this.defaultValue;
if (this.value) {
this.value = this.value;
}
this.province = this.items;
},

6
manifest.json

@ -20,7 +20,8 @@
"modules" : {
"OAuth" : {},
"Payment" : {},
"Share" : {}
"Share" : {},
"Geolocation" : {}
},
/* */
"distribute" : {
@ -74,7 +75,8 @@
"UniversalLinks" : "https://yixiang.co/app/"
}
},
"ad" : {}
"ad" : {},
"geolocation" : {}
},
"splashscreen" : {
"ios" : {

2
pages/user/address/AddAddress/index.vue

@ -28,7 +28,7 @@
<view class="checkbox-wrapper">
<checkbox-group @change="ChangeIsDefault">
<label class="well-check">
<checkbox value :checked="userAddress.isDefault ? true : false"></checkbox>
<checkbox :value="userAddress.isDefault==1?'checked':''" :checked="userAddress.isDefault ? true : false"></checkbox>
<text class="def">设置为默认地址</text>
</label>
</checkbox-group>

2
pages/user/address/AddressManagement/index.vue

@ -23,7 +23,7 @@
<view class="checkbox-wrapper">
<checkbox-group @change="radioChange(item.id)">
<label class="well-check">
<checkbox value :checked="item.isDefault||item.isDefault=='1' ? true : false"></checkbox>
<checkbox :value="item.isDefault==1?'checked':''" :checked="item.isDefault||item.isDefault=='1' ? true : false"></checkbox>
<text class="default">设为默认</text>
</label>
</checkbox-group>

Loading…
Cancel
Save