Commit Graph

295 Commits

Author SHA1 Message Date
SunCheng
f46b9d4bd6 feat(frontend): 添加存款明细展示
- 在存款计划弹窗中添加详细明细表格
  - 收入明细列表(显示预算/实际/计算用金额)
  - 支出明细列表(显示超支标记)
  - 计算说明标签(使用预算/使用实际/超支/按天折算)

- 支持新旧版本兼容
  - 有 details 字段时显示详细明细
  - 无 details 字段时显示旧版汇总

- UI 优化
  - 超支项目红色边框高亮
  - 月度/年度标签区分
  - 计算汇总和公式展示
  - 移动端响应式布局
2026-02-20 17:10:33 +08:00
SunCheng
2cb5bffc70 feat(budget): 添加存款明细数据生成逻辑
- 实现 GenerateMonthlyDetails 方法生成月度存款明细
  - 为每个预算项调用 BudgetItemCalculator 计算有效金额
  - 生成计算说明(使用预算/使用实际/超支/按天折算)
  - 标记超支项目
  - 生成汇总信息(总收入、总支出、计划存款)

- GetForMonthAsync 现在返回 Details 字段
  - 包含收入明细列表
  - 包含支出明细列表
  - 包含计算汇总和公式

- 新增集成测试验证 Details 字段生成正确
  - 验证收入项计算规则
  - 验证支出项超支标记
  - 验证硬性支出处理
  - 验证汇总计算

测试结果:58个预算测试全部通过
2026-02-20 16:59:17 +08:00
SunCheng
4cc205fc25 feat(budget): 实现存款明细计算核心逻辑
- 添加 BudgetItemCalculator 辅助类,实现明细项计算规则
  - 收入:实际>0取实际,否则取预算
  - 支出:取MAX(预算, 实际)
  - 硬性支出未发生:按天数折算
  - 归档数据:直接使用实际值

- 实现月度和年度存款核心公式
  - 月度:收入预算 + 本月年度收入 - 支出预算 - 本月年度支出
  - 年度:归档已实收 + 未来收入预算 - 归档已实支 - 未来支出预算

- 定义存款明细数据结构
  - SavingsDetail: 包含收入/支出明细列表和汇总
  - BudgetDetailItem: 预算明细项(含计算用金额、计算说明等)
  - SavingsCalculationSummary: 计算汇总信息

- 新增单元测试
  - BudgetItemCalculatorTest: 11个测试覆盖所有计算规则
  - BudgetSavingsCalculationTest: 6个测试验证核心公式

测试结果:所有测试通过 (366 passed, 0 failed)
2026-02-20 16:26:04 +08:00
SunCheng
32d5ed62d0 fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 16s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-20 14:57:19 +08:00
SunCheng
6e95568906 fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 18s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 0s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-20 13:56:29 +08:00
SunCheng
2cf19a45e5 1
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 23s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-19 22:44:26 +08:00
SunCheng
6922dff5a9 archive: unify-bill-list-ui (2026-02-19)
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 17s
Docker Build & Deploy / Deploy to Production (push) Successful in 7s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 2s
变更已完成并归档:
- 迁移 calendarV2/TransactionList.vue 使用 BillListComponent
- 代码从 403 行简化到 177 行
- 添加左滑删除功能
- Delta spec 已同步到主 specs

