新增支付服务接入与订单收银台
Project CI / AI game creator shell Rust crates (pull_request) Successful in 2m59s
Project CI / Backend tests (pull_request) Failing after 4m8s
Project CI / AI game creator shell Rust lane 1/2 (pull_request) Successful in 5m9s
Project CI / AI game creator shell Rust lane 2/2 (pull_request) Successful in 6m20s
Project CI / Frontend tests (pull_request) Successful in 3m17s
Project CI / AI game creator shell web tests (pull_request) Successful in 2m48s
Project CI / Repository checks (pull_request) Failing after 4m15s
Project CI / Native shell tests (pull_request) Successful in 6m52s
Project CI / AI game creator shell Rust crates (pull_request) Successful in 2m59s
Project CI / Backend tests (pull_request) Failing after 4m8s
Project CI / AI game creator shell Rust lane 1/2 (pull_request) Successful in 5m9s
Project CI / AI game creator shell Rust lane 2/2 (pull_request) Successful in 6m20s
Project CI / Frontend tests (pull_request) Successful in 3m17s
Project CI / AI game creator shell web tests (pull_request) Successful in 2m48s
Project CI / Repository checks (pull_request) Failing after 4m15s
Project CI / Native shell tests (pull_request) Successful in 6m52s
新增支付应用、API Key 与外部产品订单接口 接入微信 Native 下单、二维码收银台与支付结果回调 新增后台支付订单与回调投递页面 补齐 SpacetimeDB 支付表、生成绑定、OpenAPI 与使用说明
This commit is contained in:
@@ -35,6 +35,7 @@ import { FLOATING_FEEDBACK_FORM_URL } from '../common/floatingFeedbackEntryModel
|
||||
import { PlatformActionButton } from '../common/PlatformActionButton';
|
||||
import { PlatformSubpanel } from '../common/PlatformSubpanel';
|
||||
import { ClientDownloadEntry } from '../creation-home/ClientDownloadEntry';
|
||||
import { PaymentCheckoutView } from './PaymentCheckoutView';
|
||||
import {
|
||||
PlatformActiveMobileWelcomeDialog,
|
||||
shouldOpenActiveMobileWelcomeDialog,
|
||||
@@ -46,6 +47,7 @@ import {
|
||||
import { PlatformActiveProfileView } from './PlatformActiveProfileView';
|
||||
import type { PlatformEntryFlowShellProps } from './platformEntryActiveTypes';
|
||||
import { usePlatformDesktopLayout } from './platformEntryResponsive';
|
||||
import { PlatformPaymentServiceView } from './PlatformPaymentServiceView';
|
||||
import { PlatformProfileApiKeysModal } from './PlatformProfileApiKeysModal';
|
||||
import {
|
||||
canPasteFromNativeHostClipboard,
|
||||
@@ -365,6 +367,7 @@ export function PlatformEntryFlowShellImpl({
|
||||
|
||||
const isProfileStage =
|
||||
selectionStage === 'profile' ||
|
||||
selectionStage === 'profile-payment' ||
|
||||
(!isDesktopLayout && selectionStage === 'platform');
|
||||
|
||||
const profileCenter = usePlatformProfileCenterController({
|
||||
@@ -403,6 +406,10 @@ export function PlatformEntryFlowShellImpl({
|
||||
setSelectionStage('profile', { path: '/profile' });
|
||||
}, [setSelectionStage]);
|
||||
|
||||
const openPaymentService = useCallback(() => {
|
||||
setSelectionStage('profile-payment', { path: '/profile/payment' });
|
||||
}, [setSelectionStage]);
|
||||
|
||||
const openGames = useCallback(() => {
|
||||
setSelectionStage('games', { path: '/games' });
|
||||
}, [setSelectionStage]);
|
||||
@@ -575,6 +582,14 @@ export function PlatformEntryFlowShellImpl({
|
||||
);
|
||||
}
|
||||
|
||||
if (selectionStage === 'payment-checkout') {
|
||||
const checkoutToken =
|
||||
typeof window === 'undefined'
|
||||
? ''
|
||||
: (window.location.pathname.split('/').filter(Boolean).at(-1) ?? '');
|
||||
return <PaymentCheckoutView checkoutToken={checkoutToken} />;
|
||||
}
|
||||
|
||||
const isAuthenticated = Boolean(authUi?.user);
|
||||
const balance = mudPointBalance?.totalPoints ?? legacyWalletBalance;
|
||||
const isCreationStage =
|
||||
@@ -770,7 +785,13 @@ export function PlatformEntryFlowShellImpl({
|
||||
id={isCreationStage ? 'platform-tab-panel-create' : undefined}
|
||||
className={`platform-tab-panel min-h-0 min-w-0 flex-1 ${isGamePlayStage ? 'platform-tab-panel--game-play' : 'overflow-auto'} ${isCreationStage || isProfileStage || isGamePlayStage ? '' : 'px-3 py-4 sm:px-6 sm:py-6'}`}
|
||||
>
|
||||
{isProfileStage ? (
|
||||
{selectionStage === 'profile-payment' ? (
|
||||
<PlatformPaymentServiceView
|
||||
user={authUi?.user}
|
||||
onBack={openProfile}
|
||||
onLogin={() => authUi?.openLoginModal()}
|
||||
/>
|
||||
) : isProfileStage ? (
|
||||
<PlatformActiveProfileView
|
||||
dashboard={dashboard}
|
||||
isLoadingDashboard={isLoadingDashboard}
|
||||
@@ -780,6 +801,7 @@ export function PlatformEntryFlowShellImpl({
|
||||
user={authUi?.user}
|
||||
onLogin={() => authUi?.openLoginModal()}
|
||||
onOpenApiKeys={() => setIsApiKeysOpen(true)}
|
||||
onOpenPaymentService={openPaymentService}
|
||||
onOpenCommunity={() =>
|
||||
profileCenter.openProfilePopupPanel('community')
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user