Code

Ticket #8763: 8763_generic_relations_sort.diff

File 8763_generic_relations_sort.diff, 461 bytes (added by Richard Davies <richard.davies@…>, 6 years ago)
Line 
1Index: tests/modeltests/generic_relations/models.py
2===================================================================
3--- tests/modeltests/generic_relations/models.py        (revision 8798)
4+++ tests/modeltests/generic_relations/models.py        (working copy)
5@@ -22,7 +22,7 @@
6     content_object = generic.GenericForeignKey()
7 
8     class Meta:
9-        ordering = ["tag"]
10+        ordering = ["tag", "-object_id"]
11 
12     def __unicode__(self):
13         return self.tag