--- a/src/pyams_content/features/footer/skin/__init__.py Wed Jun 27 15:32:31 2018 +0200
+++ b/src/pyams_content/features/footer/skin/__init__.py Wed Jun 27 15:33:12 2018 +0200
@@ -24,6 +24,7 @@
# import packages
from pyams_content.features.renderer.skin import BaseContentRenderer
from pyams_utils.adapter import adapter_config
+from pyams_utils.traversing import get_parent
from pyramid.decorator import reify
from pyams_content import _
@@ -39,7 +40,8 @@
context = self.request.annotations.get(DISPLAY_CONTEXT)
if context is None:
context = self.context
- settings = IFooterSettings(context)
+ target = get_parent(context, IFooterTarget)
+ settings = IFooterSettings(target)
while settings.inherit:
settings = IFooterSettings(settings.parent)
return settings.settings
--- a/src/pyams_content/features/header/skin/__init__.py Wed Jun 27 15:32:31 2018 +0200
+++ b/src/pyams_content/features/header/skin/__init__.py Wed Jun 27 15:33:12 2018 +0200
@@ -24,6 +24,7 @@
# import packages
from pyams_content.features.renderer.skin import BaseContentRenderer
from pyams_utils.adapter import adapter_config
+from pyams_utils.traversing import get_parent
from pyramid.decorator import reify
from pyams_content import _
@@ -39,7 +40,8 @@
context = self.request.annotations.get(DISPLAY_CONTEXT)
if context is None:
context = self.context
- settings = IHeaderSettings(context)
+ target = get_parent(context, IHeaderTarget)
+ settings = IHeaderSettings(target)
while settings.inherit:
settings = IHeaderSettings(settings.parent)
return settings.settings