You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by hu...@apache.org on 2023/04/10 22:40:33 UTC
[superset] 02/07: fix: Dashboard not loading with default first value in filter (#23512)
This is an automated email from the ASF dual-hosted git repository.
hugh pushed a commit to branch 2023.13.1
in repository https://gitbox.apache.org/repos/asf/superset.git
commit 73ad7c3cc0ec99b81c5ca68c1d796f3ef821c8ef
Author: Geido <60...@users.noreply.github.com>
AuthorDate: Wed Mar 29 18:18:08 2023 +0200
fix: Dashboard not loading with default first value in filter (#23512)
(cherry picked from commit 4220d32f3d5994f8459dc421d6d2396e7446fdfa)
---
.../src/filters/components/Select/SelectFilterPlugin.tsx | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/superset-frontend/src/filters/components/Select/SelectFilterPlugin.tsx b/superset-frontend/src/filters/components/Select/SelectFilterPlugin.tsx
index d3cb2b4dea..a04606212c 100644
--- a/superset-frontend/src/filters/components/Select/SelectFilterPlugin.tsx
+++ b/superset-frontend/src/filters/components/Select/SelectFilterPlugin.tsx
@@ -129,7 +129,6 @@ export default function PluginFilterSelect(props: PluginFilterSelectProps) {
enableEmptyFilter && !inverseSelection && !values?.length;
const suffix = inverseSelection && values?.length ? t(' (excluded)') : '';
-
dispatchDataMask({
type: 'filterState',
__cache: filterState,
@@ -290,13 +289,9 @@ export default function PluginFilterSelect(props: PluginFilterSelectProps) {
updateDataMask,
data,
groupby,
- JSON.stringify(filterState),
+ JSON.stringify(filterState.value),
]);
- useEffect(() => {
- updateDataMask(filterState.value);
- }, [JSON.stringify(filterState.value)]);
-
useEffect(() => {
setDataMask(dataMask);
}, [JSON.stringify(dataMask)]);