Commit 850b797f authored by Xuguangxing's avatar Xuguangxing

fix

parent ccd1e5f6
...@@ -100,13 +100,20 @@ export default { ...@@ -100,13 +100,20 @@ export default {
const { orderNo, reason, payType } = this.$route.query; const { orderNo, reason, payType } = this.$route.query;
const { success } = this.$route.meta; const { success } = this.$route.meta;
// const amount = cookies.get('amount') || {}; // const amount = cookies.get('amount') || {};
try { if (isWxMp) {
const amount = JSON.parse(cookies.get('amount')); // 小程序需要从url当中获取支付金额和优惠金额等参数
this.money = amount.finalAmt || ''; const { amount, freeAmount } = this.$route.query;
this.freeAmount = amount.freeAmount || ''; this.money = amount;
} catch (e) { this.freeAmount = freeAmount;
this.money = ''; } else {
this.freeAmount = ''; try {
const amount = JSON.parse(cookies.get('amount'));
this.money = amount.finalAmt || '';
this.freeAmount = amount.freeAmount || '';
} catch (e) {
this.money = '';
this.freeAmount = '';
}
} }
this.payType = payType || ''; this.payType = payType || '';
this.orderNo = orderNo; this.orderNo = orderNo;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment