修复平台代管订单流程
This commit is contained in:
@@ -160,6 +160,24 @@ export function handoffStatusLabel(status: string) {
|
||||
return readLabel(handoffStatusMap, status)
|
||||
}
|
||||
|
||||
export function orderHandoffStatusLabel(order?: {
|
||||
handoff_status?: string
|
||||
handoff_mode?: string
|
||||
settlement_mode?: string
|
||||
} | null) {
|
||||
const status = order?.handoff_status || ''
|
||||
if (order?.handoff_mode !== 'platform' && order?.settlement_mode !== 'platform_managed') {
|
||||
return handoffStatusLabel(status)
|
||||
}
|
||||
const platformMap: Record<string, string> = {
|
||||
pending_owner: '待客服交接',
|
||||
owner_timeout: '客服交接超时',
|
||||
pending_owner_checkout: '待客服确认结账',
|
||||
owner_checkout_confirm_timeout: '客服确认结账超时',
|
||||
}
|
||||
return platformMap[status] || handoffStatusLabel(status)
|
||||
}
|
||||
|
||||
export function settlementStatusLabel(status: string) {
|
||||
return readLabel(settlementStatusMap, status)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user