From 9566e0cdb2ae6ac32b9df48c6a94d84e7c30645a Mon Sep 17 00:00:00 2001 From: jialin Date: Sun, 14 Jun 2026 19:19:51 +0800 Subject: [PATCH] fix: queryParams do not be updated timely --- src/pages/usage/summary-tab/index.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/pages/usage/summary-tab/index.tsx b/src/pages/usage/summary-tab/index.tsx index 84d603f7..a1bda4d2 100644 --- a/src/pages/usage/summary-tab/index.tsx +++ b/src/pages/usage/summary-tab/index.tsx @@ -269,6 +269,10 @@ const SummaryTab: React.FC = () => { perPage: 100 }; + if (params) { + setQueryParams(currentParams); + } + // "filter by user" — restricts every resource fetch to these creator ids. const creatorFilter = currentParams.selectedUsers.length ? { creator_ids: currentParams.selectedUsers } @@ -310,7 +314,6 @@ const SummaryTab: React.FC = () => { filters: creatorFilter }) ]); - setQueryParams(currentParams); }; // --- derived: donuts ---