diff --git a/pages/order/MyOrder/index.vue b/pages/order/MyOrder/index.vue index c334e80..727c3e8 100644 --- a/pages/order/MyOrder/index.vue +++ b/pages/order/MyOrder/index.vue @@ -361,6 +361,11 @@ class="bnt service" @click="applyRefund(order)" >{{ '申请退款' }} + 修改地址 { if(success.confirm) { uni.showLoading() - editAddress({ + applyEditAddress({ addressId, orderId: _this._orderId }).then(res => { uni.showToast({ icon: 'success', - title: '修改成功!' + title: '已提交审核' }) uni.setStorageSync('sourceAddress', chooseAddress) _this.changeType() @@ -665,6 +670,21 @@ export default { } }, methods: { + canShowModifyAddress(order) { + if (!order || order.isTravelGroup === 1 || order.isTickets === 1) { + return false + } + const type = parseInt(order._status && order._status._type) + if (type !== 1) { + return false + } + const isAddressUpdate = Number(order.isAddressUpdate || 0) + const addressUpdateStatus = Number(order.addressUpdateStatus || 0) + if (isAddressUpdate === 0) { + return true + } + return addressUpdateStatus === 2 + }, initUserLocation() { uni.getLocation({ type: 'gcj02', diff --git a/pages/order/OrderDetails/index.vue b/pages/order/OrderDetails/index.vue index 3d30e70..7e19123 100644 --- a/pages/order/OrderDetails/index.vue +++ b/pages/order/OrderDetails/index.vue @@ -41,7 +41,7 @@
{{ orderInfo.userAddress }} - 修改地址 + 修改地址
@@ -437,6 +437,7 @@ 联系商家 催发货 + 修改地址 申请退款 @@ -531,7 +532,7 @@