feat: 请求间隔散点图按模型区分颜色

- 后端 get_interval_timeline 接口返回数据添加 model 字段
- 前端散点图按模型分组显示不同颜色的数据点
- 横线统计信息支持按模型分别显示统计数据
- 管理员视图保持按用户分组,用户视图按模型分组
- 更新 mock 数据支持模型字段
This commit is contained in:
fawney19
2025-12-11 21:33:39 +08:00
parent 2dce4102b0
commit 0e8bf0a23b
6 changed files with 199 additions and 46 deletions

View File

@@ -220,6 +220,7 @@ export interface IntervalTimelinePoint {
x: string // ISO 时间字符串
y: number // 间隔分钟数
user_id?: string // 用户 ID仅 include_user_info=true 时存在)
model?: string // 模型名称
}
export interface IntervalTimelineResponse {
@@ -227,6 +228,7 @@ export interface IntervalTimelineResponse {
total_points: number
points: IntervalTimelinePoint[]
users?: Record<string, string> // user_id -> username 映射(仅 include_user_info=true 时存在)
models?: string[] // 出现的模型列表
}
export const cacheAnalysisApi = {