收敛审批动作面板并清理层叠遗留 [approval-action-panel-kiss-layering]

这个提交包含在:
2026-09-03 20:49:15 +08:00
父节点 d63ccdf77c
当前提交 c4b4427f9e
共修改 15 个文件,包含 418 行新增和 106 行删除
@@ -0,0 +1,27 @@
import { reimbursementAmountIntegrityMessage, type ReimbursementAmountSummary } from "./reimbursementWorkspace";
export function resolveReimbursementApprovalBlockReason({
amountIntegrity,
detailState,
online,
snapshotParseStatus,
}: {
amountIntegrity: ReimbursementAmountSummary["integrity"] | null;
detailState: "ready" | "loading" | "error";
online: boolean;
snapshotParseStatus: string | null | undefined;
}) {
if (!online) return "报销审批需联网核对完整报销内容;当前不能通过、退回、驳回或转审。";
if (amountIntegrity && amountIntegrity !== "ready") {
return reimbursementAmountIntegrityMessage(amountIntegrity);
}
if (snapshotParseStatus === "invalid") {
return "提交时检查记录无法解析,暂时不能审批;请联系系统管理员核对。";
}
if (detailState === "error") return "报销内容未加载完整,暂不能审批,请刷新后重试";
if (detailState === "loading") return "正在加载完整报销内容和票据;加载完成前不能作出审批决定。";
if (snapshotParseStatus !== "ready") {
return "提交时检查记录无法解析,暂时不能审批;请联系系统管理员核对。";
}
return null;
}