Skip to content

Commit

Permalink
Merge pull request #189 from jpmorganchase/filters-fix
Browse files Browse the repository at this point in the history
Fixing filters when setting multiple filters per column
  • Loading branch information
texodus authored Aug 13, 2018
2 parents 3edaeb1 + b16fffd commit 6b67811
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions packages/perspective-viewer/src/js/view.js
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -258,17 +258,9 @@ function column_aggregate_clicked() {


function column_filter_clicked() {
let filters = JSON.parse(this.getAttribute('filters'));
let new_filters = this._get_view_filters();
for (let filter of filters) {
let updated_filter = new_filters.find(x => x[0] === filter[0]);
if (updated_filter) {
filter[1] = updated_filter[1];
filter[2] = updated_filter[2];
}
}
this._updating_filter = true;
this.setAttribute('filters', JSON.stringify(filters));
this.setAttribute('filters', JSON.stringify(new_filters));
this._updating_filter = false;
this._debounce_update();
}
Expand Down

0 comments on commit 6b67811

Please sign in to comment.