提交记录:
- f8e6029: refactor(calendar-v2): migrate TransactionList to BillListComponent
- 4fd190f: fix(calendar-v2): remove left/right padding
- 1ba446f: feat(calendar-v2): add delete functionality
- d324769: specs: sync bill-list-unified-ui
2026-02-19 22:08:10 +08:00
SunCheng
d324769795 specs: sync bill-list-unified-ui from unify-bill-list-ui change
同步新的统一账单列表 UI 规范到主 specs
- 定义所有账单列表必须遵循的视觉设计和交互模式
- 包含 7 个核心需求和多个可测试场景
2026-02-19 22:07:33 +08:00
SunCheng
1ba446f05a feat(calendar-v2): add delete functionality to transaction list
添加左滑删除功能:
- 启用 show-delete prop
- 实现 onTransactionDelete 事件处理器
- 删除后更新本地列表数据
2026-02-19 22:03:24 +08:00
SunCheng
4fd190f461 fix(calendar-v2): remove left/right padding from BillListComponent
添加样式覆盖,移除 van-cell-group 和 van-list 的左右内边距,
确保账单列表在日历视图中无左右空白
2026-02-19 21:56:23 +08:00
SunCheng
9eb712cc44 chore: add openspec artifacts for unify-bill-list-ui change 2026-02-19 21:54:33 +08:00
SunCheng
4f6b634e68 docs: add migration record and update task status 2026-02-19 21:54:16 +08:00
SunCheng
cdd20352a3 docs: update unify-bill-list-ui change scope
更新变更范围以反映实际情况:
- 实际只需迁移 1 个页面: calendarV2/TransactionList.vue
- 其他页面要么已使用 BillListComponent,要么不是账单列表
- 更新 proposal、design 和 tasks 文档
2026-02-19 21:53:34 +08:00
SunCheng
f8e6029108 refactor(calendar-v2): migrate TransactionList to BillListComponent
- 使用统一的 BillListComponent 替换自定义账单列表
- 保留自定义 header (交易记录标题 + Items 计数 + Smart 按钮)
- 移除数据格式转换逻辑,直接传递原始数据
- 简化代码从 403 行减少到 177 行
- 配置: data-source=custom, enable-filter=false, show-delete=false
2026-02-19 21:52:23 +08:00
SunCheng
7a39258bc8 fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 17s
Docker Build & Deploy / Deploy to Production (push) Successful in 8s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-19 21:34:55 +08:00
SunCheng
986f46b84c fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 20s
Docker Build & Deploy / Deploy to Production (push) Successful in 5s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-19 21:10:29 +08:00
SunCheng
3402ffaae2 fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 3m13s
Docker Build & Deploy / Deploy to Production (push) Successful in 8s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-19 11:04:05 +08:00
SunCheng
6ca00c1478 feat: 将默认首页改为日历页面
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 16s
Docker Build & Deploy / Deploy to Production (push) Successful in 5s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
- 添加根路径 / 重定向到日历页面 calendar-v2
- 修改已登录用户访问登录页时的跳转目标为日历页面
- 现在访问 http://localhost:5173/ 会直接进入日历页面
2026-02-18 22:20:42 +08:00
SunCheng
0101c3e366 fix: 修复图表组件运行时错误
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 16s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
- 将 getChartOptionsByType 替换为 getChartOptions
- 修复 MonthlyExpenseCard.vue 中的图表配置
- 修复 ExpenseCategoryCard.vue 中的图表配置
- 修复 BudgetChartAnalysis.vue 中的图表配置
- 统计页面、日历页面、预算页面运行正常,无控制台错误
2026-02-18 22:19:25 +08:00
SunCheng
5e38a52e5b fix: 修复 TypeScript interface 语法错误
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 18s
Docker Build & Deploy / Deploy to Production (push) Successful in 5s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 2s
- 将 BaseChart.vue、Icon.vue、IconSelector.vue 从 TypeScript 转换为 JavaScript
- 移除 interface 声明,改用 defineProps 对象语法
- 移除类型注解,保持 JavaScript 兼容性
- 修复 ESLint 解析错误,现在所有 lint 检查通过
2026-02-18 22:09:19 +08:00
SunCheng
c49f66757e 1
Some checks failed
Docker Build & Deploy / Build Docker Image (push) Waiting to run
Docker Build & Deploy / Deploy to Production (push) Has been cancelled
Docker Build & Deploy / Cleanup Dangling Images (push) Has been cancelled
Docker Build & Deploy / WeChat Notification (push) Has been cancelled
2026-02-18 21:16:45 +08:00
SunCheng
77c9b47246 Merge branch 'main' of ssh://suncheng.asia:14222/suncheng/EmailBill into feature/remove-v1-modules
Some checks failed
Docker Build & Deploy / Deploy to Production (push) Has been cancelled
Docker Build & Deploy / Cleanup Dangling Images (push) Has been cancelled
Docker Build & Deploy / WeChat Notification (push) Has been cancelled
Docker Build & Deploy / Build Docker Image (push) Has been cancelled
2026-02-18 21:15:13 +08:00
SunCheng
a21c533ba5 fix: 修复账单列表分页bug并优化日期和图标显示
- 修复分页并发加载bug,防止重复请求同一页数据
- 优化日期格式显示,从 HH:mm 改为 MM-DD HH:mm
- 集成分类真实图标,支持 Iconify 格式,替换默认五角星图标
- 添加图标加载降级机制,确保兼容性
2026-02-18 21:14:54 +08:00
SunCheng
61aa19b3d2 style: unify card styles across calendar, statistics, and budget pages
- 调整 theme.css 中的 --radius-lg 为 12px 以符合设计标准
- 统一日历页面卡片样式(padding, border-radius, shadow)
- 统一统计页面所有卡片组件的样式
- 统一预算页面图表卡片样式,替换硬编码值为 CSS 变量
- 为关键样式添加 fallback 值以防止变量未定义
- 所有卡片现在使用统一的样式变量:
  - padding: var(--spacing-xl, 16px)
  - border-radius: var(--radius-lg, 12px)
  - box-shadow: var(--shadow-sm)
  - background: var(--bg-secondary)
