feat: 更新财务系统功能和界面优化

- 优化财务仪表板数据展示
- 增强账户管理功能
- 改进预算和分类管理
- 完善报表和统计分析
- 优化交易管理界面
- 更新Workspace工作区

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
woshiqp465
2025-10-05 15:10:06 +08:00
parent a1dc8de7e5
commit 1def26f74f
35 changed files with 4449 additions and 3000 deletions

View File

@@ -1,5 +1,4 @@
import { getQuery } from 'h3';
import { listExchangeRates } from '~/utils/finance-metadata';
import { useResponseSuccess } from '~/utils/response';
@@ -22,7 +21,10 @@ export default defineEventHandler(async (event) => {
if (date) {
rates = rates.filter((rate) => rate.date === date);
} else if (rates.length > 0) {
const latestDate = rates.reduce((max, rate) => (rate.date > max ? rate.date : max), rates[0].date);
const latestDate = rates.reduce(
(max, rate) => Math.max(rate.date, max),
rates[0].date,
);
rates = rates.filter((rate) => rate.date === latestDate);
}