1
0
mirror of https://github.com/django/django.git synced 2025-10-27 23:56:08 +00:00

Fixed #24851 -- Fixed crash with reverse one-to-one relation in ModelAdmin.list_display

Forwardport of 2456276b02 from stable/1.8.x
This commit is contained in:
Tim Graham
2015-05-27 11:43:22 -04:00
parent 80ad5472ce
commit ad0f0daf8c
5 changed files with 17 additions and 5 deletions

View File

@@ -83,6 +83,10 @@ class Swallow(models.Model):
ordering = ('speed', 'load')
class SwallowOneToOne(models.Model):
swallow = models.OneToOneField(Swallow)
class UnorderedObject(models.Model):
"""
Model without any defined `Meta.ordering`.