MrShi
2026-05-06 e07b79bc313a35d01d150c6a99f5254b026d92db
small-program/pages/new-address/new-address.vue
@@ -89,6 +89,7 @@
      onLoad() {
         const item = uni.getStorageSync('addr');
         if (item) {
            console.log(item,"============================")
            this.type = 2
            uni.setNavigationBarTitle({
               title: '编辑收货地址'
@@ -98,7 +99,9 @@
            this.form.phone = item.phone
            this.form.addr = item.addr
            this.form.areaId = item.areaId
            this.form.areaName = item.areaDetail
            this.form.latitude=item.latitude
            this.form.longitude = item.longitude
            this.form.areaName = (item.provinceName||'') + (item.cityName||'')+(item.districtName||'')
            this.form.isDefault = Number(item.isDefault)
            uni.removeStorageSync('addr');
         }
@@ -108,7 +111,8 @@
         chooseLocation() {
            uni.chooseLocation({
               success: (res) => {
                  this.form.addr = res.name
                  console.log(res,"============================")
                  this.form.addr = res.address
                  this.form.latitude = res.latitude
                  this.form.longitude = res.longitude
               },