Added yet another hack to keep the child admin site happy.
This really validates a different solution to the child admin layout, e.g. by registering the models in the regular admin site.fix_request_path_info
parent
39d2da9e68
commit
14a5417891
|
|
@ -126,6 +126,7 @@ class PolymorphicParentModelAdmin(admin.ModelAdmin):
|
||||||
def __init__(self, model, admin_site, *args, **kwargs):
|
def __init__(self, model, admin_site, *args, **kwargs):
|
||||||
super(PolymorphicParentModelAdmin, self).__init__(model, admin_site, *args, **kwargs)
|
super(PolymorphicParentModelAdmin, self).__init__(model, admin_site, *args, **kwargs)
|
||||||
self._child_admin_site = self.admin_site.__class__(name=self.admin_site.name)
|
self._child_admin_site = self.admin_site.__class__(name=self.admin_site.name)
|
||||||
|
self._child_admin_site.get_app_list = lambda request: () # HACK: workaround for Django 1.9
|
||||||
self._is_setup = False
|
self._is_setup = False
|
||||||
|
|
||||||
def _lazy_setup(self):
|
def _lazy_setup(self):
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue