admin: fix form missing on update pages

This commit is contained in:
Jens Langhammer 2020-02-17 21:02:47 +01:00
parent 7cbf20a71c
commit 73b173b92a
1 changed files with 1 additions and 0 deletions

View File

@ -96,6 +96,7 @@ class PropertyMappingUpdateView(
success_message = _("Successfully updated Property Mapping") success_message = _("Successfully updated Property Mapping")
def get_context_data(self, **kwargs): def get_context_data(self, **kwargs):
kwargs = super().get_context_data(**kwargs)
form_cls = self.get_form_class() form_cls = self.get_form_class()
if hasattr(form_cls, "template_name"): if hasattr(form_cls, "template_name"):
kwargs["base_template"] = form_cls.template_name kwargs["base_template"] = form_cls.template_name