diff --git a/pages/users/user_address/index.vue b/pages/users/user_address/index.vue index 18a8c1a..c8f43ab 100644 --- a/pages/users/user_address/index.vue +++ b/pages/users/user_address/index.vue @@ -70,23 +70,28 @@
- + + + + + {{userAddress.detail}} + {{userAddress.address_detail}} + + 修改地址 + + + 选择收货地址 - - - - 柏林湾 - 四川省泸州市龙马潭区陶然路三段1号 - - 修改地址 - + + 门牌号 + - 姓名 --> - - 详细地址 - - @@ -184,7 +184,7 @@ address_id: 0, //地址id userAddress: { is_default: false, - detail: '', + detail: '' }, //地址详情 region: ['省', '市', '区'], valueRegion: [0, 0, 0], @@ -254,7 +254,8 @@ // #ifndef H5 uni.chooseLocation({ success: function(res) { - that.userAddress.detail = res.address; + that.userAddress.detail = res.name + that.userAddress.address_detail = res.address; that.location = `${res.latitude},${res.longitude}`;; } }); @@ -308,9 +309,6 @@ let region = [res.data.province, res.data.city, res.data.district, res.data.street, res .data.village ]; - console.log({ - ...res.data - }); that.$set(that, 'userAddress', res.data); that.$set(that, 'region', region); that.city_id = res.data.city_id @@ -446,7 +444,9 @@ formSubmit: function(e) { let that = this, value = e.detail.value; - value.location = this.location + value.location = that.location + value.detail = that.userAddress.detail + value.address_detail = that.userAddress.address_detail if (!value.real_name) return that.$util.Tips({ title: '请填写收货人姓名'