mirror of
https://github.com/graphql-python/graphene-django.git
synced 2025-02-21 05:50:36 +03:00
Merge branch 'master' of github.com:graphql-python/graphene-django
This commit is contained in:
commit
9539d012dd
|
@ -71,7 +71,7 @@ class Query(graphene.ObjectType):
|
||||||
def resolve_users(self):
|
def resolve_users(self):
|
||||||
return UserModel.objects.all()
|
return UserModel.objects.all()
|
||||||
|
|
||||||
schema = graphene.Schema(query=QueryRoot)
|
schema = graphene.Schema(query=Query)
|
||||||
```
|
```
|
||||||
|
|
||||||
Then you can simply query the schema:
|
Then you can simply query the schema:
|
||||||
|
|
|
@ -81,7 +81,7 @@ following:
|
||||||
def resolve_users(self):
|
def resolve_users(self):
|
||||||
return UserModel.objects.all()
|
return UserModel.objects.all()
|
||||||
|
|
||||||
schema = graphene.Schema(query=QueryRoot)
|
schema = graphene.Schema(query=Query)
|
||||||
|
|
||||||
Then you can simply query the schema:
|
Then you can simply query the schema:
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user