8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-11-26 14:42:25 +00:00

Lots of little UI improvements

This commit is contained in:
lhark 2016-11-18 11:53:10 +01:00
parent 5df96a6061
commit b32dad0cd6
27 changed files with 272 additions and 91 deletions

View file

@ -1,10 +1,10 @@
<table class="table table-striped"> <table class="table table-striped">
<thead> <thead>
<tr> <tr>
<th>Nom de l'article</th> <th>Article</th>
<th>Prix</th> <th>Prix</th>
<th>Cotisation</th> <th>Cotisation</th>
<th>Durée (en mois)</th> <th>Durée (mois)</th>
<th></th> <th></th>
</tr> </tr>
</thead> </thead>
@ -14,8 +14,16 @@
<td>{{ article.prix }}</td> <td>{{ article.prix }}</td>
<td>{{ article.cotisation }}</td> <td>{{ article.cotisation }}</td>
<td>{{ article.duration }}</td> <td>{{ article.duration }}</td>
<td>{% if is_trez %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'cotisations:edit-article' article.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a>{% endif %} <td class="text-right">
<a class="btn btn-info btn-sm" role="button" href="{% url 'cotisations:history' 'article' article.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if is_trez %}
<a class="btn btn-primary btn-sm" role="button" title="Éditer" href="{% url 'cotisations:edit-article' article.id %}">
<i class="glyphicon glyphicon-edit"></i>
</a>
{% endif %}
<a class="btn btn-info btn-sm" role="button" title="Historique" href="{% url 'cotisations:history' 'article' article.id %}">
<i class="glyphicon glyphicon-time"></i>
</a>
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -8,8 +8,16 @@
{% for banque in banque_list %} {% for banque in banque_list %}
<tr> <tr>
<td>{{ banque.name }}</td> <td>{{ banque.name }}</td>
<td>{% if is_trez %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'cotisations:edit-banque' banque.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a>{% endif %} <td class="text-right">
<a class="btn btn-info btn-sm" role="button" href="{% url 'cotisations:history' 'banque' banque.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if is_trez %}
<a class="btn btn-primary btn-sm" role="button" title="Éditer" href="{% url 'cotisations:edit-banque' banque.id %}">
<i class="glyphicon glyphicon-edit"></i>
</a>
{% endif %}
<a class="btn btn-info btn-sm" role="button" title="Historique" href="{% url 'cotisations:history' 'banque' banque.id %}">
<i class="glyphicon glyphicon-time"></i>
</a>
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -23,7 +23,8 @@
<td>{{ facture.paiement }}</td> <td>{{ facture.paiement }}</td>
<td>{{ facture.date }}</td> <td>{{ facture.date }}</td>
{% if is_cableur %} {% if is_cableur %}
<td><div class="dropdown"> <td>
<div class="dropdown">
<button class="btn btn-default dropdown-toggle" type="button" id="editionfacture" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true"> <button class="btn btn-default dropdown-toggle" type="button" id="editionfacture" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
Modifier Modifier
<span class="caret"></span> <span class="caret"></span>
@ -35,10 +36,25 @@
{% else %} {% else %}
<li>Facture controlée</li> <li>Facture controlée</li>
{% endif %} {% endif %}
</ul></div></td> </ul>
</div>
</td>
{% endif %} {% endif %}
<td>{% if facture.valid %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'cotisations:facture-pdf' facture.id %}"><i class="glyphicon glyphicon-save"></i> PDF</a>{% else %}Facture invalide{% endif %}</td> <td>
<td><a class="btn btn-info btn-sm" role="button" href="{% url 'cotisations:history' 'facture' facture.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if facture.valid %}
<a class="btn btn-primary btn-sm" role="button" href="{% url 'cotisations:facture-pdf' facture.id %}">
<i class="glyphicon glyphicon-save"></i>
PDF
</a>
{% else %}
<font color="red">Facture invalide</font>
{% endif %}
</td>
<td class="text-right">
<a class="btn btn-info btn-sm" role="button" title="Historique" href="{% url 'cotisations:history' 'facture' facture.id %}">
<i class="glyphicon glyphicon-time"></i>
</a>
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -8,8 +8,16 @@
{% for paiement in paiement_list %} {% for paiement in paiement_list %}
<tr> <tr>
<td>{{ paiement.moyen }}</td> <td>{{ paiement.moyen }}</td>
<td>{% if is_trez %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'cotisations:edit-paiement' paiement.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a>{% endif %} <td class="text-right">
<a class="btn btn-info btn-sm" role="button" href="{% url 'cotisations:history' 'paiement' paiement.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if is_trez %}
<a class="btn btn-primary btn-sm" role="button" title="Éditer" href="{% url 'cotisations:edit-paiement' paiement.id %}">
<i class="glyphicon glyphicon-edit"></i>
</a>
{% endif %}
<a class="btn btn-info btn-sm" role="button" title="Historique" href="{% url 'cotisations:history' 'paiement' paiement.id %}">
<i class="glyphicon glyphicon-time"></i>
</a>
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -1,10 +1,30 @@
{% extends "base.html" %} {% extends "base.html" %}
{% block sidebar %} {% block sidebar %}
<p><a href="{% url "cotisations:index" %}">Liste des factures</a></p> {% if is_trez %}
<p><a href="{% url "cotisations:index-article" %}">Liste des articles en vente</a></p> <a class="list-group-item list-group-item-success" href="{% url "cotisations:new-facture-pdf" %}">
<p><a href="{% url "cotisations:index-banque" %}">Liste des banques</a></p> <i class="glyphicon glyphicon-plus"></i>
<p><a href="{% url "cotisations:index-paiement" %}">Liste des moyens de paiement</a></p> Créer une facture
{% if is_trez %}<p><a href="{% url "cotisations:control" %}">Controler les factures</a></p> </a>
<p><a href="{% url "cotisations:new-facture-pdf" %}">Créer une nouvelle facture</a></p>{% endif %} <a class="list-group-item list-group-item-warning" href="{% url "cotisations:control" %}">
<i class="glyphicon glyphicon-eye-open"></i>
Contrôler les factures
</a>
{% endif %}
<a class="list-group-item list-group-item-info" href="{% url "cotisations:index" %}">
<i class="glyphicon glyphicon-list"></i>
Factures
</a>
<a class="list-group-item list-group-item-info" href="{% url "cotisations:index-article" %}">
<i class="glyphicon glyphicon-list"></i>
Articles en vente
</a>
<a class="list-group-item list-group-item-info" href="{% url "cotisations:index-banque" %}">
<i class="glyphicon glyphicon-list"></i>
Banques
</a>
<a class="list-group-item list-group-item-info" href="{% url "cotisations:index-paiement" %}">
<i class="glyphicon glyphicon-list"></i>
Moyens de paiement
</a>
{% endblock %} {% endblock %}

View file

@ -22,7 +22,14 @@
<td>{{ revision.user }}</td> <td>{{ revision.user }}</td>
<td>{{ revision.date_created }}</td> <td>{{ revision.date_created }}</td>
<td>{{ revision.comment }}</td> <td>{{ revision.comment }}</td>
{% if is_bureau %}<td><a class="btn btn-info btn-sm" role="button" href="{% url 'logs:revert-action' revision.id %}"><i class="glyphicon glyphicon-repeat"></i>Annuler</a></p></td>{% endif %} {% if is_bureau %}
<td>
<a class="btn btn-danger btn-sm" role="button" href="{% url 'logs:revert-action' revision.id %}">
<i class="glyphicon glyphicon-remove"></i>
Annuler
</a>
</td>
{% endif %}
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -2,8 +2,21 @@
{% block sidebar %} {% block sidebar %}
{% if is_cableur %} {% if is_cableur %}
<p><a href="{% url "logs:stats-models" %}">Statistiques base de donnée</a></p> <a class="list-group-item list-group-item-info" href="{% url "logs:index" %}">
<p><a href="{% url "logs:stats-actions" %}">Statistiques des actions de cablage</a></p> <i class="glyphicon glyphicon-stats"></i>
<p><a href="{% url "logs:stats-users" %}">Statistiques utilisateurs</a></p> Évènements
</a>
<a class="list-group-item list-group-item-info" href="{% url "logs:stats-models" %}">
<i class="glyphicon glyphicon-stats"></i>
Base de données
</a>
<a class="list-group-item list-group-item-info" href="{% url "logs:stats-actions" %}">
<i class="glyphicon glyphicon-stats"></i>
Actions de cablage
</a>
<a class="list-group-item list-group-item-info" href="{% url "logs:stats-users" %}">
<i class="glyphicon glyphicon-stats"></i>
Utilisateurs
</a>
{% endif %} {% endif %}
{% endblock %} {% endblock %}

View file

@ -3,14 +3,17 @@
<tr> <tr>
<th>Extension</th> <th>Extension</th>
<th></th> <th></th>
<th></th>
</tr> </tr>
</thead> </thead>
{% for extension in extension_list %} {% for extension in extension_list %}
<tr> <tr>
<td>{{ extension.name }}</td> <td>{{ extension.name }}</td>
<td>{% if is_infra %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'machines:edit-extension' extension.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a>{% endif %}</td> <td class="text-right">
<td><a class="btn btn-info btn-sm" role="button" href="{% url 'machines:history' 'extension' extension.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if is_infra %}
{% include 'buttons/edit.html' with href='machines:edit-extension' id=extension.id %}
{% endif %}
{% include 'buttons/history.html' with href='machines:history' name='extension' id=extension.id %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -17,8 +17,12 @@
<td>{{ type.need_infra }}</td> <td>{{ type.need_infra }}</td>
<td>{{ type.domaine_ip }}</td> <td>{{ type.domaine_ip }}</td>
<td>{{ type.domaine_range }}</td> <td>{{ type.domaine_range }}</td>
<td>{% if is_infra %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'machines:edit-iptype' type.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a>{% endif %}</td> <td class="text-right">
<td><a class="btn btn-info btn-sm" role="button" href="{% url 'machines:history' 'iptype' type.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if is_infra %}
{% include 'buttons/edit.html' with href='machines:edit-iptype' id=type.id %}
{% endif %}
{% include 'buttons/history.html' with href='machines:history' name='iptype' id=type.id %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -19,15 +19,9 @@
<tr class="active"> <tr class="active">
{% if forloop.first %} {% if forloop.first %}
<td rowspan="{{ machine.interface_set.all|length }}"> <td rowspan="{{ machine.interface_set.all|length }}">
<a class="btn btn-primary" role="button" href="{% url 'machines:new-interface' machine.id %}" title="Ajouter une interface"> {% include 'buttons/add.html' with href='machines:new-interface' id=machine.id desc='Ajouter une interface' %}
<i class="glyphicon glyphicon-plus"></i> {% include 'buttons/suppr.html' with href='machines:del-machine' id=machine.id %}
</a> {% include 'buttons/history.html' with href='machines:history' name='machine' id=machine.id %}
<a class="btn btn-danger" role="button" href="{% url 'machines:del-machine' machine.id %}" title="Supprimer la machine">
<i class="glyphicon glyphicon-trash"></i>
</a>
<a class="btn btn-info" role="button" href="{% url 'machines:history' 'machine' machine.id %}" title="Historique">
<i class="glyphicon glyphicon-time"></i>
</a>
</td> </td>
<td rowspan="{{ machine.interface_set.all|length }}"> <td rowspan="{{ machine.interface_set.all|length }}">
<p><b>{{ machine.user }}</b</p> <p><b>{{ machine.user }}</b</p>

View file

@ -4,15 +4,18 @@
<th>Type de machine</th> <th>Type de machine</th>
<th>Type d'ip correspondant</th> <th>Type d'ip correspondant</th>
<th></th> <th></th>
<th></th>
</tr> </tr>
</thead> </thead>
{% for type in machinetype_list %} {% for type in machinetype_list %}
<tr> <tr>
<td>{{ type.type }}</td> <td>{{ type.type }}</td>
<td>{{ type.ip_type }}</td> <td>{{ type.ip_type }}</td>
<td>{% if is_infra %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'machines:edit-machinetype' type.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a>{% endif %}</td> <td class="text-right">
<td><a class="btn btn-info btn-sm" role="button" href="{% url 'machines:history' 'machinetype' type.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if is_infra %}
{% include 'buttons/edit.html' with href='machines:edit-machinetype' id=type.id %}
{% endif %}
{% include 'buttons/history.html' with href='machines:history' name='machinetype' id=type.id %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -2,8 +2,21 @@
{% block sidebar %} {% block sidebar %}
{% if is_cableur %} {% if is_cableur %}
<p><a href="{% url "machines:index-machinetype" %}">Liste des types de machine</a></p> <a class="list-group-item list-group-item-info" href="{% url "machines:index" %}">
<p><a href="{% url "machines:index-extension" %}">Liste des types des extensions</a></p> <i class="glyphicon glyphicon-list"></i>
<p><a href="{% url "machines:index-iptype" %}">Liste des types d'ip</a></p> Machines
</a>
<a class="list-group-item list-group-item-info" href="{% url "machines:index-machinetype" %}">
<i class="glyphicon glyphicon-list"></i>
Types de machines
</a>
<a class="list-group-item list-group-item-info" href="{% url "machines:index-extension" %}">
<i class="glyphicon glyphicon-list"></i>
Extensions (zones)
</a>
<a class="list-group-item list-group-item-info" href="{% url "machines:index-iptype" %}">
<i class="glyphicon glyphicon-list"></i>
Plages d'IP
</a>
{% endif %} {% endif %}
{% endblock %} {% endblock %}

View file

@ -1,6 +1,12 @@
{% extends "base.html" %} {% extends "base.html" %}
{% block sidebar %} {% block sidebar %}
<p><a href="{% url "search:search" %}">Recherche simple</a></p> <a class="list-group-item list-group-item-warning" href="{% url "search:search" %}">
<p><a href="{% url "search:searchp" %}">Recherche avancée</a></p> <i class="glyphicon glyphicon-search"></i>
Recherche simple
</a>
<a class="list-group-item list-group-item-warning" href="{% url "search:searchp" %}">
<i class="glyphicon glyphicon-zoom-in"></i>
Recherche avancée
</a>
{% endblock %} {% endblock %}

View file

@ -70,9 +70,13 @@
<div id="main" class="container-fluid text-center"> <div id="main" class="container-fluid text-center">
<div class="row content"> <div class="row content">
<div class="col-sm-2 sidenav"> <div class="col-sm-2 sidenav">
<div class="panel panel-default">
<div class="text-left list-group">
{% block sidebar %} {% block sidebar %}
{% endblock %} {% endblock %}
</div> </div>
</div>
</div>
<div class="col-sm-8 text-left"> <div class="col-sm-8 text-left">
{# Display django.contrib.messages as Bootstrap alerts #} {# Display django.contrib.messages as Bootstrap alerts #}
{% bootstrap_messages %} {% bootstrap_messages %}

View file

@ -0,0 +1,3 @@
<a class="btn btn-primary btn-sm" role="button" href="{% url href id %}" title="{{ desc|default:"Ajouter" }}">
<i class="glyphicon glyphicon-plus"></i>
</a>

View file

@ -0,0 +1,3 @@
<a class="btn btn-primary btn-sm" role="button" title="{{ desc|default:"Éditer" }}" href="{% url href id %}">
<i class="glyphicon glyphicon-edit"></i>
</a>

View file

@ -0,0 +1,4 @@
<a class="btn btn-info btn-sm" role="button" title="Historique" href="{% url href name id %}">
<i class="glyphicon glyphicon-time"></i>
</a>

View file

@ -0,0 +1,3 @@
<a class="btn btn-danger btn-sm" role="button" href="{% url href id %}" title="{{ desc|default:"Supprimer" }}">
<i class="glyphicon glyphicon-trash"></i>
</a>

View file

@ -10,9 +10,19 @@
<tr> <tr>
<td>{{room.name}}</td> <td>{{room.name}}</td>
<td>{{room.details}}</td> <td>{{room.details}}</td>
<td>{% if is_infra %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'topologie:edit-room' room.id %}"><i class="glyphicon glyphicon-random"></i> Editer</a> <td class="text-right">
<a class="btn btn-danger btn-sm" role="button" href="{% url 'topologie:del-room' room.id %}"><i class="glyphicon glyphicon-trash"></i> Supprimer</a>{% endif %} <a class="btn btn-info btn-sm" role="button" title="Historique" href="{% url 'topologie:history' 'room' room.pk %}">
<a class="btn btn-info btn-sm" role="button" href="{% url 'topologie:history' 'room' room.pk %}"><i class="glyphicon glyphicon-repeat"></i> Historique</a></td> <i class="glyphicon glyphicon-time"></i>
</a>
{% if is_infra %}
<a class="btn btn-primary btn-sm" role="button" title="Éditer" href="{% url 'topologie:edit-room' room.id %}">
<i class="glyphicon glyphicon-edit"></i>
</a>
<a class="btn btn-danger btn-sm" role="button" title="Supprimer" href="{% url 'topologie:del-room' room.id %}">
<i class="glyphicon glyphicon-trash"></i>
</a>
{% endif %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -16,8 +16,16 @@
<td>{{ port.machine_interface }}</td> <td>{{ port.machine_interface }}</td>
<td>{{ port.related }}</td> <td>{{ port.related }}</td>
<td>{{ port.details }}</td> <td>{{ port.details }}</td>
<td>{% if is_infra %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'topologie:edit-port' port.id %}"><i class="glyphicon glyphicon-random"></i> Editer</a>{% endif %} <td class="text-right">
<a class="btn btn-info btn-sm" role="button" href="{% url 'topologie:history' 'port' port.pk %}"><i class="glyphicon glyphicon-repeat"></i> Historique</a></td> <a class="btn btn-info btn-sm" role="button" title="Historique" href="{% url 'topologie:history' 'port' port.pk %}">
<i class="glyphicon glyphicon-time"></i>
</a>
{% if is_infra %}
<a class="btn btn-primary btn-sm" role="button" title="Éditer" href="{% url 'topologie:edit-port' port.id %}">
<i class="glyphicon glyphicon-edit"></i>
</a>
{% endif %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -4,20 +4,27 @@
<th>Dns</th> <th>Dns</th>
<th>Ipv4</th> <th>Ipv4</th>
<th>Localisation</th> <th>Localisation</th>
<th>Nombre de ports</th> <th>Ports</th>
<th>Détails</th> <th>Détails</th>
<th></th> <th></th>
</tr> </tr>
</thead> </thead>
{% for switch in switch_list %} {% for switch in switch_list %}
<tr> <tr>
<td>{{switch.switch_interface.dns}}</td> <td>
<a title="Configuer" href="{% url 'topologie:index-port' switch.pk %}">
{{switch.switch_interface.dns}}
</a>
</td>
<td>{{switch.switch_interface.ipv4}}</td> <td>{{switch.switch_interface.ipv4}}</td>
<td>{{switch.location}}</td> <td>{{switch.location}}</td>
<td>{{switch.number}}</td> <td>{{switch.number}}</td>
<td>{{switch.details}}</td> <td>{{switch.details}}</td>
<td><a class="btn btn-primary btn-sm" role="button" href="{% url 'topologie:index-port' switch.pk %}"><i class="glyphicon glyphicon-cog"></i> Configurer</a> <td class="text-right">
<a class="btn btn-info btn-sm" role="button" href="{% url 'topologie:history' 'switch' switch.pk %}"><i class="glyphicon glyphicon-repeat"></i> Historique</a></td> <a class="btn btn-info btn-sm" role="button" title="Historique" href="{% url 'topologie:history' 'switch' switch.pk %}">
<i class="glyphicon glyphicon-time"></i>
</a>
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -1,6 +1,12 @@
{% extends "base.html" %} {% extends "base.html" %}
{% block sidebar %} {% block sidebar %}
<p><a href="{% url "topologie:index" %}">Liste des switchs</a></p> <a class="list-group-item list-group-item-info" href="{% url "topologie:index-room" %}">
<p><a href="{% url "topologie:index-room" %}">Liste des chambres</a></p> <i class="glyphicon glyphicon-list"></i>
Chambres
</a>
<a class="list-group-item list-group-item-info" href="{% url "topologie:index" %}">
<i class="glyphicon glyphicon-list"></i>
Switchs
</a>
{% endblock %} {% endblock %}

View file

@ -10,7 +10,6 @@
<th>Date de début</th> <th>Date de début</th>
<th>Date de fin</th> <th>Date de fin</th>
<th></th> <th></th>
<th></th>
</tr> </tr>
</thead> </thead>
{% for ban in ban_list %} {% for ban in ban_list %}
@ -19,8 +18,12 @@
<td>{{ ban.raison }}</td> <td>{{ ban.raison }}</td>
<td>{{ ban.date_start }}</td> <td>{{ ban.date_start }}</td>
<td>{{ ban.date_end }}</td> <td>{{ ban.date_end }}</td>
<td>{% if is_bofh %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'users:edit-ban' ban.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a>{% endif %}</td> <td class="text-right">
<td><a class="btn btn-info btn-sm" role="button" href="{% url 'users:history' 'ban' ban.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if is_bofh %}
{% include 'buttons/edit.html' with href='users:edit-ban' id=ban.id %}
{% endif %}
{% include 'buttons/history.html' with href='users:history' name='ban' id=ban.id %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -11,8 +11,10 @@
<tr> <tr>
<td>{{ listright.listright }}</td> <td>{{ listright.listright }}</td>
<td>{{ listright.gid }}</td> <td>{{ listright.gid }}</td>
<td><a class="btn btn-primary btn-sm" role="button" href="{% url 'users:edit-listright' listright.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a></td> <td class="text-right">
<td><a class="btn btn-info btn-sm" role="button" href="{% url 'users:history' 'listright' listright.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% include 'buttons/edit.html' with href='users:edit-listright' id=listright.id %}
{% include 'buttons/history.html' with href='users:history' name='listright' id=listright.id %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -3,14 +3,15 @@
<tr> <tr>
<th>Etablissement</th> <th>Etablissement</th>
<th></th> <th></th>
<th></th>
</tr> </tr>
</thead> </thead>
{% for school in school_list %} {% for school in school_list %}
<tr> <tr>
<td>{{ school.name }}</td> <td>{{ school.name }}</td>
<td><a class="btn btn-primary btn-sm" role="button" href="{% url 'users:edit-school' school.id %}"><i class="glyphicon glyphicon-pushpin"></i> Editer</a></td> <td class="text-right">
<td><a class="btn btn-info btn-sm" role="button" href="{% url 'users:history' 'school' school.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% include 'buttons/edit.html' with href='users:edit-school' id=school.id %}
{% include 'buttons/history.html' with href='users:history' name='school' id=school.id %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -6,7 +6,6 @@
<th>Date de début</th> <th>Date de début</th>
<th>Date de fin</th> <th>Date de fin</th>
<th></th> <th></th>
<th></th>
</tr> </tr>
</thead> </thead>
{% for whitelist in white_list %} {% for whitelist in white_list %}
@ -15,8 +14,12 @@
<td>{{ whitelist.raison }}</td> <td>{{ whitelist.raison }}</td>
<td>{{ whitelist.date_start }}</td> <td>{{ whitelist.date_start }}</td>
<td>{{ whitelist.date_end }}</td> <td>{{ whitelist.date_end }}</td>
<td>{% if is_cableur %}<a class="btn btn-primary btn-sm" role="button" href="{% url 'users:edit-whitelist' whitelist.id %}"><i class="glyphicon glyphicon-flag"></i> Editer</a>{% endif %}</td> <td class="text-right">
<td><a class="btn btn-info btn-sm" role="button" href="{% url 'users:history' 'whitelist' whitelist.id %}"><i class="glyphicon glyphicon-time"></i> Historique</a></td> {% if is_cableur %}
{% include 'buttons/edit.html' with href='users:edit-whitelist' id=whitelist.id %}
{% endif %}
{% include 'buttons/history.html' with href='users:history' name='whitelist' id=whitelist.id %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -2,14 +2,35 @@
{% block sidebar %} {% block sidebar %}
{% if is_cableur %} {% if is_cableur %}
<p><a href="{% url "users:new-user" %}">Créer un adhérent</a></p> <a class="list-group-item list-group-item-success" href="{% url "users:new-user" %}">
<p><a href="{% url "users:index" %}">Liste des adhérents</a></p> <i class="glyphicon glyphicon-plus"></i>
<p><a href="{% url "users:index-ban" %}">Liste des bannissements</a></p> Créer un adhérent
<p><a href="{% url "users:index-white" %}">Liste des accès à titre gracieux</a></p> </a>
<p><a href="{% url "users:index-school" %}">Liste des établissements</a></p> <a class="list-group-item list-group-item-info" href="{% url "users:index" %}">
<p><a href="{% url "users:index-listright" %}">Liste des droits</a></p> <i class="glyphicon glyphicon-list"></i>
Adhérents
</a>
<a class="list-group-item list-group-item-info" href="{% url "users:index-ban" %}">
<i class="glyphicon glyphicon-list"></i>
Bannissements
</a>
<a class="list-group-item list-group-item-info" href="{% url "users:index-white" %}">
<i class="glyphicon glyphicon-list"></i>
Accès à titre gracieux
</a>
<a class="list-group-item list-group-item-info" href="{% url "users:index-school" %}">
<i class="glyphicon glyphicon-list"></i>
Établissements
</a>
<a class="list-group-item list-group-item-info" href="{% url "users:index-listright" %}">
<i class="glyphicon glyphicon-list"></i>
Droits
</a>
{% if is_bureau %} {% if is_bureau %}
<p><a href="{% url "users:del-right" %}">Retirer un droit</a></p> <a class="list-group-item list-group-item-danger" href="{% url "users:del-right" %}">
<i class="glyphicon glyphicon-trash"></i>
Retirer un droit
</a>
{% endif %} {% endif %}
{% endif %} {% endif %}
{% endblock %} {% endblock %}