VanZheng
|
1e61e7a31d
|
feat: add comprehensive Makefile for project management (#1)
* fix: 修复timeRange=7days时的数据加载和显示问题
## 修复内容
### 后端修复 (src/routes/admin.js)
- 添加 /admin/usage-costs 接口对 period=7days 的支持
- 实现7天时间范围的成本统计,汇总最近7天的daily数据
- 修复时区处理不一致导致的数据过滤错误
### 前端修复 (web/admin-spa/src/stores/dashboard.js)
- 修改 loadDashboardData() 支持动态 timeRange 参数
- 根据时间范围动态调整 usage-costs 查询参数
- 消除硬编码的 period=today 和 period=all
### 前端修复 (web/admin-spa/src/views/ApiKeysView.vue)
- 修正API Key详情统计的period计算逻辑
- 7days时间范围现在正确传递 period=daily 而非 monthly
- 确保列表数据和详情统计使用一致的时间范围
## 解决的问题
- 选择"最近7天"时数据显示不准确或缺失
- API Key详情展开时period参数错误
- 成本统计不跟随时间范围选择变化
- 时区计算不一致导致的边界问题
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
* feat: add comprehensive Makefile for project management
- Add common development commands (install, setup, dev, start)
- Add frontend build commands (build-web, build-all)
- Add service management with daemon support
- Add Docker deployment commands
- Add CLI management tools shortcuts
- Add maintenance and monitoring commands
- Include Chinese descriptions for better UX
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
2025-08-06 00:45:28 +08:00 |
|