66 lines
4.2 KiB
Markdown
66 lines
4.2 KiB
Markdown
|
|
## 1. Backend: Fix Budget Stats DTO and Mapping (Bug #4 & #5 - High Priority)
|
|||
|
|
|
|||
|
|
- [x] 1.1 在 `Application/Dto/BudgetDto.cs` 的 `BudgetStatsDetail` record 中添加 `Trend` 字段(`List<decimal?>`,使用 `init`)
|
|||
|
|
- [x] 1.2 在 `Application/Dto/BudgetDto.cs` 的 `BudgetStatsDetail` record 中添加 `Description` 字段(`string`,使用 `init`)
|
|||
|
|
- [x] 1.3 在 `Application/BudgetApplication.cs` 的 `GetCategoryStatsAsync` 方法中,映射 `Month` 对象时添加 `Trend = stats.Month.Trend`
|
|||
|
|
- [x] 1.4 在 `Application/BudgetApplication.cs` 的 `GetCategoryStatsAsync` 方法中,映射 `Month` 对象时添加 `Description = stats.Month.Description`
|
|||
|
|
- [x] 1.5 在 `Application/BudgetApplication.cs` 的 `GetCategoryStatsAsync` 方法中,映射 `Year` 对象时添加 `Trend = stats.Year.Trend`
|
|||
|
|
- [x] 1.6 在 `Application/BudgetApplication.cs` 的 `GetCategoryStatsAsync` 方法中,映射 `Year` 对象时添加 `Description = stats.Year.Description`
|
|||
|
|
|
|||
|
|
## 2. Backend: Add Unit Tests for DTO Mapping
|
|||
|
|
|
|||
|
|
- [x] 2.1 在 `WebApi.Test/` 中创建 `BudgetApplicationTests.cs` 测试类(如果不存在)
|
|||
|
|
- [x] 2.2 编写测试用例 `GetCategoryStatsAsync_Should_Include_Trend_And_Description_In_Month_Stats`
|
|||
|
|
- [x] 2.3 编写测试用例 `GetCategoryStatsAsync_Should_Include_Trend_And_Description_In_Year_Stats`
|
|||
|
|
- [x] 2.4 运行测试并验证通过:`dotnet test --filter "FullyQualifiedName~BudgetApplicationTests"`
|
|||
|
|
|
|||
|
|
## 3. Frontend: Fix Navigation Routes (Bug #1)
|
|||
|
|
|
|||
|
|
- [x] 3.1 使用 `grep` 搜索底部导航组件代码(搜索关键字 `van-tabbar` 或 `统计`)
|
|||
|
|
- [x] 3.2 定位"统计"标签的路由配置(检查 `to` 或 `path` 属性)
|
|||
|
|
- [x] 3.3 修改路由路径为 `/statistics-v2`
|
|||
|
|
- [x] 3.4 验证路由配置文件 `Web/src/router/index.js` 中存在 `/statistics-v2` 路由定义
|
|||
|
|
|
|||
|
|
## 4. Frontend: Fix Bill Deletion Function (Bug #2)
|
|||
|
|
|
|||
|
|
- [x] 4.1 使用 `grep` 搜索日历页面的账单详情组件(搜索关键字 `删除` 或 `delete`)
|
|||
|
|
- [x] 4.2 定位删除按钮的点击事件绑定(检查 `@click` 或 `onClick`)
|
|||
|
|
- [x] 4.3 实现 `handleDelete` 函数,使用 `showConfirmDialog` 显示确认对话框
|
|||
|
|
- [x] 4.4 在确认后调用删除 API 并关闭弹窗,刷新日历视图
|
|||
|
|
- [x] 4.5 在取消时关闭对话框但保持弹窗打开
|
|||
|
|
- [x] 4.6 处理删除失败场景,显示错误提示
|
|||
|
|
|
|||
|
|
## 5. Frontend: Fix Vant DatetimePicker Registration (Bug #3)
|
|||
|
|
|
|||
|
|
- [x] 5.1 检查 `Web/src/main.ts` 或全局组件注册文件
|
|||
|
|
- [x] 5.2 验证是否导入 `DatetimePicker`(`import { DatetimePicker } from 'vant'`)
|
|||
|
|
- [x] 5.3 如果缺失,添加全局注册 `app.use(DatetimePicker)`
|
|||
|
|
- [ ] 5.4 启动前端开发服务器,验证控制台无 "Failed to resolve component" 警告
|
|||
|
|
|
|||
|
|
## 6. Frontend: Verify Budget Chart Renders Correctly After Backend Fix
|
|||
|
|
|
|||
|
|
- [ ] 6.1 启动后端和前端服务
|
|||
|
|
- [ ] 6.2 打开预算页面,点击"使用情况"或"完成情况"旁的感叹号图标
|
|||
|
|
- [ ] 6.3 验证明细弹窗显示完整的 HTML 表格(非"暂无数据")
|
|||
|
|
- [ ] 6.4 验证燃尽图显示波动曲线(非直线)
|
|||
|
|
- [x] 6.5 检查前端 `BudgetChartAnalysis.vue:603` 和 `:629` 行的 fallback 逻辑是否仍触发(如需修改条件检查)
|
|||
|
|
|
|||
|
|
## 7. Investigation: Budget Card Amount Mismatch (Bug #6 - Low Priority)
|
|||
|
|
|
|||
|
|
- [ ] 7.1 在测试环境中打开预算页面,点击预算卡片的"查询关联账单"按钮
|
|||
|
|
- [ ] 7.2 对比预算卡片显示的"实际"金额与账单列表金额总和
|
|||
|
|
- [ ] 7.3 检查不一致的预算是否标记为硬性预算(📌)
|
|||
|
|
- [ ] 7.4 如果是硬性预算,验证虚拟消耗的计算逻辑(`BudgetService.cs:376-405`)
|
|||
|
|
- [ ] 7.5 检查 `BudgetResult` 中 `PeriodStart` 和 `PeriodEnd` 的赋值是否与 `GetPeriodRange` 一致
|
|||
|
|
- [ ] 7.6 如果是虚拟消耗导致,考虑在前端账单列表中添加提示说明(可选)
|
|||
|
|
- [ ] 7.7 如果是日期范围问题,修复 `BudgetResult` 的赋值逻辑
|
|||
|
|
|
|||
|
|
## 8. End-to-End Verification
|
|||
|
|
|
|||
|
|
- [x] 8.1 运行后端所有测试:`dotnet test`
|
|||
|
|
- [x] 8.2 运行前端 lint:`cd Web && pnpm lint`
|
|||
|
|
- [x] 8.3 构建前端:`cd Web && pnpm build`
|
|||
|
|
- [ ] 8.4 手动测试所有修复的 bug(按 bug-handoff-document.md 中的验证清单)
|
|||
|
|
- [ ] 8.5 清除浏览器缓存并重新测试
|
|||
|
|
- [ ] 8.6 验证控制台无错误或警告
|