feat: Dashboard MVP with summary API and UI
Add GET /api/v1/dashboards/summary (24h events, open problems, hosts, severity breakdown, recent events) and Vue /dashboard page.
This commit is contained in:
@@ -112,3 +112,11 @@ export async function ackProblem(problemId: number): Promise<{ id: number; statu
|
||||
export async function resolveProblem(problemId: number): Promise<{ id: number; status: string }> {
|
||||
return apiFetch(`/api/v1/problems/${problemId}/resolve`, { method: "POST" });
|
||||
}
|
||||
|
||||
export interface DashboardSummary {
|
||||
events_last_24h: number;
|
||||
hosts_total: number;
|
||||
problems_open: number;
|
||||
severity_24h: Record<string, number>;
|
||||
recent_events: EventSummary[];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user