fix: use prepared AI analysis outputs
This commit is contained in:
@@ -25,6 +25,11 @@ const riskLabels: Record<string, string> = {
|
||||
unknown: "未知",
|
||||
};
|
||||
|
||||
const statusLabels: Record<ElderAiAnalysisHistoryItem["status"], string> = {
|
||||
completed: "已完成",
|
||||
failed: "未完成",
|
||||
};
|
||||
|
||||
function formatDateTime(value: string): string {
|
||||
return new Date(value).toLocaleString("zh-CN");
|
||||
}
|
||||
@@ -214,7 +219,7 @@ export function ElderAiAnalysisDialog({ elder, onClose, open }: ElderAiAnalysisD
|
||||
</div>
|
||||
<div className="flex items-center gap-2">
|
||||
{item.restricted ? <Badge variant="secondary">受限</Badge> : null}
|
||||
<Badge variant={item.status === "failed" ? "destructive" : "secondary"}>{item.status}</Badge>
|
||||
<Badge variant={item.status === "failed" ? "destructive" : "secondary"}>{statusLabels[item.status]}</Badge>
|
||||
</div>
|
||||
</div>
|
||||
))}
|
||||
|
||||
Reference in New Issue
Block a user