Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible limitation with or filter #179

Open
kfranqueiro opened this issue Mar 31, 2016 · 1 comment
Open

Possible limitation with or filter #179

kfranqueiro opened this issue Mar 31, 2016 · 1 comment

Comments

@kfranqueiro
Copy link
Member

Originally reported in dojo/dojo1-dgrid#1265, the following doesn't work as expected.

Given a store with data with IDs 1 through 10:

store.filter(new store.Filter().or(
    new store.Filter().gt('id', 7).lt('id', 10),
    new store.Filter().lt('id', 4).gt('id', 1)
));

This results in a collection with no items, whereas you'd expect it to include IDs 2, 3, 8, and 9..

If you remove the chained filters on each of the arguments to or, it works as expected and matches either one.

I'm not sure yet whether this is a bug or a usage issue.

@rgillan
Copy link

rgillan commented Jul 23, 2022

I know this is a really old ticket but we're still using dGrid/dStore and dojo 1.17 (hard to go past such a solid reliable framework). We are running into the store filter.or not filtering the expected results correctly (indeed returns all rows, not excluding those not matched with the or entries). Has anyone looked into this at all before we start digging through the filter code?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants