Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Add filters #164
Add filters support for connections.
FilterableConnectionField will create InputFilter object with filters for every Connection's Node's property. The date type will be the same as in Node object. Currenly enums and comlex objects (not scalars) are not supported.
I've added this filter operations:
Multiple filters will always work like AND.
1 similar comment
I think my criticisms are stylistic and personal preference. There's some typos and I personally wouldn't leave TODO comments in a contribution.
I also think that some of your function names as well the use of
However, I don't dispute that this works. I borrowed and adapted it for my own needs and it helped me to understand how arguments are constructed.
Honestly, I'm really not sure what the stance graphql-python has on contributions. If you look across their projects, there are so many ignored questions and contributions in addition to tutorials and examples that don't even work correctly. Either way, I support adding filtering to this similar to how it is done in the graphene-django implementation.
Here is the relevant part of my implementation for comparison: