Commit 30683fac authored by 俞嘉婷's avatar 俞嘉婷

feat: 天降财神道具购买 去掉二次确认弹窗

parent 0caf6301
import Panel from "../../Module/Panel";
import { _decorator, Button, Label, Node, RichText } from "cc";
import { showPanel } from "../../Module/UIFast";
import { showPanel, showToast } from "../../Module/UIFast";
import ToolBuyConfirmPanel from "./ToolBuyConfirmPanel";
import store from "../../store/store";
import { _asyncThrottle } from "../Utils/Utils";
import { sendWebNetWithToken, WebNetName } from "../Utils/WebNet/WebNet";
const {ccclass, property} = _decorator;
......@@ -34,9 +36,19 @@ export default class ToolBuyPanel extends Panel {
}
/** 立即购买 */
async buyHandle() {
this.hidePanel()
showPanel(ToolBuyConfirmPanel);
}
// async buyHandle() {
// this.hidePanel()
// showPanel(ToolBuyConfirmPanel);
// }
// 20240729 去掉二次确认弹窗
/** 确认购买 */
buyHandle = _asyncThrottle(async () => {
const res = await sendWebNetWithToken(WebNetName.buyRichSp);
if (!res?.success) return;
showToast("购买成功~快去使用吧");
this.hidePanel();
})
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment