|
|
|
@ -26,27 +26,39 @@
@@ -26,27 +26,39 @@
|
|
|
|
|
<a class="navbar-brand" href="{{ request.resource_url(request.root) }}">ordr</a> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<!-- main section links --> |
|
|
|
|
<ul class="navbar-nav mr-auto"> |
|
|
|
|
<li class="nav-item active"><a class="nav-link" href="http://localhost:6543/orders">Orders</a></li> |
|
|
|
|
<li class="nav-item"><a class="nav-link" href="http://localhost:6543/faq">FAQs</a></li> |
|
|
|
|
<li class="nav-item"><a class="nav-link" href="http://localhost:6543/admin">Admin</a></li> |
|
|
|
|
</ul> |
|
|
|
|
{% if request.user %} |
|
|
|
|
<!-- user is logged in --> |
|
|
|
|
|
|
|
|
|
<!-- user login and setting stuff on the right --> |
|
|
|
|
<ul class="navbar-nav"> |
|
|
|
|
<li class="nav-item dropdown" id="user-options"> |
|
|
|
|
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdownUserSettings" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> |
|
|
|
|
Logged in as <span>HolgerFrey</span> |
|
|
|
|
</a> |
|
|
|
|
<ul class="dropdown-menu" aria-labelledby="navbarDropdownUserSettings"> |
|
|
|
|
<li class="dropdown-item"><a href="http://localhost:6543/account/settings">Settings</a></li> |
|
|
|
|
<li class="dropdown-item"><a href="https://git.cpi.imtek.uni-freiburg.de/holgi/ordr2/issues">Submit an Issue</a></li> |
|
|
|
|
<li class="dropdown-item"></li> |
|
|
|
|
<li class="dropdown-item"><a href="http://localhost:6543/account/logout">Logout</a></li> |
|
|
|
|
</ul> |
|
|
|
|
</li> |
|
|
|
|
</ul> |
|
|
|
|
<!-- main section links --> |
|
|
|
|
<ul class="navbar-nav mr-auto"> |
|
|
|
|
<li class="nav-item {{ 'active' if request.context.nav_section == 'orders' }}"><a class="nav-link" href="{{ request.resource_url(request.root, 'orders') }}">Orders</a></li> |
|
|
|
|
<li class="nav-item {{ 'active' if request.context.nav_section == 'root' and request.view_name == 'faq' }}"><a class="nav-link" href="{{ request.resource_url(request.root, 'faq') }}">FAQs</a></li> |
|
|
|
|
<li class="nav-item {{ 'active' if request.context.nav_section == 'admin' }}"><a class="nav-link" href="{{ request.resource_url(request.root, 'admin') }}">Admin</a></li> |
|
|
|
|
</ul> |
|
|
|
|
|
|
|
|
|
<!-- user login and setting stuff on the right --> |
|
|
|
|
<ul class="navbar-nav"> |
|
|
|
|
<li class="nav-item dropdown" id="user-options"> |
|
|
|
|
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdownUserSettings" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> |
|
|
|
|
Logged in as <span>{{ request.user.username }}</span> |
|
|
|
|
</a> |
|
|
|
|
<ul class="dropdown-menu" aria-labelledby="navbarDropdownUserSettings"> |
|
|
|
|
<li class="dropdown-item"><a href="{{ request.resource_url(request.root, 'account', 'settings') }}">Settings</a></li> |
|
|
|
|
<li class="dropdown-item"><a href="https://git.cpi.imtek.uni-freiburg.de/holgi/ordr2/issues">Submit an Issue</a></li> |
|
|
|
|
<li class="dropdown-item"></li> |
|
|
|
|
<li class="dropdown-item"><a href="{{ request.resource_url(request.root, 'account', 'logout') }}">Logout</a></li> |
|
|
|
|
</ul> |
|
|
|
|
</li> |
|
|
|
|
</ul> |
|
|
|
|
{% else %} |
|
|
|
|
<!-- No logged in user --> |
|
|
|
|
|
|
|
|
|
<!-- main section links --> |
|
|
|
|
<ul class="navbar-nav mr-auto"> |
|
|
|
|
<li class="nav-item {{ 'active' if request.context.nav_section == 'root' and request.view_name == 'faq' }}"><a class="nav-link" href="{{ request.resource_url(request.root, 'faq') }}">FAQs</a></li> |
|
|
|
|
<li class="nav-item {{ 'active' if request.context.nav_section == 'account' and request.view_name == 'register'}}"><a class="nav-link" href="{{ request.resource_url(request.root, 'account', 'register') }}">Register</a></li> |
|
|
|
|
</ul> |
|
|
|
|
{% endif %} |
|
|
|
|
</nav> |
|
|
|
|
|
|
|
|
|
<!-- header level two --> |
|
|
|
|