mirror of
https://github.com/graphql-python/graphene-django.git
synced 2025-01-29 02:34:20 +03:00
Example for order_by being ignored
This commit is contained in:
parent
7210e308ec
commit
2117cb2b01
|
@ -488,18 +488,18 @@ def test_should_query_filter_node_limit():
|
||||||
)
|
)
|
||||||
|
|
||||||
def resolve_all_reporters(self, args, context, info):
|
def resolve_all_reporters(self, args, context, info):
|
||||||
return Reporter.objects.all()
|
return Reporter.objects.order_by('a_choice')
|
||||||
|
|
||||||
r = Reporter.objects.create(
|
|
||||||
first_name='John',
|
|
||||||
last_name='Doe',
|
|
||||||
email='johndoe@example.com',
|
|
||||||
a_choice=1
|
|
||||||
)
|
|
||||||
Reporter.objects.create(
|
Reporter.objects.create(
|
||||||
first_name='Bob',
|
first_name='Bob',
|
||||||
last_name='Doe',
|
last_name='Doe',
|
||||||
email='bobdoe@example.com',
|
email='bobdoe@example.com',
|
||||||
|
a_choice=2
|
||||||
|
)
|
||||||
|
r = Reporter.objects.create(
|
||||||
|
first_name='John',
|
||||||
|
last_name='Doe',
|
||||||
|
email='johndoe@example.com',
|
||||||
a_choice=1
|
a_choice=1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user