Rename the get_menu_links and get_menus_links to navigation_resolve_menu. Change the return value of the menu resolving to include the resolved object. Update the links display templates to show which object the links belong to when there is more than one object. Update the links display templates to show which menu the links belong to when there is more than one menu. Remove the sidebar menu and unify its links with the secondary menu. Signed-off-by: Roberto Rosario <Roberto.Rosario@mayan-edms.com>
44 lines
1.9 KiB
HTML
44 lines
1.9 KiB
HTML
{% load i18n %}
|
|
|
|
{% load navigation_tags %}
|
|
{% load smart_settings_tags %}
|
|
|
|
{% spaceless %}
|
|
<nav class="navbar navbar-default navbar-fixed-top">
|
|
<div class="container-fluid">
|
|
<div class="navbar-header">
|
|
<button aria-expanded="false" aria-controls="navbar" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" type="button">
|
|
<span class="sr-only">{% trans 'Toggle navigation' %}</span>
|
|
<span class="icon-bar"></span>
|
|
<span class="icon-bar"></span>
|
|
<span class="icon-bar"></span>
|
|
</button>
|
|
<a class="navbar-brand" href="{% url home_view %}">{% smart_setting 'COMMON_PROJECT_TITLE' %}</a>
|
|
</div>
|
|
|
|
<div id="navbar" class="navbar-collapse collapse">
|
|
<ul class="nav navbar-nav navbar-right">
|
|
{% navigation_resolve_menu name='topbar' as topbar_menus_results %}
|
|
{% for tobpar_menu_result in topbar_menus_results %}
|
|
{% for link_group in tobpar_menu_result.link_groups %}
|
|
{% for link in link_group.links %}
|
|
{% with 'true' as as_li %}
|
|
{% with 'true' as hide_active_anchor %}
|
|
{% with 'active' as li_class_active %}
|
|
{% with 'first' as li_class_first %}
|
|
{% with ' ' as link_classes %}
|
|
{% include 'navigation/generic_subnavigation.html' %}
|
|
{% endwith %}
|
|
{% endwith %}
|
|
{% endwith %}
|
|
{% endwith %}
|
|
{% endwith %}
|
|
{% endfor %}
|
|
{% endfor %}
|
|
{% endfor %}
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
{% endspaceless %}
|