2026-02-18 20:44:58 +08:00
SunCheng
c1e2adacea chore: archive migrate-remaining-echarts-to-chartjs change
- Synced chart-migration-patterns spec to main specs
- Archived to openspec/changes/archive/2026-02-16-migrate-remaining-echarts-to-chartjs
- All artifacts complete, 57/80 tasks complete (23 test tasks skipped)

Schema: spec-driven
Status: ✓ Complete with warnings (test tasks skipped)
2026-02-16 22:40:13 +08:00
SunCheng
d1737f162d fix: add defensive checks to BudgetChartAnalysis chart data
- Added null checks for overallStats.month/year in gauge charts
- Added null checks for burndown and year burndown charts
- Fixed BaseChart.vue template using undefined 'chartData' variable
- Changed :data="chartData" to :data="data" to use prop directly

Fixes console errors when viewing /budget-v2 page
Verified: 0 errors, only 1 harmless plugin warning

Refs: openspec/changes/migrate-remaining-echarts-to-chartjs
2026-02-16 22:04:10 +08:00
SunCheng
9921cd5fdf chore: migrate remaining ECharts components to Chart.js
- Migrated 4 components from ECharts to Chart.js:
  * MonthlyExpenseCard.vue (折线图)
  * DailyTrendChart.vue (双系列折线图)
  * ExpenseCategoryCard.vue (环形图)
  * BudgetChartAnalysis.vue (仪表盘 + 多种图表)

- Removed all ECharts imports and environment variable switches
- Unified all charts to use BaseChart.vue component
- Build verified: pnpm build success ✓
- No echarts imports remaining ✓

