🦄 refactor(立减金领取页): 修改文案

This commit is contained in:
wangsongsole 2023-03-01 18:07:04 +08:00
parent 977b59c6fd
commit f899da66af
1 changed files with 10 additions and 12 deletions

View File

@ -117,13 +117,17 @@
return null; return null;
}, },
//获取订单详情 //获取订单详情
getOrderDetail (id) { getOrderDetail (id, isNext = false, message = '') {
req.axiosGet('/voucher/info', { req.axiosGet('/voucher/info', {
order_number: id order_number: id
}).then(res => { }).then(res => {
this.reduceInfo = res.data.rule; this.reduceInfo = res.data.rule;
this.reduceInfo.status = res.data.status; this.reduceInfo.status = res.data.status;
this.couponInfo = res.data; this.couponInfo = res.data;
if (isNext) {
window.location.href = './advise.html';
sessionStorage.setItem('messageTip', message);
}
}).catch(); }).catch();
}, },
toReceive () { toReceive () {
@ -143,14 +147,8 @@
setTimeout(() => { setTimeout(() => {
this.disabledBtn = false; this.disabledBtn = false;
}, 2000); }, 2000);
if (res.code == 200) { const text = res.code == 200 ? '' : res.message;
window.location.href = './advise.html'; this.getOrderDetail(this.orderNumber, true, text);
this.getOrderDetail();
sessionStorage.setItem('messageTip', '');
} else {
window.location.href = './advise.html';
sessionStorage.setItem('messageTip', res.message);
}
}) })
.catch((err) => { }); .catch((err) => { });
}, },
@ -173,13 +171,13 @@
return '立即领取'; return '立即领取';
break; break;
case 1: case 1:
return '充值中'; return '立即领取';
break; break;
case 2: case 2:
return '已完成'; return '已领取';
break; break;
case 3: case 3:
return '充值失败'; return '立即领取';
break; break;
case 5: case 5:
return '已过期'; return '已过期';