|
@@ -13,6 +13,7 @@ import { useEventPoint } from "@/hooks/useEventPoint";
|
|
|
import { useRouter } from "@/i18n/routing";
|
|
|
import { useSystemStore } from "@/stores/useSystemStore";
|
|
|
import { useWalletStore } from "@/stores/useWalletStore";
|
|
|
+import { goBlankPage } from "@/utils";
|
|
|
import { Button, Dialog, Form, Input, Toast } from "antd-mobile";
|
|
|
import BigNumber from "bignumber.js";
|
|
|
import clsx from "clsx";
|
|
@@ -228,15 +229,24 @@ const Deposit = () => {
|
|
|
formInstanceRef.current?.resetFields();
|
|
|
tipModelRef.current?.onClose();
|
|
|
setAmount("");
|
|
|
- // const url =
|
|
|
- // "https://caixa.pay4z.com/brl/qrcode.html?tradeNo=T2501180056ijk21kJ&amount=20&payAmount=20¤cy=BRL&expiredAt=2025-01-18%2001%3A11%3A31&expire=1737173491282&raw=00020101021226870014br.gov.bcb.pix2565qrcode.santsbank.com%2Fdynamic%2Fdc8cf003-1616-47f8-94e6-16be500d05b45204000053039865802BR5907LF%20LTDA6009Sao%20Paulo62070503***6304DF54&type=QRCODE";
|
|
|
-
|
|
|
+ const url =
|
|
|
+ "https://caixa.pay4z.com/brl/qrcode.html?tradeNo=T2501180056ijk21kJ&amount=20&payAmount=20¤cy=BRL&expiredAt=2025-01-18%2001%3A11%3A31&expire=1737173491282&raw=00020101021226870014br.gov.bcb.pix2565qrcode.santsbank.com%2Fdynamic%2Fdc8cf003-1616-47f8-94e6-16be500d05b45204000053039865802BR5907LF%20LTDA6009Sao%20Paulo62070503***6304DF54&type=QRCODE";
|
|
|
+ // const a = document.createElement("a");
|
|
|
+ // a.target = "_blank";
|
|
|
+ // a.href = url;
|
|
|
+ // document.body.append(a);
|
|
|
+ // setTimeout(() => {
|
|
|
+ // a.click();
|
|
|
+ // // window.open(url);
|
|
|
+ // }, 300);
|
|
|
+ goBlankPage(url, "_blank");
|
|
|
if (res.data.pay_url) {
|
|
|
eventInitiate();
|
|
|
+
|
|
|
// fix: ios 限制
|
|
|
- setTimeout(() => {
|
|
|
- window.open(res.data.pay_url);
|
|
|
- }, 0);
|
|
|
+ // setTimeout(() => {
|
|
|
+ // window.open(res.data.pay_url);
|
|
|
+ // }, 0);
|
|
|
} else {
|
|
|
Toast.show({ icon: "success", content: t("code.200"), maskClickable: false });
|
|
|
}
|