|
@@ -43,6 +43,7 @@ Page({
|
|
|
recordList: [],
|
|
|
maxPage: 1, // 总分页数
|
|
|
refoundStatus: false,
|
|
|
+ cancelRefoundStatus: false,
|
|
|
goodsInfo: {}, // 选中的数据
|
|
|
},
|
|
|
|
|
@@ -202,7 +203,7 @@ Page({
|
|
|
this.onSubmit({orderNo: dataset.orderno})
|
|
|
} else {
|
|
|
wx.navigateTo({
|
|
|
- url: '../orders/order-result?orderNo=' + dataset.orderno
|
|
|
+ url: `../orders/order-result?orderNo=${dataset.orderno}&tabIdx=${this.data.tabIdx}`
|
|
|
})
|
|
|
}
|
|
|
},
|
|
@@ -308,23 +309,23 @@ Page({
|
|
|
}
|
|
|
|
|
|
if(item.wechatStatus === "REFUNDING") {
|
|
|
- wx.showLoading({
|
|
|
- title: '加载中...',
|
|
|
- mask: true,
|
|
|
- })
|
|
|
- try {
|
|
|
- const refundOrderId = item.refundOrderId
|
|
|
- const {data} = await api_userPaymentCancelRefund(refundOrderId)
|
|
|
- wx.hideLoading()
|
|
|
- if(data.code == 200) {
|
|
|
- wx.showToast({ title: '取消退款成功', icon: 'none' })
|
|
|
- this.onRefoundComfirm()
|
|
|
- } else {
|
|
|
- wx.showToast({ title: data.message, icon: 'none' })
|
|
|
+ this.setData({
|
|
|
+ cancelRefoundStatus: true
|
|
|
+ }, async () => {
|
|
|
+ try {
|
|
|
+ const refundOrderId = item.refundOrderId
|
|
|
+ const {data} = await api_userPaymentCancelRefund(refundOrderId)
|
|
|
+ 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 = {
|
|
@@ -342,13 +343,15 @@ Page({
|
|
|
}
|
|
|
this.setData({
|
|
|
goodsInfo,
|
|
|
+ cancelRefoundStatus: true,
|
|
|
refoundStatus: true
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
changeRefoundStatus(e: {detail: any}) {
|
|
|
this.setData({
|
|
|
- refoundStatus: e.detail
|
|
|
+ refoundStatus: e.detail,
|
|
|
+ cancelRefoundStatus: false,
|
|
|
})
|
|
|
},
|
|
|
onRefoundComfirm() {
|
|
@@ -360,6 +363,7 @@ Page({
|
|
|
that.setData({
|
|
|
page: 1,
|
|
|
maxPage: 1,
|
|
|
+ cancelRefoundStatus: false,
|
|
|
recordList: [],
|
|
|
}, () => {
|
|
|
this.getList()
|