This commit is contained in:
2026-08-17 17:49:10 +08:00
parent 911a3620e1
commit c7334b2cf8
30 changed files with 1043 additions and 249 deletions
@@ -115,6 +115,20 @@ export interface PlatformTenantOrderStatistics {
asOf: string
}
export interface PlatformOrderBatchReviewFailure {
orderId: number | string
code: string
message: string
}
export interface PlatformOrderBatchReviewResult {
total: number
successCount: number
failureCount: number
successOrderIds: Array<number | string>
failedOrders: PlatformOrderBatchReviewFailure[]
}
type PlatformFirstLegOrderPagePayload = Omit<PlatformFirstLegOrderPageResource, 'page' | 'size' | 'total' | 'pages'> & {
page: number | string
size: number | string
@@ -176,6 +190,14 @@ export function approvePlatformFirstLegOrder(tenantId: string, orderId: string)
return postData<void>(`/platform/v1/orders/first-leg/${orderId}/approve`, undefined, { tenantId })
}
export function batchApprovePlatformFirstLegOrders(tenantId: string, orderIds: string[]) {
return postData<PlatformOrderBatchReviewResult>(
'/platform/v1/orders/first-leg/batch-approve',
{ orderIds },
{ tenantId },
)
}
export function acceptPlatformFirstLegOrder(tenantId: string, orderId: string) {
return postData<void>(`/platform/v1/orders/first-leg/${orderId}/accept`, undefined, { tenantId })
}