From ee46b246eae1f1cf47b2a559ab93194e28b59a18 Mon Sep 17 00:00:00 2001 From: yezian Date: Mon, 26 Feb 2024 22:49:03 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=8B=E8=AF=95=E5=BE=AE=E4=BF=A1=E6=94=AF?= =?UTF-8?q?=E4=BB=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/pay/page.jsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/pay/page.jsx b/app/pay/page.jsx index b85f9ac..3a9cf10 100644 --- a/app/pay/page.jsx +++ b/app/pay/page.jsx @@ -97,12 +97,12 @@ export default function Pay() { ...base, product_id: customCoin.selected ? "h5_custom_coin" : selectedPrice.id, custom_coins: customCoin.selected ? customCoin.num : 0, - pay_type: type, + pay_type: base?.b_mid !== 153 ? type : "wxpay_h5", from: "app", }; //如果是微信jsapi支付直接跳转到中间页 - if (type === "wxpay_h5" && base?.b_mid !== 153) { + if (type === "wxpay_jsapi" && base?.b_mid !== 153) { router.push(`/pay/${encodeURIComponent(JSON.stringify(body))}`); return; } @@ -122,7 +122,7 @@ export default function Pay() { } ); const data = await response.json(); - console.log(data); + console.log(JSON.stringify(body), data); if (data.ret === -1) { Toast.show({ content: data.msg, @@ -133,7 +133,7 @@ export default function Pay() { case "alipay_h5": router.push(`${data.data.alipay_h5_param_str}`); break; - case "wxpay_h5": + case "wxpay_jsapi": router.push(`${data.data.wxpay_h5_param_str}`); break; default: @@ -286,7 +286,7 @@ export default function Pay() { */}