This is a migrated thread and some comments may be shown as answers.

Datasource Filtering for Between

1 Answer 103 Views
Data Source
This is a migrated thread and some comments may be shown as answers.
Daniel
Top achievements
Rank 1
Daniel asked on 06 Mar 2012, 12:16 AM
Trying to get a column filtered to be between two ranges, but it only applies the first filter.

Half borrowed jsfiddle:

http://jsfiddle.net/BmGHB/1/

You can see that if you click the button, then examine the filter using the filter icon on the grid itself, only the first filter has been applied.

Any suggestions?

1 Answer, 1 is accepted

Sort by
0
Daniel
Top achievements
Rank 1
answered on 14 Mar 2012, 07:50 PM
Going through a dozen different search terms for the same problem, I found the answer.

I wasn't setting a logic type, so it was discarding the second filter.

dataSource.filter({ logic: "and", filters: [ <filters here> ] });

Tags
Data Source
Asked by
Daniel
Top achievements
Rank 1
Answers by
Daniel
Top achievements
Rank 1
Share this question
or