feat: 重构管理端列表与风控/结算导航,新增表格导出和结算审核确认

This commit is contained in:
2026-05-19 17:06:56 +08:00
parent a1fb163f1b
commit 37b13278ef
47 changed files with 1255 additions and 524 deletions

View File

@@ -33,6 +33,12 @@ import {
PRD_PAYOUT_REVIEW,
} from "./draw-prd";
function drawStatusText(status: string, t: (key: string) => string): string {
const key = `statusOptions.${status}`;
const translated = t(key);
return translated === key ? status : translated;
}
function Field({ label, children }: { label: string; children: React.ReactNode }) {
return (
<div className="grid gap-1 sm:grid-cols-[10rem_1fr] sm:items-start">
@@ -114,12 +120,16 @@ export function DrawDetailConsole({ drawId }: { drawId: string }) {
<CardTitle className="text-xl">{data.draw_no}</CardTitle>
<p className="mt-1 text-sm text-muted-foreground">{t("drawDetail")}</p>
</div>
<div className="flex flex-wrap items-center gap-2">
<DrawStatusBadge status={data.status} label={data.status} />
<div className="flex flex-col items-end gap-1 text-right">
<DrawStatusBadge
status={data.hall_preview_status}
label={t("hallPreviewStatus", { status: data.hall_preview_status })}
status={data.status}
label={drawStatusText(data.status, t)}
/>
<p className="text-sm text-muted-foreground">
{t("hallPreviewStatus", {
status: drawStatusText(data.hall_preview_status, t),
})}
</p>
</div>
</div>
</CardHeader>