src/iconolab_episteme/templates/partials/header.html
changeset 12 902a14596a56
child 15 37c39e71b944
equal deleted inserted replaced
7:a40fd3990850 12:902a14596a56
       
     1 {% load notifications_tags %}
       
     2 {% load iconolab_tags %}
       
     3 {% load staticfiles %}
       
     4 
       
     5 <header>
       
     6   <section id="topnav">
       
     7     <nav class="navbar navbar-default">
       
     8       <div class="{% container_class %}">
       
     9         <div class="navbar-header">
       
    10             {# {% if not homepage %} #}
       
    11               <a class="navbar-brand" href="{% url 'home' %}">
       
    12                 <img src="{% static 'iconolab/img/iconolab.png' %}" alt="Iconolab" height="20">
       
    13               </a>
       
    14             {# {% endif %} #}
       
    15         </div>
       
    16         <div id="navbar" class="navbar-collapse collapse">
       
    17           <ul class="nav navbar-nav">
       
    18             <li><a href="{% url 'iconolab_help' %}">Le projet</a></li>
       
    19             {% if collection_name %}<li><a href="{% url 'collection_home' collection_name %}">Contribuer</a></li>{% endif %}
       
    20           </ul>
       
    21           {% include "partials/header_search_form.html"%}
       
    22           <a class="navbar-brand" href="https://projet-episteme.org/" target="_blank" rel="noopener noreferrer">
       
    23             <img src="{% static 'iconolab_episteme/img/logo_episteme.png' %}" alt="Episteme" height="25" style="margin-left: 20%;">
       
    24           </a>
       
    25           <ul class="nav navbar-nav navbar-right">
       
    26             {% if request.user.is_authenticated %}
       
    27               {% notifications_unread as unread_count %}
       
    28               <li><a href="{% url 'user_home' request.user.username %}" title="{{request.user.username}}: Mon espace - {{ unread_count }} notification(s)">
       
    29                 Mon espace <span class="badge {% if unread_count %}badge-warning{% endif %}">
       
    30                 {{ unread_count }} <i class="fa fa-envelope-o" aria-hidden="true"></i> </span>
       
    31               </a></li>
       
    32               <li><a href="{% url 'account:logout' %}">Déconnexion</a></li>
       
    33             {% else %}
       
    34               <li><a href="{% url 'account:register' %}">Créer un compte</a></li>
       
    35               <li><a href="{% url 'account:login' %}?next={{ request.path | urlencode }}">Connexion</a></li>
       
    36             {% endif %}
       
    37           </ul>
       
    38         </div><!--/.nav-collapse -->
       
    39       </div><!--/.container-fluid -->
       
    40     </nav>
       
    41   </section>
       
    42 </header>
       
    43 
       
    44 <div class="{% container_class %}">
       
    45 {% include "partials/header_breadcrumbs.html" %}
       
    46 </div>