Skip to content

Commit 60edcc0

Browse files
committed
resetFilters
1 parent 13b32bd commit 60edcc0

File tree

2 files changed

+11
-10
lines changed

2 files changed

+11
-10
lines changed

services/static-webserver/client/source/class/osparc/dashboard/SearchBarFilter.js

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,6 @@ qx.Class.define("osparc.dashboard.SearchBarFilter", {
172172
this.__hideFilterMenu();
173173
}
174174
}, this);
175-
textField.addListener("changeValue", () => this.__filter(), this);
176175

177176
const resetButton = this.getChildControl("reset-button");
178177
resetButton.addListener("execute", () => this.__resetFilters(), this);
@@ -285,10 +284,6 @@ qx.Class.define("osparc.dashboard.SearchBarFilter", {
285284
});
286285
},
287286

288-
resetSharedWithActiveFilter: function() {
289-
this.__removeChips("shared-with");
290-
this.__filter();
291-
},
292287

293288
setSharedWithActiveFilter: function(optionId, optionLabel) {
294289
this.__removeChips("shared-with");
@@ -353,9 +348,13 @@ qx.Class.define("osparc.dashboard.SearchBarFilter", {
353348
}
354349
},
355350

356-
__resetFilters: function() {
351+
resetFilters: function() {
357352
this.__removeChips();
358353
this.getChildControl("text-field").resetValue();
354+
},
355+
356+
__resetFilters: function() {
357+
this.resetFilters();
359358
this.__filter();
360359
},
361360

services/static-webserver/client/source/class/osparc/dashboard/StudyBrowser.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -916,15 +916,17 @@ qx.Class.define("osparc.dashboard.StudyBrowser", {
916916
this.invalidateStudies();
917917
this._resourcesContainer.setResourcesToList([]);
918918

919-
if (workspaceId === -1) {
920-
// Workspaces
921-
this.__reloadWorkspaces();
922-
} else if (workspaceId === -2) {
919+
if (workspaceId === -2) {
923920
// Search result: no folders, just studies
924921
this.__setFoldersToList([]);
925922
this.__reloadStudies();
923+
} else if (workspaceId === -1) {
924+
// Workspaces
925+
this._searchBarFilter.resetFilters();
926+
this.__reloadWorkspaces();
926927
} else {
927928
// Actual workspace
929+
this._searchBarFilter.resetFilters();
928930
this.__reloadFolders();
929931
this.__reloadStudies();
930932
}

0 commit comments

Comments
 (0)