refactor(q1): src/api 全量清零 any + types/monitor 扩展输入 DTO

ROADMAP Q1 推进(前端类型安全治理 in_progress):

- src/api/ 整个目录 any 清零(含 monitor/ deploy/ 子目录 12+ 文件)
  create/update 入参 any -> Record<string, unknown> / object
  mock 桩 trace/grafana 对接 types/ 标准类型(Trace/GrafanaDashboard)
  典型接口 LdapFormData/ProbeForm 等强类型表单用 object 接收
- types/monitor.ts 扩展 ~150 行接口:
  ZabbixDatasource / AlertSilence / 7 个输入 DTO
  Trace / TraceSpan / TraceServiceMetrics / GrafanaDashboard / DashboardPanel
  HealthProbeInput

验证:
- 整个 src/api/ 目录 any=0
- ESLint no-explicit-any: 995 -> 937 (本项目此轮贡献 -58)
- tsc -b 零错误, npm run build ✓ (17.06s)
- API 回归 8/8 核心端点通过, Docker 部署 healthy
This commit is contained in:
attacker committed 2026-06-26 03:37:56 +08:00
1 parent 480e677042
commit b553c7956d
436 files changed
+410 -1198

No files matched your search

@@ -0,0 +1 @@
import{h as e}from"./index-o4rKtKfJ.js";const o={list:()=>e.get("/prometheus-datasources"),get:t=>e.get(`/prometheus-datasources/${t}`),create:t=>e.post("/prometheus-datasources",t),update:(t,s)=>e.put(`/prometheus-datasources/${t}`,s),delete:t=>e.delete(`/prometheus-datasources/${t}`),setDefault:t=>e.post(`/prometheus-datasources/${t}/default`),testConnection:t=>e.post("/prometheus-datasources/test",t)},u={list:()=>e.get("/zabbix-datasources"),get:t=>e.get(`/zabbix-datasources/${t}`),create:t=>e.post("/zabbix-datasources",t),update:(t,s)=>e.put(`/zabbix-datasources/${t}`,s),delete:t=>e.delete(`/zabbix-datasources/${t}`),setDefault:t=>e.post(`/zabbix-datasources/${t}/default`),testConnection:t=>e.post("/zabbix-datasources/test",t)};export{o as p,u as z};