diff --git a/app/pay/[weixin]/page.jsx b/app/pay/[weixin]/page.jsx index be97480..d677db9 100644 --- a/app/pay/[weixin]/page.jsx +++ b/app/pay/[weixin]/page.jsx @@ -14,10 +14,12 @@ export default function Weixin({ params }) { const [isLoading, setIsLoading] = useState(true); useEffect(() => { var QRCode = require("qrcode"); - const weixinUrl = decodeURIComponent(params.weixin); - QRCode.toDataURL(weixinUrl, function (err, url) { - setQrcodeUrl(url); - }); + QRCode.toDataURL( + `https://tiefen.fun/pay/inweixin/${params.weixin}`, + function (err, url) { + setQrcodeUrl(url); + } + ); //确认设备类型 const base = webviewBaseRequest(); if (base?.b_dt === 1) setDevice(1); diff --git a/app/pay/inweixin/[weixin]/page.jsx b/app/pay/inweixin/[weixin]/page.jsx new file mode 100644 index 0000000..8167ab4 --- /dev/null +++ b/app/pay/inweixin/[weixin]/page.jsx @@ -0,0 +1,32 @@ +"use client"; + +import React, { useEffect } from "react"; +import { useRouter } from "next/navigation"; + +export default function SafePay({ params }) { + const router = useRouter(); + useEffect(() => { + const weixinUrl = decodeURIComponent(params.weixin); + router.push(weixinUrl); + }, []); + + return ( +
+
+

+ 微信安全支付 +

+
+
+
+ + + +

正在跳转...

+
+
+ ); +}