From c2e65573ccfa29b6d6e727e93b9552380c520f86 Mon Sep 17 00:00:00 2001 From: Damian Stasik Date: Wed, 26 Jan 2022 23:49:41 +0100 Subject: [PATCH] fix: preserve column sorting preferences in data browser (#2016) --- src/dashboard/Data/Browser/Browser.react.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/dashboard/Data/Browser/Browser.react.js b/src/dashboard/Data/Browser/Browser.react.js index db535207fb..816c038e11 100644 --- a/src/dashboard/Data/Browser/Browser.react.js +++ b/src/dashboard/Data/Browser/Browser.react.js @@ -203,12 +203,13 @@ class Browser extends DashboardView { ), selection: {}, relation: isRelationRoute ? relation : null, + }, () => { + if (isRelationRoute) { + this.fetchRelation(relation, filters); + } else if (className) { + this.fetchData(className, filters); + } }); - if (isRelationRoute) { - this.fetchRelation(relation, filters); - } else if (className) { - this.fetchData(className, filters); - } } extractFiltersFromQuery(props) {