mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Refs #31657 -- Added test for ordering by self-referential ForeignKeys.
This commit is contained in:
committed by
Mariusz Felisiak
parent
a59de6e89e
commit
c1f7de8acc
@@ -18,6 +18,7 @@ from django.db import models
|
||||
|
||||
class Author(models.Model):
|
||||
name = models.CharField(max_length=63, null=True, blank=True)
|
||||
editor = models.ForeignKey('self', models.CASCADE, null=True)
|
||||
|
||||
class Meta:
|
||||
ordering = ('-pk',)
|
||||
|
||||
Reference in New Issue
Block a user