feat(wallet logs): add reversal transaction type and status labels

1. 新增reversal冲正交易类型到钱包日志参数和筛选选项
2. 将原refund的标签拆分,单独为冲正添加选项
3. 新增已冲正和已人工处理两种交易状态标签
This commit is contained in:
2026-05-14 10:42:29 +08:00
parent ece50ae3b5
commit f777888940
2 changed files with 7 additions and 3 deletions

View File

@@ -20,14 +20,16 @@ export const WALLET_FLOW_FILTERS: { value: string; label: string }[] = [
{ value: "transfer_out", label: "转出" },
{ value: "bet", label: "下注扣款" },
{ value: "prize", label: "派彩" },
{ value: "refund", label: "退本/冲正" },
{ value: "refund", label: "退本" },
{ value: "reversal", label: "冲正" },
];
export function logTypeLabel(t: string): string {
const map: Record<string, string> = {
transfer_in: "转入",
transfer_out: "转出",
refund: "退本/冲正",
refund: "退本",
reversal: "冲正",
bet: "下注扣款",
prize: "派彩",
};
@@ -37,6 +39,8 @@ export function logTypeLabel(t: string): string {
function txnStatusLabel(status: string): string {
if (status === "posted") return "成功";
if (status === "pending_reconcile") return "待对账";
if (status === "reversed") return "已冲正";
if (status === "manually_processed") return "已人工处理";
return status;
}

View File

@@ -42,6 +42,6 @@ export type GetWalletLogsParams = {
page?: number;
/** 每页条数PRD 示例 `size` */
size?: number;
/** 逗号分隔transfer_in,transfer_out,bet,prize,refund */
/** 逗号分隔transfer_in,transfer_out,bet,prize,refund,reversal */
type?: string;
};