Updated internal link management
authorThierry Florac <thierry.florac@onf.fr>
Thu, 12 Jul 2018 17:37:06 +0200
changeset 92 b3b7ec7530f5
parent 91 d11056520bf5
child 93 d3ef1b0cc076
Updated internal link management
src/pyams_default_theme/features/header/skin/templates/simple-header.pt
src/pyams_default_theme/features/menu/__init__.py
--- a/src/pyams_default_theme/features/header/skin/templates/simple-header.pt	Thu Jul 12 17:36:48 2018 +0200
+++ b/src/pyams_default_theme/features/header/skin/templates/simple-header.pt	Thu Jul 12 17:37:06 2018 +0200
@@ -2,7 +2,7 @@
 	 tal:define="settings view.settings" i18n:domain="pyams_default_theme">
 	<tal:var replace="structure provider:pyams.banner" />
 	<ul class="nav nav-tabs" role="tablist">
-		<tal:loop repeat="link settings.tabs.get_visible_items()">
+		<tal:loop repeat="link settings.tabs.get_visible_items(request)">
 			<li role="presentation"
 				tal:attributes="class 'active' if view.is_active(link) else ''">
 				<a tal:define="info view.get_link_info(link);
--- a/src/pyams_default_theme/features/menu/__init__.py	Thu Jul 12 17:36:48 2018 +0200
+++ b/src/pyams_default_theme/features/menu/__init__.py	Thu Jul 12 17:37:06 2018 +0200
@@ -19,13 +19,13 @@
 from pyams_content.component.illustration import IBasicIllustration
 from pyams_content.component.links.interfaces import IBaseLink, IInternalLink
 from pyams_default_theme.interfaces import IContentNavigationIllustration
-from pyams_skin.layer import IPyAMSUserLayer
+from pyams_skin.layer import IPyAMSLayer
 
 # import packages
 from pyams_utils.adapter import adapter_config
 
 
-@adapter_config(context=(IBaseLink, IPyAMSUserLayer), provides=IContentNavigationIllustration)
+@adapter_config(context=(IBaseLink, IPyAMSLayer), provides=IContentNavigationIllustration)
 def base_link_navigation_illustration_adapter(context, request):
     """Base link navigation illustration adapter"""
     illustration = IBasicIllustration(context, None)