2017-05-30 20:44:30 +02:00
|
|
|
{% load static %}
|
|
|
|
{% load wagtailcore_tags %}
|
2016-08-12 11:41:52 +02:00
|
|
|
|
2016-08-12 10:03:39 +02:00
|
|
|
<nav class="navbar navbar-fixed-top">
|
|
|
|
<div class="container-fluid">
|
|
|
|
<div class="navbar-header">
|
2017-05-30 20:44:30 +02:00
|
|
|
<a class="navbar-brand" href="{% slugurl "k-fet" %}">
|
2016-08-12 11:41:52 +02:00
|
|
|
<img src="{% static 'kfet/img/logo3.png' %}">
|
|
|
|
</a>
|
2016-08-12 10:03:39 +02:00
|
|
|
</div>
|
2017-05-30 20:44:30 +02:00
|
|
|
<ul class="nav navbar-nav">
|
2017-06-23 02:53:05 +02:00
|
|
|
<li class="kfetopen dropdown">
|
2017-06-22 16:59:41 +02:00
|
|
|
<ul class="base nav dropdown-toggle" data-toggle="dropdown">
|
2017-06-21 07:08:28 +02:00
|
|
|
<li class="bullet"></li>
|
|
|
|
{% if perms.kfet.is_team %}
|
|
|
|
<li class="warning fade">
|
|
|
|
<span class="glyphicon glyphicon-warning-sign"></span>
|
|
|
|
</li>
|
|
|
|
{% endif %}
|
|
|
|
</ul>
|
|
|
|
<div class="details dropdown-menu">
|
|
|
|
La K-Fêt est
|
2017-06-23 02:53:05 +02:00
|
|
|
<b><span class="status-text">
|
2017-06-21 07:08:28 +02:00
|
|
|
<span class="glyphicon glyphicon-refresh spinning"></span>
|
2017-06-23 02:53:05 +02:00
|
|
|
</span></b>.
|
2017-06-21 07:08:28 +02:00
|
|
|
{% if perms.kfet.is_team %}
|
|
|
|
<button class="btn btn-primary force-close-btn"> </button>
|
|
|
|
{% endif %}
|
|
|
|
</div>
|
2017-06-23 02:53:05 +02:00
|
|
|
</li>
|
2017-05-30 20:44:30 +02:00
|
|
|
{% for item in menu_items %}
|
|
|
|
{% if item.text == "Accueil" %}
|
|
|
|
<li class="{{ item.active_class }} hidden-xs hidden-sm">
|
|
|
|
<a href="{{ item.href }}" title="Accueil">
|
|
|
|
<span class="glyphicon glyphicon-home"></span>
|
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
{% else %}
|
|
|
|
<li class="{{ item.active_class }} hidden-xs hidden-sm">
|
|
|
|
<a href="{{ item.href }}">
|
|
|
|
{{ item.text }}
|
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
{% endif %}
|
|
|
|
{% endfor %}
|
|
|
|
<li class="dropdown visible-xs visible-sm nav-pages">
|
|
|
|
<a href="#" data-toggle="dropdown" roles="button" aria-haspopup="true" aria-expanded="false" class="navbar-toggle">
|
|
|
|
<span class="icon-bar"></span>
|
|
|
|
<span class="icon-bar"></span>
|
|
|
|
<span class="icon-bar"></span>
|
|
|
|
</a>
|
|
|
|
<ul class="dropdown-menu">
|
|
|
|
{% for item in menu_items %}
|
|
|
|
<li>
|
|
|
|
<a href="{{ item.href }}">
|
|
|
|
{{ item.text }}
|
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
{% endfor %}
|
|
|
|
</ul>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
<ul class="nav navbar-nav navbar-right nav-app">
|
|
|
|
{% if user.username == 'kfet_genericteam' %}
|
|
|
|
{% include "kfet/nav_item.html" with text="Équipe standard" %}
|
2017-06-12 01:51:10 +02:00
|
|
|
{% elif user.is_authenticated and not user.profile.account_kfet %}
|
|
|
|
{% include "kfet/nav_item.html" with class="disabled" href="#" glyphicon="user" text="Mon compte" %}
|
2017-05-30 20:44:30 +02:00
|
|
|
{% elif user.profile.account_kfet.readable %}
|
|
|
|
{% url "kfet.account.read" user.profile.account_kfet.trigramme as url_my_account %}
|
|
|
|
{% include "kfet/nav_item.html" with href=url_my_account glyphicon="user" text="Mon compte" %}
|
|
|
|
{% endif %}
|
|
|
|
{% if perms.kfet.is_team %}
|
|
|
|
{% include "kfet/nav_item.html" with url="kfet.kpsul" glyphicon="shopping-cart" text="K-Psul" %}
|
|
|
|
{% include "kfet/nav_item.html" with url="kfet.transfers" glyphicon="transfer" text="Transferts" %}
|
|
|
|
{% include "kfet/nav_item.html" with url="kfet.history" glyphicon="th-list" text="Historique" %}
|
|
|
|
<li class="dropdown">
|
2017-06-12 01:51:10 +02:00
|
|
|
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
2017-05-30 20:44:30 +02:00
|
|
|
<span class="glyphicon glyphicon-option-vertical"></span>
|
|
|
|
</a>
|
|
|
|
<ul class="dropdown-menu">
|
|
|
|
<li class="divider"></li>
|
|
|
|
<li><a href="{% url 'kfet.account' %}">Comptes</a></li>
|
|
|
|
<li><a href="{% url 'kfet.checkout' %}">Caisses</a></li>
|
|
|
|
<li class="divider"></li>
|
|
|
|
<li><a href="{% url 'kfet.article' %}">Articles</a></li>
|
|
|
|
<li><a href="{% url 'kfet.inventory' %}">Inventaires</a></li>
|
|
|
|
<li><a href="{% url 'kfet.order' %}">Commandes</a></li>
|
|
|
|
{% if user.username != 'kfet_genericteam' %}
|
|
|
|
<li class="divider"></li>
|
|
|
|
<li><a href="{% url 'kfet.login.genericteam' %}" target="_blank" class="genericteam">Connexion standard</a></li>
|
|
|
|
{% endif %}
|
|
|
|
{% if perms.kfet.change_settings %}
|
|
|
|
<li><a href="{% url 'kfet.settings' %}">Paramètres</a></li>
|
|
|
|
{% endif %}
|
|
|
|
<li class="divider"></li>
|
|
|
|
<li>
|
|
|
|
<a href="{% url "cof-logout" %}?next=/k-fet/">
|
|
|
|
<span class="glyphicon glyphicon-log-out"></span><span>Déconnexion</span>
|
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</li>
|
|
|
|
{% endif %}
|
|
|
|
{% if user.is_authenticated and not perms.kfet.is_team %}
|
|
|
|
<li>
|
|
|
|
<a href="{% url "cof-logout" %}?next=/k-fet/" title="Déconnexion">
|
|
|
|
<span class="glyphicon glyphicon-log-out"></span>
|
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
{% elif not user.is_authenticated %}
|
|
|
|
<li>
|
|
|
|
<a href="{% url "cof-login" %}?next={{ request.path }}" title="Connexion">
|
|
|
|
<span>Connexion</span><!--
|
|
|
|
--><span class="glyphicon glyphicon-log-in"></span>
|
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
{% endif %}
|
|
|
|
</ul>
|
|
|
|
</div>
|
2016-08-03 06:33:27 +02:00
|
|
|
</nav>
|
|
|
|
|
2016-08-20 21:08:33 +02:00
|
|
|
<script type="text/javascript">
|
|
|
|
|
|
|
|
$(document).ready(function () {
|
2017-05-30 20:44:30 +02:00
|
|
|
$('.genericteam').on('click', function () {
|
2016-08-20 21:08:33 +02:00
|
|
|
setTimeout(function () { location.reload() }, 1000);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
</script>
|