1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

[2.0.x] Fixed #28849 -- Fixed referenced table and column rename on SQLite.

Thanks Ramiro for the input and Tim for the review.

Backport of 095c1aaa89 from master
This commit is contained in:
Simon Charette
2017-11-26 22:39:43 -05:00
parent 50b35eef0b
commit 31d318d19c
9 changed files with 180 additions and 22 deletions

View File

@@ -103,3 +103,11 @@ class ObjectReference(models.Model):
class RawData(models.Model):
raw_data = models.BinaryField()
class Author(models.Model):
name = models.CharField(max_length=255, unique=True)
class Book(models.Model):
author = models.ForeignKey(Author, models.CASCADE, to_field='name')