feat(M08-D): 补后台订单运营

This commit is contained in:
Codex
2026-08-10 11:52:25 +08:00
parent 3502f5b5f7
commit 20a292e4ce
10 changed files with 619 additions and 37 deletions
+53
View File
@@ -98,6 +98,59 @@ export interface ManagedRoom {
export type RoomInput = Omit<ManagedRoom, 'id'>;
export type OrderStatus =
| 'DRAFT'
| 'PENDING_PAYMENT'
| 'PAID'
| 'RESERVED'
| 'IN_PROGRESS'
| 'FINISHED'
| 'CANCELLED'
| 'REFUNDING'
| 'REFUNDED'
| 'CLOSED';
export type OrderAction =
| 'SUBMIT'
| 'CONFIRM_PAYMENT'
| 'RESERVE'
| 'START'
| 'FINISH'
| 'CANCEL'
| 'BEGIN_REFUND'
| 'COMPLETE_REFUND'
| 'CLOSE';
export interface ManagedOrder {
id: string;
orderNo: string;
storeId: string;
storeName: string;
roomId: string;
roomName: string;
roomNo: string;
status: OrderStatus;
startAt: string;
endAt: string;
totalAmountCents: number;
paidAmountCents: number;
latestPayment: null | { id: string; provider: string; status: string };
createdAt: string;
}
export interface OrderHistoryItem {
id: string;
fromStatus: OrderStatus | null;
toStatus: OrderStatus;
action: OrderAction | 'CREATED' | 'EXPIRED' | 'MIGRATED';
actorType: string;
actorId: string | null;
source: string;
reason: string;
traceId: string;
createdAt: string;
}
export interface BusinessStatistics {
storeId: string;
from: string;