Skip to content

Commit

Permalink
every category has to be included in a set colum filter
Browse files Browse the repository at this point in the history
  • Loading branch information
sgratzl committed May 3, 2019
1 parent 6649efb commit 8b1f36f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/model/SetColumn.ts
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,11 @@ export default class SetColumn extends ValueColumn<string[]> implements IArrayCo
if (!this.currentFilter) {
return true;
}
return Array.from(this.getSet(row)).some((s) => isCategoryIncluded(this.currentFilter, s));
const v = Array.from(this.getSet(row));
if (v.length === 0) {
return isCategoryIncluded(this.currentFilter, null);
}
return v.every((s) => isCategoryIncluded(this.currentFilter, s));
}

getFilter() {
Expand Down

0 comments on commit 8b1f36f

Please sign in to comment.