Refs: openspec/changes/migrate-remaining-echarts-to-chartjs
2026-02-16 21:55:38 +08:00
fac83eb09a Merge pull request 'feature/remove-v1-modules' (#1) from feature/remove-v1-modules into main
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 39s
Docker Build & Deploy / Deploy to Production (push) Successful in 8s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 2s
Docker Build & Deploy / WeChat Notification (push) Successful in 2s
Reviewed-on: #1
2026-02-15 10:12:18 +08:00
SunCheng
a88556c784 fix 2026-02-15 10:10:28 +08:00
SunCheng
e51a3edd50 refactor: 统一账单列表组件,封装 BillListComponent
- 创建 BillListComponent 组件(基于 v2 风格,紧凑布局)
  - 支持筛选(类型、分类、日期范围)和排序(金额、时间)
  - 支持分页加载、左滑删除、点击详情、多选模式
  - 支持 API 自动加载和 Custom 自定义数据两种模式
- 迁移 6 个页面/组件到新组件:
  - TransactionsRecord.vue
  - EmailRecord.vue
  - ClassificationNLP.vue
  - UnconfirmedClassification.vue
  - BudgetCard.vue
  - ReasonGroupList.vue
- 删除旧版 TransactionList 组件
- 保留 CalendarV2 的特殊版本(有专用功能)
- 添加完整的使用文档和 JSDoc 注释
2026-02-15 10:08:14 +08:00
SunCheng
6f725dbb13 fix: 修复收入预算计算和添加存款计划明细功能
问题1:修复收入预算实际金额计算
- 在 BudgetRepository.cs 中修复 SelectedCategories.Split 逻辑
- 添加 StringSplitOptions.RemoveEmptyEntries 和 StringSplitOptions.TrimEntries 参数
- 添加单元测试验证修复

问题2:添加存款计划明细按钮和弹窗
- 在 BudgetCard.vue 中添加 'show-detail' emit
- 为存款计划卡片(category === 2)添加明细按钮
- 在 SavingsBudgetContent.vue 中实现明细弹窗
- 弹窗显示:收入预算、支出预算、计划存款公式、存款结果

问题3:统一卡片样式
- 修复 BudgetChartAnalysis.vue 的卡片样式
- 使用 16px 圆角、增强阴影和边框
2026-02-14 12:58:26 +08:00
SunCheng
a7954f55ad feat: remove V1 calendar/budget/stats modules
- 删除 V1 前端页面 (CalendarView, BudgetView, statisticsV1)
- 移除 V1 路由配置 (/calendar, /budget, /)
- 清理路由守卫中的 V1 版本切换逻辑
- 移除设置页面中的版本切换功能
- 更新底部导航和登录重定向到 V2 路由
- 移除 App.vue 中 V1 页面的缓存配置
- 删除后端 TransactionRecordController.GetDailyStatisticsAsync (Obsolete)
- 删除 TransactionStatisticsController.GetBalanceStatisticsAsync
- 保留 V2 仍在使用的共享 API (GetUncoveredCategories, GetArchiveSummary, GetDailyStatistics)
- 保留 V2 使用的全局事件监听机制
- 所有测试通过 (210/210)

Breaking Change: V1 API 端点和路由将不可用
2026-02-14 00:01:44 +08:00
SunCheng
162b6d02dd fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 26s
Docker Build & Deploy / Deploy to Production (push) Successful in 8s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 2s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-13 22:49:07 +08:00
SunCheng
803f09cc97 feat(calendar): simplify holiday highlight styles and improve accessibility
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 27s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 2s
Docker Build & Deploy / WeChat Notification (push) Successful in 2s
- Introduced a new visual style for holiday highlights in the calendar component, replacing complex gradients with solid colors for better clarity.
- Removed the holiday badge to reduce visual noise and enhance user experience.
- Ensured that holiday information remains accessible through long-press interactions.
- Updated specifications to reflect the new design decisions and requirements for both light and dark themes.
- Added tasks for implementation, including style adjustments and accessibility enhancements.
2026-02-12 21:39:27 +08:00
SunCheng
aff0cbb55e refactor: 移除调试代码,优化底部导航样式
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 20s
Docker Build & Deploy / Deploy to Production (push) Successful in 7s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 2s
2026-02-11 17:30:13 +08:00
SunCheng
d439beb32d 1
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 20s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 17:25:37 +08:00
SunCheng
841b53e75b fix
All checks were successful
Docker Build & Deploy / Deploy to Production (push) Successful in 7s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
Docker Build & Deploy / Build Docker Image (push) Successful in 21s
2026-02-11 17:18:37 +08:00
SunCheng
0fed10b60d 1
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 21s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
2026-02-11 17:05:18 +08:00
SunCheng
d8a7c11490 1
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 19s
Docker Build & Deploy / Deploy to Production (push) Successful in 5s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 16:28:46 +08:00
SunCheng
4e840e8e56 1
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 22s
Docker Build & Deploy / Deploy to Production (push) Successful in 7s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 16:24:40 +08:00
SunCheng
36e0a933f6 fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 25s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 16:09:04 +08:00
SunCheng
91389353ad fix
Some checks failed
Docker Build & Deploy / Deploy to Production (push) Blocked by required conditions
Docker Build & Deploy / Build Docker Image (push) Successful in 2m46s
Docker Build & Deploy / Cleanup Dangling Images (push) Has been cancelled
Docker Build & Deploy / WeChat Notification (push) Has been cancelled
2026-02-11 15:33:09 +08:00
SunCheng
fe5de8bbcd fix: 优化 TabBar 样式和调试信息展示,确保在 PWA 中正确贴底
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 1m16s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 15:19:30 +08:00
SunCheng
00c6787430 refactor: 移除调试信息面板的详细信息展示
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 20s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 2s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 15:00:25 +08:00
SunCheng
02d7727ae6 feat: 添加调试信息面板,显示容器高度、TabBar 位置和尺寸等信息
Some checks failed
Docker Build & Deploy / Build Docker Image (push) Failing after 4m6s
Docker Build & Deploy / Deploy to Production (push) Has been skipped
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 14:53:49 +08:00
SunCheng
dfa2c405c5 fix: 优化底部导航栏样式,调整高度和盒模型设置
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 23s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 14:47:53 +08:00
SunCheng
0d649b76a2 feat: 添加调试信息面板,优化主题色彩和底部导航栏布局
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 23s
Docker Build & Deploy / Deploy to Production (push) Successful in 8s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 14:42:46 +08:00
SunCheng
e491856e28 fix: 统一主题色彩系统,优化底部导航栏间距
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 22s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
- 新建 theme.css 定义 CSS 变量,统一亮色/暗色主题色彩
- 新建 layout.css 优化底部导航栏布局
- 在 App.vue 中添加 Vant UI 主题变量映射
- 修复底部导航栏与屏幕底部间距过大问题
- 添加安全区域(safe-area-inset)处理
2026-02-11 14:29:31 +08:00
SunCheng
51172e8c5a fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 4m27s
Docker Build & Deploy / Deploy to Production (push) Successful in 7s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
2026-02-11 13:00:01 +08:00
SunCheng
ca3e929770 fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 18s
Docker Build & Deploy / Deploy to Production (push) Successful in 8s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 2s
2026-02-10 19:51:20 +08:00