|
@@ -68,10 +68,11 @@ const Card: FC<PropsWithChildren<CardProps>> = (props) => {
|
|
|
duration: 0,
|
|
|
maskStyle: { zIndex: 99999, background: "rgba(0,0,0,0.5)" },
|
|
|
});
|
|
|
+
|
|
|
const res: any = await systemStore.setupConfig();
|
|
|
if (res?.recharge_enable) {
|
|
|
if (wallet.deposit <= 0) {
|
|
|
- toastRef.current?.hide();
|
|
|
+ toastRef.current?.close();
|
|
|
await feedback.showModal({
|
|
|
content: (modalProps: any) => (
|
|
|
<>
|
|
@@ -110,20 +111,21 @@ const Card: FC<PropsWithChildren<CardProps>> = (props) => {
|
|
|
}
|
|
|
}
|
|
|
if (!wallet?.score || wallet?.score <= 0) {
|
|
|
- toastRef.current?.hide();
|
|
|
+ toastRef.current?.close();
|
|
|
router.push("/deposit");
|
|
|
return;
|
|
|
}
|
|
|
if (!res?.browser_enable) {
|
|
|
if (!isPWAorAPK()) {
|
|
|
if (isIOS()) {
|
|
|
- toastRef.current?.hide();
|
|
|
+ toastRef.current?.close();
|
|
|
await feedback.showImage({
|
|
|
imgUrl: "/store/ios.webp",
|
|
|
});
|
|
|
return;
|
|
|
}
|
|
|
- toastRef.current?.hide();
|
|
|
+
|
|
|
+ toastRef.current?.close();
|
|
|
await feedback.showModal({
|
|
|
content: () => {
|
|
|
return <InstallAPK></InstallAPK>;
|
|
@@ -134,8 +136,6 @@ const Card: FC<PropsWithChildren<CardProps>> = (props) => {
|
|
|
useDefaultFooter: false,
|
|
|
maskClose: true,
|
|
|
});
|
|
|
-
|
|
|
- // dialogManage.showDialog("InstallAPK");
|
|
|
return;
|
|
|
}
|
|
|
}
|
|
@@ -152,20 +152,20 @@ const Card: FC<PropsWithChildren<CardProps>> = (props) => {
|
|
|
const type = getCoinType(game, groupType!);
|
|
|
|
|
|
if (!token) {
|
|
|
- toastRef.current?.hide();
|
|
|
+ toastRef.current?.close();
|
|
|
router.push("/login?redirect=/");
|
|
|
return;
|
|
|
}
|
|
|
// 现金游戏
|
|
|
if (type === 1 && Number(wallet.score) + wallet.point <= 0) {
|
|
|
- toastRef.current?.hide();
|
|
|
+ toastRef.current?.close();
|
|
|
router.push("/deposit");
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
// 免费游戏
|
|
|
if (type === 2 && Number(wallet.free_score) <= 0) {
|
|
|
- toastRef.current?.hide();
|
|
|
+ toastRef.current?.close();
|
|
|
// router.push("/deposit");
|
|
|
Toast.show({
|
|
|
icon: "fail",
|
|
@@ -176,7 +176,7 @@ const Card: FC<PropsWithChildren<CardProps>> = (props) => {
|
|
|
}
|
|
|
// 重玩游戏
|
|
|
if (type === 3 && Number(wallet.lose_score) <= 0) {
|
|
|
- toastRef.current?.hide();
|
|
|
+ toastRef.current?.close();
|
|
|
Toast.show({
|
|
|
icon: "fail",
|
|
|
content: "No replay coins",
|
|
@@ -221,7 +221,7 @@ const Card: FC<PropsWithChildren<CardProps>> = (props) => {
|
|
|
gameRef.current = unfinishedGame;
|
|
|
setVisible(false);
|
|
|
gameModelRef.current?.onOpen();
|
|
|
- toastRef.current?.hide();
|
|
|
+ toastRef.current?.close();
|
|
|
return;
|
|
|
}
|
|
|
getGameUrl(brandRef.current!, params);
|