Add missing field
parent
0950478fcd
commit
76efd54df5
|
|
@ -1450,6 +1450,13 @@ class Migration(migrations.Migration):
|
|||
to="tests.ParentModelWithManager",
|
||||
),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name="childmodelwithmanager",
|
||||
name="field1",
|
||||
field=models.CharField(
|
||||
max_length=10,
|
||||
),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name="childmodelwithmanager",
|
||||
name="polymorphic_ctype",
|
||||
|
|
|
|||
|
|
@ -222,6 +222,7 @@ class ParentModelWithManager(PolymorphicModel):
|
|||
|
||||
class ChildModelWithManager(PolymorphicModel):
|
||||
# Also test whether foreign keys receive the manager:
|
||||
field1 = models.CharField(max_length=10) # needed as MyManager uses it
|
||||
fk = models.ForeignKey(
|
||||
ParentModelWithManager, on_delete=models.CASCADE, related_name="childmodel_set"
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in New Issue