From abf8de07d0e5d77d37576925045233e13245faa2 Mon Sep 17 00:00:00 2001 From: himeshr Date: Thu, 1 Aug 2024 14:38:42 +0530 Subject: [PATCH] #1461 | Reflect filter changes immediately --- .../src/action/customDashboard/CustomDashboardActions.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/openchs-android/src/action/customDashboard/CustomDashboardActions.js b/packages/openchs-android/src/action/customDashboard/CustomDashboardActions.js index ba3f45a9a..f6a105f52 100644 --- a/packages/openchs-android/src/action/customDashboard/CustomDashboardActions.js +++ b/packages/openchs-android/src/action/customDashboard/CustomDashboardActions.js @@ -208,6 +208,10 @@ class CustomDashboardActions { static clearCounts(state, action, context) { const newState = {...state}; + const customDashboardService = context.get(CustomDashboardService); + const {selectedFilterValues} = customDashboardService.getDashboardData(state.activeDashboardUUID); + newState.customDashboardFilters = selectedFilterValues; + newState.hasFiltersSet = getHasFiltersSet(selectedFilterValues); newState.cardToCountResultMap = {}; return newState; }