Skip to content
Snippets Groups Projects
Verified Commit 0384b0fe authored by Jonathan Weth's avatar Jonathan Weth :keyboard:
Browse files

Make virtual foreign key optional

parent 68c58c72
No related branches found
No related tags found
1 merge request!326Make virtual foreign key optional
Pipeline #2998 passed
......@@ -232,7 +232,7 @@ class ExtensibleModel(models.Model, metaclass=_ExtensibleModelBase):
related_name = cls.Meta.default_related_name
# Add field to hold key to foreign model
id_field = to_field_type()
id_field = to_field_type(blank=True, null=True)
cls.field(**{id_field_name: id_field})
@property
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment