From 6219a23c6989f4092beba55e64dfaed019c7cba1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=93=E5=B9=B3=E8=89=BA?= <52643018@qq.com> Date: Tue, 3 Aug 2021 17:04:47 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E9=87=87=E8=B4=AD=E5=8D=95?= =?UTF-8?q?=E8=AF=A6=E6=83=85=E9=A1=B5=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- canteen/pages/purchase/detail.vue | 76 +++++++++++++++++-------------- 1 file changed, 41 insertions(+), 35 deletions(-) diff --git a/canteen/pages/purchase/detail.vue b/canteen/pages/purchase/detail.vue index 93ba4e1..528280c 100644 --- a/canteen/pages/purchase/detail.vue +++ b/canteen/pages/purchase/detail.vue @@ -20,26 +20,24 @@ - + - - - 车辆 - {{order.car_license}} - - - 司机 - {{order.deliver_man}} - - - 联系电话 - {{order.deliver_phone}} - - - 收货时间 - {{order.deadline}} - - + + 车辆 + {{order.car_license}} + + + 司机 + {{order.deliver_man}} + + + 联系电话 + {{order.deliver_phone}} + + + 收货时间 + {{order.deadline_text}} + 证明材料-供应端 @@ -303,23 +301,31 @@ }, // 改变订单状态 orderStateChange(state){ - uni.showModal({ - title: '温馨提示', - content: '确定继续退单吗?', - confirmColor: '#FF0000', - cancelColor: '#11D189', - success: result => { - if(result.confirm){ - this.$http(this.API.API_CANTEEN_PURCHASEUPDATE, { - p_sn: this.p_sn, - state: state - }).then(res => { - console.log("orderStateChange", res); - this.$msg('操作成功').then(()=> this.getData()); - }) + let that = this; + if(state == '已退单'){ + uni.showModal({ + title: '温馨提示', + content: '退单前请与供应商协商,以免造成损失!确定继续退单操作吗?', + confirmColor: '#FF0000', + cancelColor: '#11D189', + success: result => { + if(result.confirm){ + $change(); + } } - } - }) + }) + }else{ + $change(); + } + + function $change(){ + that.$http(that.API.API_CANTEEN_PURCHASEUPDATE, { + p_sn: that.p_sn, + state: state + }).then(res => { + that.$msg('操作成功').then(()=> that.getData()); + }) + } } } }