From 1e6f1628b524b22266553e5e7620ab326c1aae94 Mon Sep 17 00:00:00 2001 From: yezian Date: Tue, 27 Feb 2024 00:00:40 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=8A=E7=BA=BF=E5=BE=AE=E4=BF=A1h5=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 | 9 ++++----- app/vip/page.jsx | 9 ++++++++- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/app/pay/page.jsx b/app/pay/page.jsx index 8b0ee27..465ac05 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: base?.b_mid !== 153 ? type : "wxpay_h5", + pay_type: type, from: "app", }; //如果是微信jsapi支付直接跳转到中间页 - if (type === "wxpay_jsapi" && base?.b_mid !== 153) { + if (type === "wxpay_jsapi") { router.push(`/pay/${encodeURIComponent(JSON.stringify(body))}`); return; } @@ -122,7 +122,6 @@ export default function Pay() { } ); const data = await response.json(); - console.log(JSON.stringify(body), data); if (data.ret === -1) { Toast.show({ content: data.msg, @@ -133,7 +132,7 @@ export default function Pay() { case "alipay_h5": router.push(`${data.data.alipay_h5_param_str}`); break; - case "wxpay_jsapi": + case "wxpay_h5": router.push( `https://weixin.tiefen.fun/pay/wxpay_h5/${encodeURIComponent( data.data.wxpay_h5_param_str @@ -290,7 +289,7 @@ export default function Pay() { */}
*/}
createOrder("wxpay_jsapi")} + onClick={() => createOrder("wxpay_h5")} className="flex flex-row cursor-pointer gap-1.5 h-11 items-center justify-center bg-primary rounded-full" >