fix: hide internal model names in account center
This commit is contained in:
parent
c433b714cd
commit
03cdefca34
@ -29,6 +29,7 @@ function mapLedgerReasonLabel(reason: string) {
|
||||
if (reason === "image_generation") return "图片生成";
|
||||
if (reason === "style_pro_generation") return "风格化 PRO";
|
||||
if (reason === "style_pro_realistic_generation") return "风格化 PRO 实景化";
|
||||
if (reason === "realtime_canvas_generation") return "实时绘画生成";
|
||||
if (reason === "model3d_generation") return "3D模型生成";
|
||||
if (reason === "model3d_task") return "3D模型任务";
|
||||
if (reason === "model3d_task_refund") return "3D模型任务失败退回";
|
||||
@ -71,6 +72,14 @@ function formatLedgerDetail(params: {
|
||||
}
|
||||
|
||||
const trimmedNote = typeof note === "string" ? note.trim() : "";
|
||||
if (reason === "style_pro_realistic_generation") {
|
||||
return "风格化 PRO 实景化生图消耗积分";
|
||||
}
|
||||
if (reason === "realtime_canvas_generation") {
|
||||
const sanitizedRealtimeNote = trimmedNote.replace(/(.*$/, "").trim();
|
||||
return sanitizedRealtimeNote || "实时绘画生成消耗积分";
|
||||
}
|
||||
|
||||
if (reason === "model3d_task") {
|
||||
const taskMatch = trimmedNote.match(MODEL3D_LEDGER_NOTE_WITH_TASK_PATTERN);
|
||||
if (taskMatch) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user