mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-24 20:33:11 +00:00
Title block for compatibility
This commit is contained in:
parent
0c49a3b077
commit
46cb6dddb3
1 changed files with 260 additions and 232 deletions
|
@ -92,28 +92,38 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<ul class="nav navbar-nav">
|
||||
{% can_view_any_app users machines cotisations %}
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-users"></i> {% trans "Users" %}<span class="caret"></span></a>
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true"
|
||||
aria-expanded="false"><i class="fa fa-users"></i> {% trans "Users" %}<span class="caret"></span></a>
|
||||
<ul class="dropdown-menu">
|
||||
{% can_view_app users %}
|
||||
<li><a href="{% url 'users:index' %}"><i class="fa fa-user"></i> {% trans "Manage the users" %}</a></li>
|
||||
<li><a href="{% url 'users:index-clubs' %}"><i class="fa fa-users"></i> {% trans "Manage the clubs" %}</a></li>
|
||||
<li><a href="{% url 'users:index' %}"><i class="fa fa-user"></i> {% trans "Manage the users" %}
|
||||
</a></li>
|
||||
<li><a href="{% url 'users:index-clubs' %}"><i
|
||||
class="fa fa-users"></i> {% trans "Manage the clubs" %}</a></li>
|
||||
{% acl_end %}
|
||||
{% can_view_app machines %}
|
||||
<li><a href="{% url 'machines:index' %}"><i class="fa fa-desktop"></i> {% trans "Manage the machines" %}</a></li>
|
||||
<li><a href="{% url 'machines:index' %}"><i
|
||||
class="fa fa-desktop"></i> {% trans "Manage the machines" %}</a></li>
|
||||
{% acl_end %}
|
||||
{% can_view_app cotisations %}
|
||||
<li><a href="{% url 'cotisations:index' %}"><i class="fa fa-eur"></i> {% trans "Manage the subscriptions" %}</a></li>
|
||||
<li><a href="{% url 'cotisations:index' %}"><i
|
||||
class="fa fa-eur"></i> {% trans "Manage the subscriptions" %}</a></li>
|
||||
{% acl_end %}
|
||||
</ul>
|
||||
</li>
|
||||
{% acl_end %}
|
||||
{% can_view_app topologie %}
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-sitemap"></i> {% trans "Topology" %}<span class="caret"></span></a>
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true"
|
||||
aria-expanded="false"><i class="fa fa-sitemap"></i> {% trans "Topology" %}<span
|
||||
class="caret"></span></a>
|
||||
<ul class="dropdown-menu">
|
||||
<li><a href="{% url 'topologie:index' %}"><i class="fa fa-microchip"></i> {% trans "Switches" %}</a></li>
|
||||
<li><a href="{% url 'topologie:index-ap' %}"><i class="fa fa-wifi"></i> {% trans "Access points" %}</a></li>
|
||||
<li><a href="{% url 'topologie:index-room' %}"><i class="fa fa-home"></i> {% trans "Rooms" %}</a></li>
|
||||
<li><a href="{% url 'topologie:index' %}"><i class="fa fa-microchip"></i> {% trans "Switches" %}
|
||||
</a></li>
|
||||
<li><a href="{% url 'topologie:index-ap' %}"><i
|
||||
class="fa fa-wifi"></i> {% trans "Access points" %}</a></li>
|
||||
<li><a href="{% url 'topologie:index-room' %}"><i class="fa fa-home"></i> {% trans "Rooms" %}
|
||||
</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
{% acl_end %}
|
||||
|
@ -130,7 +140,9 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
</ul>
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-info"></i> {% trans "More information" %}<span class="caret"></span></a>
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true"
|
||||
aria-expanded="false"><i class="fa fa-info"></i> {% trans "More information" %}<span
|
||||
class="caret"></span></a>
|
||||
<ul class="dropdown-menu">
|
||||
<li><a href="{% url 'about' %}"><i class="fa fa-info-circle"></i> {% trans "About" %}</a></li>
|
||||
<li><a href="{% url 'contact' %}"><i class="fa fa-at"></i> {% trans "Contact" %}</a></li>
|
||||
|
@ -154,10 +166,12 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<li>
|
||||
<form action="{% url 'search:search' %}" class="navbar-form" role="search">
|
||||
<div class="input-group">
|
||||
<input type="text" class="form-control" placeholder="{% trans "Search" %}" name="q" id="search-term" {% if search_term %}value="{{ search_term }}"{% endif %}>
|
||||
<input type="text" class="form-control" placeholder="{% trans "Search" %}" name="q"
|
||||
id="search-term" {% if search_term %}value="{{ search_term }}"{% endif %}>
|
||||
<div class="input-group-btn">
|
||||
<button class="btn btn-default" type="submit"><i class="fa fa-search"></i></button>
|
||||
<a href="{% url 'search:searchp' %}" class="btn btn-default" role="button"><i class="fa fa-plus"></i></a>
|
||||
<a href="{% url 'search:searchp' %}" class="btn btn-default" role="button"><i
|
||||
class="fa fa-plus"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
@ -166,10 +180,14 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
{% endif %}
|
||||
{% if request.user.is_authenticated %}
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-user-circle"></i> {{ request.user.pseudo|slice:":15" }} <span class="caret"></span></a>
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true"
|
||||
aria-expanded="false"><i class="fa fa-user-circle"></i> {{ request.user.pseudo|slice:":15" }}
|
||||
<span class="caret"></span></a>
|
||||
<ul class="dropdown-menu">
|
||||
<li><a href="{% url 'users:mon-profil' %}"><i class="fa fa-user"></i> {% trans "My profile" %}</a></li>
|
||||
<li><a id="toggle_login" href="{% url 'logout' %}"><i class="fa fa-sign-out"></i> {% trans "Log out" %}</a></li>
|
||||
<li><a href="{% url 'users:mon-profil' %}"><i
|
||||
class="fa fa-user"></i> {% trans "My profile" %}</a></li>
|
||||
<li><a id="toggle_login" href="{% url 'logout' %}"><i
|
||||
class="fa fa-sign-out"></i> {% trans "Log out" %}</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
{% endif %}
|
||||
|
@ -195,6 +213,9 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
{# Display breadcrumbs #}
|
||||
{% block breadcrumbs %}{% endblock %}
|
||||
|
||||
{# Some pages need a title block #}
|
||||
{% block content_title %}{% if title %}<h2>{{ title }}</h2>{% endif %}{% endblock %}
|
||||
|
||||
{# Display django.contrib.messages as Bootstrap alerts #}
|
||||
{% bootstrap_messages %}
|
||||
{% block content %}{% endblock %}
|
||||
|
@ -218,7 +239,9 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<th scope="row">{% trans "Internet access" %}</th>
|
||||
<td class="text-right">
|
||||
{% if request_user.has_access %}
|
||||
<i class="text-success">{% blocktrans with end_access_date=request.user.end_access|date:"d b Y" %}Until {{ end_access_date }}{% endblocktrans %}</i>
|
||||
<i class="text-success">
|
||||
{% blocktrans with end_access_date=request.user.end_access|date:"d b Y" %}Until
|
||||
{{ end_access_date }}{% endblocktrans %}</i>
|
||||
{% else %}
|
||||
<i class="text-danger">{% trans "Disabled" %}</i>
|
||||
{% endif %}
|
||||
|
@ -228,7 +251,9 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<th scope="row">{% trans "Membership" %}</th>
|
||||
<td class="text-right">
|
||||
{% if request_user.is_adherent %}
|
||||
<i class="text-success">{% blocktrans with end_adhesion_date=request_user.end_adhesion|date:"d b Y" %}Until {{ end_adhesion_date }}{% endblocktrans %}</i>
|
||||
<i class="text-success">
|
||||
{% blocktrans with end_adhesion_date=request_user.end_adhesion|date:"d b Y" %}
|
||||
Until {{ end_adhesion_date }}{% endblocktrans %}</i>
|
||||
{% else %}
|
||||
<i class="text-danger">{% trans "Non member" %}</i>
|
||||
{% endif %}
|
||||
|
@ -236,7 +261,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
</tr>
|
||||
</table>
|
||||
<div class="list-group">
|
||||
<a class="list-group-item list-group-item-info" role="button"href="{% url 'users:mon-profil' %}">
|
||||
<a class="list-group-item list-group-item-info" role="button"
|
||||
href="{% url 'users:mon-profil' %}">
|
||||
<i class="fa fa-user-circle"></i>
|
||||
{% trans "View my profile" %}
|
||||
</a>
|
||||
|
@ -250,14 +276,16 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
{% if request_user.is_authenticated %}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h4>{% blocktrans count interfaces|length as nb %}{{ nb }} active machine{% plural %}{{ nb }} active machines{% endblocktrans %}</h4>
|
||||
<h4>{% blocktrans count interfaces|length as nb %}{{ nb }} active machine{% plural %}{{ nb }}
|
||||
active machines{% endblocktrans %}</h4>
|
||||
</div>
|
||||
<ul class="list-group">
|
||||
{% for interface in interfaces|slice:":5" %}
|
||||
<div class="list-group-item">{{ interface }}</div>
|
||||
{% endfor %}
|
||||
{% if interfaces|length > 5 %}
|
||||
<a class="list-group-item list-group-item-info" role="button" href="{% url 'users:mon-profil' %}">
|
||||
<a class="list-group-item list-group-item-info" role="button"
|
||||
href="{% url 'users:mon-profil' %}">
|
||||
<i class="fa fa-plus"></i>
|
||||
{% trans "View my machines" %}
|
||||
</a>
|
||||
|
|
Loading…
Reference in a new issue