fix(dashboard): display company name instead of ID in health score overview

This commit is contained in:
selfrelease
2026-07-19 21:39:49 +08:00
parent 4980ebcd30
commit 8138fb5540
4 changed files with 20 additions and 11 deletions
@@ -120,7 +120,7 @@ export default function InvestorDashboardPage() {
<div className="flex items-center gap-3">
<HealthScoreBadge score={Math.round(score.total_score)} />
<div>
<p className="text-sm font-medium"> ID: {score.company_id.slice(0, 8)}...</p>
<p className="text-sm font-medium">{score.company_name ?? `企业 ${score.company_id.slice(0, 8)}`}</p>
<p className="text-xs text-muted-foreground">
{new Date(score.calculated_at).toLocaleDateString("zh-CN")}
</p>
+1
View File
@@ -6,6 +6,7 @@ import { apiFetch, type ApiResponse } from "./api";
export interface HealthScore {
id: string;
company_id: string;
company_name: string | null;
total_score: number;
financial_score: number | null;
operational_score: number | null;