diff --git a/app/vip/page.jsx b/app/vip/page.jsx index e501bea..2210241 100644 --- a/app/vip/page.jsx +++ b/app/vip/page.jsx @@ -122,6 +122,22 @@ export default function Vip() { return; } switch (type) { + case "coin": + window.ReactNativeWebView.postMessage( + JSON.stringify({ + type: "COINPAY", + data: { + url: "/api/vas/create_order", + body: { product_id: data.data.product.id }, + product: data.data.product.name, + coinPrice: data.data.product.real_coin_price, + validity: "永久", + info: "", + onPurchaseDone: () => {}, + }, + }) + ); + break; case "iap": window.ReactNativeWebView.postMessage( JSON.stringify({ @@ -290,7 +306,7 @@ export default function Vip() {
createOrder("iap")} + onClick={() => createOrder("coin")} className="flex flex-row cursor-pointer gap-1.5 h-11 items-center justify-center bg-primary rounded-full" >