Fix navbar
This commit is contained in:
parent
ae1731593f
commit
7b18e02c7e
|
@ -58,13 +58,24 @@
|
|||
</button>
|
||||
<div class="collapse navbar-collapse" id="target-main">
|
||||
<ul class="navbar-nav justify-content-center w-100 icms-menu-hovered mx-lg-n2 menu-main">
|
||||
{% for page in page.get_children %}
|
||||
<li class="nav-item">
|
||||
<a class="nav-link text-nowrap" href="{{ page.url }}" target="_self">
|
||||
{{ page.title|safe }}
|
||||
</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
{% if page.get_children|length > 0 %}
|
||||
{% for page in page.get_children %}
|
||||
<li class="nav-item">
|
||||
<a class="nav-link text-nowrap" href="{{ page.url }}" target="_self">
|
||||
{{ page.title|safe }}
|
||||
</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
{% for page in page.get_parent.get_children %}
|
||||
<li class="nav-item">
|
||||
<a class="nav-link text-nowrap" href="{{ page.url }}" target="_self">
|
||||
{{ page.title|safe }}
|
||||
</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
|
|
Loading…
Reference in New Issue