mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-23 11:53:12 +00:00
Merge branch 'ticks' into 'master'
Fix #143 Closes #143 See merge request federez/re2o!190
This commit is contained in:
commit
41cd115f51
10 changed files with 292 additions and 188 deletions
|
@ -25,20 +25,10 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
{% load acl %}
|
{% load acl %}
|
||||||
{% load i18n %}
|
{% load i18n %}
|
||||||
{% load logs_extra %}
|
{% load logs_extra %}
|
||||||
|
{% load design %}
|
||||||
|
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
|
||||||
<th>{% trans "Article" %}</th>
|
|
||||||
<th>{% trans "Price" %}</th>
|
|
||||||
<th>{% trans "Cotisation type" %}</th>
|
|
||||||
<th>{% trans "Duration (month)" %}</th>
|
|
||||||
<th>{% trans "Concerned users" %}</th>
|
|
||||||
<th>{% trans "Available for everyone" %}</th>
|
|
||||||
<th></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
{% for article in article_list %}
|
|
||||||
<tr>
|
<tr>
|
||||||
<td>{{ article.name }}</td>
|
<td>{{ article.name }}</td>
|
||||||
<td>{{ article.prix }}</td>
|
<td>{{ article.prix }}</td>
|
||||||
|
@ -54,7 +44,34 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
{% acl_end %}
|
{% acl_end %}
|
||||||
{% history_button article %}
|
{% history_button article %}
|
||||||
</td>
|
</td>
|
||||||
|
<th>{% trans "Article" %}</th>
|
||||||
|
<th>{% trans "Price" %}</th>
|
||||||
|
<th>{% trans "Cotisation type" %}</th>
|
||||||
|
<th>{% trans "Duration (month)" %}</th>
|
||||||
|
<th>{% trans "Concerned users" %}</th>
|
||||||
|
<th>{% trans "Available for everyone" %}</th>
|
||||||
|
<th></th>
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
</thead>
|
||||||
</table>
|
{% for article in article_list %}
|
||||||
|
<tr>
|
||||||
|
<td>{{ article.name }}</td>
|
||||||
|
<td>{{ article.prix }}</td>
|
||||||
|
<td>{{ article.type_cotisation }}</td>
|
||||||
|
<td>{{ article.duration }}</td>
|
||||||
|
<td>{{ article.type_user }}</td>
|
||||||
|
<td>{{ article.available_for_everyone|tick }}</td>
|
||||||
|
<td class="text-right">
|
||||||
|
{% can_edit article %}
|
||||||
|
<a class="btn btn-primary btn-sm" role="button" title="{% trans "Edit" %}" href="{% url 'cotisations:edit-article' article.id %}">
|
||||||
|
<i class="fa fa-edit"></i>
|
||||||
|
</a>
|
||||||
|
{% acl_end %}
|
||||||
|
<a class="btn btn-info btn-sm" role="button" title="{% trans "Historique" %}" href="{% url 'cotisations:history' 'article' article.id %}">
|
||||||
|
<i class="fa fa-history"></i>
|
||||||
|
</a>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
{% endfor %}
|
||||||
|
</table>
|
||||||
|
|
||||||
|
|
|
@ -25,17 +25,10 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
{% load acl %}
|
{% load acl %}
|
||||||
{% load i18n %}
|
{% load i18n %}
|
||||||
{% load logs_extra %}
|
{% load logs_extra %}
|
||||||
|
{% load design %}
|
||||||
|
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
|
||||||
<th>{% trans "Payment type" %}</th>
|
|
||||||
<th>{% trans "Is available for everyone" %}</th>
|
|
||||||
<th>{% trans "Custom payment method" %}</th>
|
|
||||||
<th></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
{% for paiement in paiement_list %}
|
|
||||||
<tr>
|
<tr>
|
||||||
<td>{{ paiement.moyen }}</td>
|
<td>{{ paiement.moyen }}</td>
|
||||||
<td>{{ paiement.available_for_everyone }}</td>
|
<td>{{ paiement.available_for_everyone }}</td>
|
||||||
|
@ -50,7 +43,30 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
{% acl_end %}
|
{% acl_end %}
|
||||||
{% history_button paiement %}
|
{% history_button paiement %}
|
||||||
</td>
|
</td>
|
||||||
|
<th>{% trans "Payment type" %}</th>
|
||||||
|
<th>{% trans "Is available for everyone" %}</th>
|
||||||
|
<th>{% trans "Custom payment method" %}</th>
|
||||||
|
<th></th>
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
</thead>
|
||||||
</table>
|
{% for paiement in paiement_list %}
|
||||||
|
<tr>
|
||||||
|
<td>{{ paiement.moyen }}</td>
|
||||||
|
<td>{{ paiement.available_for_everyone|tick }}</td>
|
||||||
|
<td>
|
||||||
|
{{paiement.get_payment_method_name}}
|
||||||
|
</td>
|
||||||
|
<td class="text-right">
|
||||||
|
{% can_edit paiement %}
|
||||||
|
<a class="btn btn-primary btn-sm" role="button" title="{% trans "Edit" %}" href="{% url 'cotisations:edit-paiement' paiement.id %}">
|
||||||
|
<i class="fa fa-edit"></i>
|
||||||
|
</a>
|
||||||
|
{% acl_end %}
|
||||||
|
<a class="btn btn-info btn-sm" role="button" title="{% trans "Historique" %}" href="{% url 'cotisations:history' 'paiement' paiement.id %}">
|
||||||
|
<i class="fa fa-history"></i>
|
||||||
|
</a>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
{% endfor %}
|
||||||
|
</table>
|
||||||
|
|
||||||
|
|
|
@ -24,6 +24,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
|
||||||
{% load acl %}
|
{% load acl %}
|
||||||
{% load logs_extra %}
|
{% load logs_extra %}
|
||||||
|
{% load design %}
|
||||||
|
|
||||||
<div class="table-responsive">
|
<div class="table-responsive">
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
|
@ -42,7 +43,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
{% for extension in extension_list %}
|
{% for extension in extension_list %}
|
||||||
<tr>
|
<tr>
|
||||||
<td>{{ extension.name }}</td>
|
<td>{{ extension.name }}</td>
|
||||||
<td>{{ extension.need_infra }}</td>
|
<td>{{ extension.need_infra|tick }}</td>
|
||||||
<td>{{ extension.soa}}</td>
|
<td>{{ extension.soa}}</td>
|
||||||
<td>{{ extension.origin }}</td>
|
<td>{{ extension.origin }}</td>
|
||||||
{% if ipv6_enabled %}
|
{% if ipv6_enabled %}
|
||||||
|
@ -53,6 +54,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
{% include 'buttons/edit.html' with href='machines:edit-extension' id=extension.id %}
|
{% include 'buttons/edit.html' with href='machines:edit-extension' id=extension.id %}
|
||||||
{% acl_end %}
|
{% acl_end %}
|
||||||
{% history_button extension %}
|
{% history_button extension %}
|
||||||
|
{% include 'buttons/history.html' with href='machines:history' name='extension' id=extension.id %}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
|
@ -22,6 +22,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
{% endcomment %}
|
{% endcomment %}
|
||||||
|
|
||||||
|
{% load design %}
|
||||||
|
|
||||||
{% load acl %}
|
{% load acl %}
|
||||||
{% load logs_extra %}
|
{% load logs_extra %}
|
||||||
<div class="table-responsive">
|
<div class="table-responsive">
|
||||||
|
@ -43,7 +45,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
<tr>
|
<tr>
|
||||||
<td>{{ type.type }}</td>
|
<td>{{ type.type }}</td>
|
||||||
<td>{{ type.extension }}</td>
|
<td>{{ type.extension }}</td>
|
||||||
<td>{{ type.need_infra }}</td>
|
<td>{{ type.need_infra|tick }}</td>
|
||||||
<td>{{ type.domaine_ip_start }}-{{ type.domaine_ip_stop }}</td>
|
<td>{{ type.domaine_ip_start }}-{{ type.domaine_ip_stop }}</td>
|
||||||
<td>{{ type.prefix_v6 }}</td>
|
<td>{{ type.prefix_v6 }}</td>
|
||||||
<td>{{ type.vlan }}</td>
|
<td>{{ type.vlan }}</td>
|
||||||
|
@ -53,6 +55,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
{% include 'buttons/edit.html' with href='machines:edit-iptype' id=type.id %}
|
{% include 'buttons/edit.html' with href='machines:edit-iptype' id=type.id %}
|
||||||
{% acl_end %}
|
{% acl_end %}
|
||||||
{% history_button type %}
|
{% history_button type %}
|
||||||
|
{% include 'buttons/history.html' with href='machines:history' name='iptype' id=type.id %}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
|
@ -24,6 +24,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
|
||||||
{% load acl %}
|
{% load acl %}
|
||||||
{% load logs_extra %}
|
{% load logs_extra %}
|
||||||
|
{% load design %}
|
||||||
|
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<thead>
|
<thead>
|
||||||
|
@ -42,12 +43,13 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
<td>{{ nas.nas_type }}</td>
|
<td>{{ nas.nas_type }}</td>
|
||||||
<td>{{ nas.machine_type }}</td>
|
<td>{{ nas.machine_type }}</td>
|
||||||
<td>{{ nas.port_access_mode }}</td>
|
<td>{{ nas.port_access_mode }}</td>
|
||||||
<td>{{ nas.autocapture_mac }}</td>
|
<td>{{ nas.autocapture_mac|tick }}</td>
|
||||||
<td class="text-right">
|
<td class="text-right">
|
||||||
{% can_edit nas %}
|
{% can_edit nas %}
|
||||||
{% include 'buttons/edit.html' with href='machines:edit-nas' id=nas.id %}
|
{% include 'buttons/edit.html' with href='machines:edit-nas' id=nas.id %}
|
||||||
{% acl_end %}
|
{% acl_end %}
|
||||||
{% history_button nas %}
|
{% history_button nas %}
|
||||||
|
{% include 'buttons/history.html' with href='machines:history' name='nas' id=nas.id %}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
|
@ -22,6 +22,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
{% endcomment %}
|
{% endcomment %}
|
||||||
|
|
||||||
|
{% load design %}
|
||||||
|
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
|
@ -37,8 +39,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
<td>{{ server.service }}</td>
|
<td>{{ server.service }}</td>
|
||||||
<td>{{ server.server }}</td>
|
<td>{{ server.server }}</td>
|
||||||
<td>{{ server.last_regen }}</td>
|
<td>{{ server.last_regen }}</td>
|
||||||
<td>{{ server.asked_regen }}</td>
|
<td>{{ server.asked_regen| tick }}</td>
|
||||||
<td>{{ server.need_regen }}</td>
|
<td>{{ server.need_regen | tick }}</td>
|
||||||
<td class="text-right">
|
<td class="text-right">
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
|
@ -47,6 +47,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
{% include 'buttons/edit.html' with href='machines:edit-service' id=service.id %}
|
{% include 'buttons/edit.html' with href='machines:edit-service' id=service.id %}
|
||||||
{% acl_end %}
|
{% acl_end %}
|
||||||
{% history_button service %}
|
{% history_button service %}
|
||||||
|
{% include 'buttons/history.html' with href='machines:history' name='service' id=service.id %}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
315
preferences/templates/preferences/display_preferences.html
Normal file → Executable file
315
preferences/templates/preferences/display_preferences.html
Normal file → Executable file
|
@ -25,198 +25,201 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
|
||||||
{% load bootstrap3 %}
|
{% load bootstrap3 %}
|
||||||
{% load acl %}
|
{% load acl %}
|
||||||
|
{% load design %}
|
||||||
|
|
||||||
{% block title %}Création et modification des préférences{% endblock %}
|
{% block title %}Création et modification des préférences{% endblock %}
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<h4>Préférences utilisateur</h4>
|
<h4>Préférences utilisateur</h4>
|
||||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalUser' %}">
|
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalUser' %}">
|
||||||
<i class="fa fa-edit"></i>
|
<i class="fa fa-edit"></i>
|
||||||
Editer
|
Editer
|
||||||
</a>
|
</a>
|
||||||
<p>
|
<p>
|
||||||
</p>
|
</p>
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Téléphone obligatoirement requis</th>
|
<th>Téléphone obligatoirement requis</th>
|
||||||
<td>{{ useroptions.is_tel_mandatory }}</td>
|
<td>{{ useroptions.is_tel_mandatory|tick }}</td>
|
||||||
<th>Champ gpg fingerprint</th>
|
<th>Auto inscription</th>
|
||||||
<td>{{ useroptions.gpg_fingerprint }}</td>
|
<td>{{ useroptions.self_adhesion|tick }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Creations d'adhérents par tous</th>
|
<th>Champ gpg fingerprint</th>
|
||||||
<td>{{ useroptions.all_can_create_adherent }}</td>
|
<td>{{ useroptions.gpg_fingerprint|tick }}</td>
|
||||||
<th>Creations de clubs par tous</th>
|
<th>Shell par défaut des utilisateurs</th>
|
||||||
<td>{{ useroptions.all_can_create_club }}</td>
|
<td>{{ useroptions.shell_default }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Auto inscription</th>
|
<th>Creations d'adhérents par tous</th>
|
||||||
<td>{{ useroptions.self_adhesion }}</td>
|
<td>{{ useroptions.all_can_create_adherent|tick }}</td>
|
||||||
<th>Shell par défaut des utilisateurs</th>
|
<th>Creations de clubs par tous</th>
|
||||||
<td>{{ useroptions.shell_default }}</td>
|
<td>{{ useroptions.all_can_create_club|tick }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<h4>Préférences machines</h4>
|
|
||||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalMachine' %}">
|
|
||||||
<i class="fa fa-edit"></i>
|
<h4>Préférences machines</h4>
|
||||||
Editer
|
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalMachine' %}">
|
||||||
</a>
|
<i class="fa fa-edit"></i>
|
||||||
<p>
|
Editer
|
||||||
</p>
|
</a>
|
||||||
<table class="table table-striped">
|
<p>
|
||||||
|
</p>
|
||||||
|
<table class="table table-striped">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Mot de passe par machine</th>
|
<th>Mot de passe par machine</th>
|
||||||
<td>{{ machineoptions.password_machine }}</td>
|
<td>{{ machineoptions.password_machine|tick }}</td>
|
||||||
<th>Machines/interfaces autorisées par utilisateurs</th>
|
<th>Machines/interfaces autorisées par utilisateurs</th>
|
||||||
<td>{{ machineoptions.max_lambdauser_interfaces }}</td>
|
<td>{{ machineoptions.max_lambdauser_interfaces }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Alias dns autorisé par utilisateur</th>
|
<th>Alias dns autorisé par utilisateur</th>
|
||||||
<td>{{ machineoptions.max_lambdauser_aliases }}</td>
|
<td>{{ machineoptions.max_lambdauser_aliases }}</td>
|
||||||
<th>Support de l'ipv6</th>
|
<th>Support de l'ipv6</th>
|
||||||
<td>{{ machineoptions.ipv6_mode }}</td>
|
<td>{{ machineoptions.ipv6_mode }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Creation de machines</th>
|
<th>Creation de machines</th>
|
||||||
<td>{{ machineoptions.create_machine }}</td>
|
<td>{{ machineoptions.create_machine|tick }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<h4>Préférences topologie</h4>
|
<h4>Préférences topologie</h4>
|
||||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalTopologie' %}">
|
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalTopologie' %}">
|
||||||
<i class="fa fa-edit"></i>
|
<i class="fa fa-edit"></i>
|
||||||
Editer
|
Editer
|
||||||
</a>
|
</a>
|
||||||
<p>
|
<p>
|
||||||
</p>
|
</p>
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Politique générale de placement de vlan</th>
|
<th>Politique générale de placement de vlan</th>
|
||||||
<td>{{ topologieoptions.radius_general_policy }}</td>
|
<td>{{ topologieoptions.radius_general_policy }}</td>
|
||||||
<th> Ce réglage défini la politique vlan après acceptation radius : soit sur le vlan de la plage d'ip de la machine, soit sur un vlan prédéfini dans "Vlan où placer les machines après acceptation RADIUS"</th>
|
<th> Ce réglage défini la politique vlan après acceptation radius : soit sur le vlan de la plage d'ip de la machine, soit sur un vlan prédéfini dans "Vlan où placer les machines après acceptation RADIUS"</th>
|
||||||
<td></td>
|
<td></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Vlan où placer les machines après acceptation RADIUS</th>
|
<th>Vlan où placer les machines après acceptation RADIUS</th>
|
||||||
<td>{{ topologieoptions.vlan_decision_ok }}</td>
|
<td>{{ topologieoptions.vlan_decision_ok }}</td>
|
||||||
<th>Vlan où placer les machines après rejet RADIUS</th>
|
<th>Vlan où placer les machines après rejet RADIUS</th>
|
||||||
<td>{{ topologieoptions.vlan_decision_nok }}</td>
|
<td>{{ topologieoptions.vlan_decision_nok }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<h4>Préférences generales</h4>
|
<h4>Préférences generales</h4>
|
||||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'GeneralOption' %}">
|
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'GeneralOption' %}">
|
||||||
<i class="fa fa-edit"></i>
|
<i class="fa fa-edit"></i>
|
||||||
Editer
|
Editer
|
||||||
</a>
|
</a>
|
||||||
<p>
|
<p>
|
||||||
</p>
|
</p>
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Nom du site web</th>
|
<th>Nom du site web</th>
|
||||||
<td>{{ generaloptions.site_name }}</td>
|
<td>{{ generaloptions.site_name }}</td>
|
||||||
<th>Adresse mail d'expedition automatique</th>
|
<th>Adresse mail d'expedition automatique</th>
|
||||||
<td>{{ generaloptions.email_from }}</td>
|
<td>{{ generaloptions.email_from }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Affichage de résultats dans le champ de recherche</th>
|
<th>Affichage de résultats dans le champ de recherche</th>
|
||||||
<td>{{ generaloptions.search_display_page }}</td>
|
<td>{{ generaloptions.search_display_page }}</td>
|
||||||
<th>Nombre d'items affichés en liste (taille normale)</th>
|
<th>Nombre d'items affichés en liste (taille normale)</th>
|
||||||
<td>{{ generaloptions.pagination_number }}</td>
|
<td>{{ generaloptions.pagination_number }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Nombre d'items affichés en liste (taille élevée)</th>
|
<th>Nombre d'items affichés en liste (taille élevée)</th>
|
||||||
<td>{{ generaloptions.pagination_large_number }}</td>
|
<td>{{ generaloptions.pagination_large_number }}</td>
|
||||||
<th>Temps avant expiration du lien de reinitialisation de mot de passe (en heures)</th>
|
<th>Temps avant expiration du lien de reinitialisation de mot de passe (en heures)</th>
|
||||||
<td>{{ generaloptions.req_expire_hrs }}</td>
|
<td>{{ generaloptions.req_expire_hrs }}</td>
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<th>Message global affiché sur le site</th>
|
|
||||||
<td>{{ generaloptions.general_message }}</td>
|
|
||||||
<th>Résumé des CGU</th>
|
|
||||||
<td>{{ generaloptions.GTU_sum_up }}</td>
|
|
||||||
<tr>
|
|
||||||
<tr>
|
|
||||||
<th>CGU</th>
|
|
||||||
<td>{{generaloptions.GTU}}</th>
|
|
||||||
</tr>
|
|
||||||
</table>
|
|
||||||
<h4>Données de l'association</h4>
|
|
||||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'AssoOption' %}">
|
|
||||||
<i class="fa fa-edit"></i>
|
|
||||||
Editer
|
|
||||||
</a>
|
|
||||||
<p>
|
|
||||||
</p>
|
|
||||||
<table class="table table-striped">
|
|
||||||
<tr>
|
|
||||||
<th>Nom</th>
|
|
||||||
<td>{{ assooptions.name }}</td>
|
|
||||||
<th>SIRET</th>
|
|
||||||
<td>{{ assooptions.siret }}</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Adresse</th>
|
<th>Message global affiché sur le site</th>
|
||||||
<td>{{ assooptions.adresse1 }}<br>
|
<td>{{ generaloptions.general_message }}</td>
|
||||||
{{ assooptions.adresse2 }}</td>
|
<th>Résumé des CGU</th>
|
||||||
<th>Contact mail</th>
|
<td>{{ generaloptions.GTU_sum_up }}</td>
|
||||||
<td>{{ assooptions.contact }}</td>
|
<tr>
|
||||||
|
<tr>
|
||||||
|
<th>CGU</th>
|
||||||
|
<td>{{generaloptions.GTU}}</th>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<h4>Données de l'association</h4>
|
||||||
|
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'AssoOption' %}">
|
||||||
|
<i class="fa fa-edit"></i>
|
||||||
|
Editer
|
||||||
|
</a>
|
||||||
|
<p>
|
||||||
|
</p>
|
||||||
|
<table class="table table-striped">
|
||||||
|
<tr>
|
||||||
|
<th>Nom</th>
|
||||||
|
<td>{{ assooptions.name }}</td>
|
||||||
|
<th>SIRET</th>
|
||||||
|
<td>{{ assooptions.siret }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Telephone</th>
|
<th>Adresse</th>
|
||||||
<td>{{ assooptions.telephone }}</td>
|
<td>{{ assooptions.adresse1 }}<br>
|
||||||
<th>Pseudo d'usage</th>
|
{{ assooptions.adresse2 }}</td>
|
||||||
<td>{{ assooptions.pseudo }}</td>
|
<th>Contact mail</th>
|
||||||
|
<td>{{ assooptions.contact }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Objet utilisateur de l'association</th>
|
<th>Telephone</th>
|
||||||
<td>{{ assooptions.utilisateur_asso }}</td>
|
<td>{{ assooptions.telephone }}</td>
|
||||||
<th>Description de l'association</th>
|
<th>Pseudo d'usage</th>
|
||||||
|
<td>{{ assooptions.pseudo }}</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>Objet utilisateur de l'association</th>
|
||||||
|
<td>{{ assooptions.utilisateur_asso }}</td>
|
||||||
|
<th>Description de l'association</th>
|
||||||
<td>{{ assooptions.description | safe }}</td>
|
<td>{{ assooptions.description | safe }}</td>
|
||||||
</tr>
|
|
||||||
|
|
||||||
</table>
|
|
||||||
<h4>Messages personalisé dans les mails</h4>
|
|
||||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'MailMessageOption' %}">
|
|
||||||
<i class="fa fa-edit"></i>
|
|
||||||
Editer
|
|
||||||
</a>
|
|
||||||
<p>
|
|
||||||
</p>
|
|
||||||
<table class="table table-striped">
|
|
||||||
<tr>
|
|
||||||
<th>Mail de bienvenue (Français)</th>
|
|
||||||
<td>{{ mailmessageoptions.welcome_mail_fr | safe }}</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<th>Mail de bienvenue (Anglais)</th>
|
|
||||||
<td>{{ mailmessageoptions.welcome_mail_en | safe }}</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
|
||||||
<h2>Liste des services et préférences page d'accueil</h2>
|
|
||||||
{% can_create preferences.Service%}
|
|
||||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:add-service' %}"><i class="fa fa-plus"></i> Ajouter un service</a>
|
|
||||||
{% acl_end %}
|
|
||||||
<a class="btn btn-danger btn-sm" role="button" href="{% url 'preferences:del-services' %}"><i class="fa fa-trash"></i> Supprimer un ou plusieurs service</a>
|
|
||||||
{% include "preferences/aff_service.html" with service_list=service_list %}
|
|
||||||
|
|
||||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'HomeOption' %}">
|
</table>
|
||||||
<i class="fa fa-edit"></i>
|
<h4>Messages personalisé dans les mails</h4>
|
||||||
Editer
|
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'MailMessageOption' %}">
|
||||||
</a>
|
<i class="fa fa-edit"></i>
|
||||||
<p>
|
Editer
|
||||||
|
</a>
|
||||||
<table class="table table-striped">
|
<p>
|
||||||
|
</p>
|
||||||
|
<table class="table table-striped">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Url du compte twitter</th>
|
<th>Mail de bienvenue (Français)</th>
|
||||||
<td>{{ homeoptions.twitter_url }}</td>
|
<td>{{ mailmessageoptions.welcome_mail_fr | safe }}</td>
|
||||||
<th>Nom utilisé pour afficher le compte</th>
|
|
||||||
<td>{{ homeoptions.twitter_account_name }}</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Url du compte facebook</th>
|
<th>Mail de bienvenue (Anglais)</th>
|
||||||
<td>{{ homeoptions.facebook_url }}</td>
|
<td>{{ mailmessageoptions.welcome_mail_en | safe }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<br />
|
<h2>Liste des services et préférences page d'accueil</h2>
|
||||||
<br />
|
{% can_create preferences.Service%}
|
||||||
<br />
|
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:add-service' %}"><i class="fa fa-plus"></i> Ajouter un service</a>
|
||||||
|
{% acl_end %}
|
||||||
|
<a class="btn btn-danger btn-sm" role="button" href="{% url 'preferences:del-services' %}"><i class="fa fa-trash"></i> Supprimer un ou plusieurs service</a>
|
||||||
|
{% include "preferences/aff_service.html" with service_list=service_list %}
|
||||||
|
|
||||||
|
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'HomeOption' %}">
|
||||||
|
<i class="fa fa-edit"></i>
|
||||||
|
Editer
|
||||||
|
</a>
|
||||||
|
<p>
|
||||||
|
|
||||||
|
<table class="table table-striped">
|
||||||
|
<tr>
|
||||||
|
<th>Url du compte twitter</th>
|
||||||
|
<td>{{ homeoptions.twitter_url }}</td>
|
||||||
|
<th>Nom utilisé pour afficher le compte</th>
|
||||||
|
<td>{{ homeoptions.twitter_account_name }}</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>Url du compte facebook</th>
|
||||||
|
<td>{{ homeoptions.facebook_url }}</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
19
preferences/templatetags/__init__.py
Normal file
19
preferences/templatetags/__init__.py
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
#re2o est un logiciel d'administration développé initiallement au rezometz. Il
|
||||||
|
# se veut agnostique au réseau considéré, de manière à être installable en
|
||||||
|
# quelques clics.
|
||||||
|
#
|
||||||
|
# Copyright © 2017 Maël Kervella
|
||||||
|
#
|
||||||
|
# This program is free software; you can redistribute it and/or modify
|
||||||
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
# the Free Software Foundation; either version 2 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License along
|
||||||
|
# with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
39
re2o/templatetags/design.py
Normal file
39
re2o/templatetags/design.py
Normal file
|
@ -0,0 +1,39 @@
|
||||||
|
#re2o est un logiciel d'administration développé initiallement au rezometz. Il
|
||||||
|
# se veut agnostique au réseau considéré, de manière à être installable en
|
||||||
|
# quelques clics.
|
||||||
|
#
|
||||||
|
# Copyright © 2017 Maël Kervella
|
||||||
|
#
|
||||||
|
# This program is free software; you can redistribute it and/or modify
|
||||||
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
# the Free Software Foundation; either version 2 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License along
|
||||||
|
# with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
|
||||||
|
from django import template
|
||||||
|
from django.utils.html import conditional_escape
|
||||||
|
from django.utils.safestring import mark_safe
|
||||||
|
|
||||||
|
register = template.Library()
|
||||||
|
|
||||||
|
|
||||||
|
@register.filter(needs_autoescape=False)
|
||||||
|
def tick(valeur, autoescape=False):
|
||||||
|
|
||||||
|
if isinstance(valeur,bool):
|
||||||
|
if valeur == True:
|
||||||
|
result = '<i style="color: #1ECA18;" class="fas fa-check"></i>'
|
||||||
|
else:
|
||||||
|
result = '<i style="color: #D10115;" class="fas fa-times"></i>'
|
||||||
|
return mark_safe(result)
|
||||||
|
|
||||||
|
else: # if the value is not a boolean, display it as if tick was not called
|
||||||
|
return valeur
|
Loading…
Reference in a new issue