Relay filtering single object
See original GitHub issueFor example I have this type, the model is AbstractUser
class UserType(DjangoObjectType):
class Meta:
model = UserModel
interfaces = (graphene.relay.Node, )
filter_fields = ['username']
class Query(graphene.ObjectType):
user = graphene.relay.Node.Field(UserType)
all_users = DjangoFilterConnectionField(UserType)
I want to be able to do this:
query {
user(username: "Bob") {
first_name
last_name
}
}
How I could implement this type of behaviour without using get()
method?
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Django graphene relay restricting queries to objects owned ...
I am using graphene 2, django 2, and django-filter 1.11. class AnimalFilter(django_filters.FilterSet): # Do case-insensitive lookups on 'name' ...
Read more >GraphQL Directives | Relay
The @refetchable directive can only be added to fragments that are "refetchable", that is, on fragments that are declared on Viewer or Query...
Read more >A deep dive into the Relay store - Yash Mahalwal - Medium
We know that getValue works only when the field to be fetched is a primitive or an array of primitive types. But what...
Read more >Getting Started with Lightspeed Filter
Let's get you up and filtering with Lightspeed Filter! First thing is first, let's get your devices setup to be filtered and then...
Read more >Multi-camera Relay Tracker Utilizing Color-Based Particle ...
Multi-camera Relay Tracker Utilizing Color-Based Particle Filtering ... If an object is detected in one camera, the other camera can then be controlled...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ok, I guess I figured it finally, will post my update shortly.
@impowski I’m going to close this issue now. Please do post any updates you have here for posterity.