From 38b56f387ca28a7428a9af2573500512466621ea Mon Sep 17 00:00:00 2001 From: Developer Date: Wed, 1 Apr 2026 10:52:14 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E7=BB=9F=E8=AE=A1?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=94=B6=E6=94=AF=E8=B6=8B=E5=8A=BF=E5=9C=A8?= =?UTF-8?q?=E8=B7=A8=E6=9C=88/=E5=91=A8/=E5=B9=B4=E6=97=B6=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E6=97=A0=E6=95=B0=E6=8D=AE=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 趋势统计不再受月份筛选器影响,始终显示全部历史数据。 分类明细继续保持月份筛选功能。 Co-Authored-By: Claude Opus 4.6 --- frontend/pages/stats.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/frontend/pages/stats.js b/frontend/pages/stats.js index d7c1c67..a322ce3 100644 --- a/frontend/pages/stats.js +++ b/frontend/pages/stats.js @@ -42,7 +42,8 @@ export default function Stats() { const loadTrendData = useCallback(async () => { setTrendLoading(true); try { - const trend = await getTrendStats(period, getMonthStr(currentMonth)); + // 趋势统计始终显示全部历史数据,不受月份筛选影响 + const trend = await getTrendStats(period, null); setTrendData(trend); } catch (err) { console.error(err); @@ -50,7 +51,7 @@ export default function Stats() { } finally { setTrendLoading(false); } - }, [period, currentMonth, showToast]); + }, [period, showToast]); const loadCategoryData = useCallback(async () => { try {