Explorar o código

Update orders.ts

lex-xin hai 6 meses
pai
achega
46e397662e
Modificáronse 1 ficheiros con 8 adicións e 2 borrados
  1. 8 2
      miniprogram/pages/orders/orders.ts

+ 8 - 2
miniprogram/pages/orders/orders.ts

@@ -308,17 +308,23 @@ Page({
     }
 
     if(item.wechatStatus === "REFUNDING") {
+      wx.showLoading({
+        title: '加载中...',
+        mask: true,
+      })
       try {
         const refundOrderId = item.refundOrderId
         const {data} = await api_userPaymentCancelRefund(refundOrderId)
-        console.log(data, 'data')
+        wx.hideLoading()
         if(data.code == 200) {
           wx.showToast({ title: '取消退款成功', icon: 'none' })
           this.onRefoundComfirm()
         } else {
           wx.showToast({ title: data.message, icon: 'none' })
         }
-      } catch {}
+      } catch {
+        wx.hideLoading()
+      }
     } else {
       const { orderNo, studentPaymentOrderDetails } = item
       const goodsInfo: any = {