Skip to content

Commit

Permalink
wc: Perform query when user changes a quick filter #TASK-7216 #TASK-7100
Browse files Browse the repository at this point in the history
  • Loading branch information
jmjuanes committed Jan 13, 2025
1 parent 49e7f20 commit 3055214
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/webcomponents/variant/variant-browser-horizontal-filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,16 @@ export default class VariantBrowserHorizontalFilter extends LitElement {
this.preparedQuery = {...this.preparedQuery};
// this.updateQueryList();
this.notifyQuery(this.preparedQuery);
this.requestUpdate();
// this.requestUpdate();
// check if this is a quick filter --> if so, we have to dispatch the search event
if (this.quickFiltersList.length > 0) {
const filterId = Object.keys(this.mapFilterIdToField)
.find(id => this.mapFilterIdToField[id] === key);
// verify of the filter id is in the quickFiltersList
if (filterId && this.quickFiltersList.find(filter => filter.id === filterId)) {
this.notifySearch(this.preparedQuery);
}
}
}

// DEPRECATED
Expand Down

0 comments on commit 3055214

Please sign in to comment.