Skip to content

Latest commit

 

History

History
13 lines (9 loc) · 578 Bytes

210_RestrictedNavigation.md

File metadata and controls

13 lines (9 loc) · 578 Bytes

Restricted Navigation

Now - since you have restricted some documents to certain groups, you need to manipulate the pimcore navigation renderer.

Navigation: Do not use the default nav builder extension (pimcore_build_nav). Just use the members_build_nav to build secure menus. Otherwise your restricted pages will show up. This twig extension will also handle your navigation cache strategy.

Usage

{% set nav = members_build_nav(currentDoc, documentRootDoc, null, true) %}
{{ pimcore_render_nav(nav, 'menu', 'renderMenu', { maxDepth: 2 }) }}