mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-22 11:23:10 +00:00
Merge branch 'front_pref' into 'dev'
Front pref See merge request federez/re2o!359
This commit is contained in:
commit
9d3fc3a5c9
2 changed files with 222 additions and 103 deletions
|
@ -31,14 +31,84 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
{% block title %}{% trans "Preferences" %}{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h4>{% trans "User preferences" %}</h4>
|
||||
<div id="accordion">
|
||||
|
||||
<div class="panel panel-default" id="general">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_general">
|
||||
<h4 class="panel-title" id="general">
|
||||
<a><i class="fa fa-cog"></i> {% trans "General preferences" %}</a>
|
||||
</h4>
|
||||
</div>
|
||||
|
||||
<div id="collapse_general" class="panel-collapse panel-body collapse">
|
||||
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'GeneralOption' %}">
|
||||
<i class="fa fa-edit"></i>{% trans "Edit" %}
|
||||
</a>
|
||||
<p></p>
|
||||
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Website name" %}</th>
|
||||
<td>{{ generaloptions.site_name }}</td>
|
||||
<th>{% trans "Email address for automatic emailing" %}</th>
|
||||
<td>{{ generaloptions.email_from }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "Number of results displayed when searching" %}</th>
|
||||
<td>{{ generaloptions.search_display_page }}</td>
|
||||
<th>{% trans "Number of items per page (standard size)" %}</th>
|
||||
<td>{{ generaloptions.pagination_number }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "Number of items per page (large size)" %}</th>
|
||||
<td>{{ generaloptions.pagination_large_number }}</td>
|
||||
<th>{% trans "Time before expiration of the reset password link (in hours)" %}</th>
|
||||
<td>{{ generaloptions.req_expire_hrs }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "General message displayed on the website" %}</th>
|
||||
<td>{{ generaloptions.general_message }}</td>
|
||||
<th>{% trans "Main site url" %}</th>
|
||||
<td>{{ generaloptions.main_site_url }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "Summary of the General Terms of Use" %}</th>
|
||||
<td>{{ generaloptions.GTU_sum_up }}</td>
|
||||
<th>{% trans "General Terms of Use" %}</th>
|
||||
<td>{{ generaloptions.GTU }}</th>
|
||||
</tr>
|
||||
</table>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Local email accounts enabled" %}</th>
|
||||
<td>{{ useroptions.local_email_accounts_enabled|tick }}</td>
|
||||
<th>{% trans "Local email domain" %}</th>
|
||||
<td>{{ useroptions.local_email_domain }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "Maximum number of email aliases allowed" %}</th>
|
||||
<td>{{ useroptions.max_email_address }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default" id="users">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_users">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-users fa-fw"></i> {% trans "User preferences" %}</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_users" class="panel-collapse panel-body collapse">
|
||||
|
||||
<p></p>
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalUser' %}">
|
||||
<i class="fa fa-edit"></i>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<p>
|
||||
</p>
|
||||
<h5>{% trans "General preferences" %}</h5>
|
||||
<p></p>
|
||||
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Creation of members by everyone" %}</th>
|
||||
|
@ -54,7 +124,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
</tr>
|
||||
</table>
|
||||
|
||||
<h5>{% trans "Users general permissions" %}</h5>
|
||||
<h4 id="users">{% trans "Users general permissions" %}</h4>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Default shell for users" %}</th>
|
||||
|
@ -73,27 +143,24 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<td>{{ useroptions.gpg_fingerprint|tick }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default" id="machines">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_machines">
|
||||
<h4 class ="panel-title">
|
||||
<a><i class="fa fa-desktop"></i> {% trans "Machines preferences" %}</a>
|
||||
</h4>
|
||||
</div>
|
||||
|
||||
<div id="collapse_machines" class="panel-collapse panel-body collapse">
|
||||
|
||||
<h5>{% trans "Email accounts preferences" %}</h5>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Local email accounts enabled" %}</th>
|
||||
<td>{{ useroptions.local_email_accounts_enabled|tick }}</td>
|
||||
<th>{% trans "Local email domain" %}</th>
|
||||
<td>{{ useroptions.local_email_domain }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "Maximum number of email aliases allowed" %}</th>
|
||||
<td>{{ useroptions.max_email_address }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h4>{% trans "Machines preferences" %}</h4>
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalMachine' %}">
|
||||
<i class="fa fa-edit"></i>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<p>
|
||||
</p>
|
||||
<p></p>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Password per machine" %}</th>
|
||||
|
@ -112,13 +179,22 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<td>{{ machineoptions.create_machine|tick }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h4>{% trans "Topology preferences" %}</h4>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default" id="topo">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_topo">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-sitemap"></i> {% trans "Topology preferences" %}</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_topo" class="panel-collapse panel-body collapse">
|
||||
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalTopologie' %}">
|
||||
<i class="fa fa-edit"></i>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<p>
|
||||
</p>
|
||||
<p></p>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "General policy for VLAN setting" %}</th>
|
||||
|
@ -138,13 +214,29 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
</tr>
|
||||
</table>
|
||||
|
||||
<h6>Clef radius</h6>
|
||||
<h4>Clef radius</h4>
|
||||
{% can_create RadiusKey%}
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:add-radiuskey' %}"><i class="fa fa-plus"></i> Ajouter une clef radius</a>
|
||||
{% acl_end %}
|
||||
{% include "preferences/aff_radiuskey.html" with radiuskey_list=radiuskey_list %}
|
||||
|
||||
<h4>Configuration des switches</h4>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default" id="switches">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_switches">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-server"></i> Configuration des Switches</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_switches" class="panel-collapse panel-body collapse">
|
||||
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'OptionalTopologie' %}">
|
||||
<i class="fa fa-edit"></i>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<p></p>
|
||||
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>Web management, activé si provision automatique</th>
|
||||
|
@ -192,55 +284,23 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
</p>
|
||||
{% if switchmanagementcred_list %}<span class="label label-success"> OK{% else %}<span class="label label-danger">Manquant{% endif %}</span>
|
||||
{% include "preferences/aff_switchmanagementcred.html" with switchmanagementcred_list=switchmanagementcred_list %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="panel panel-default" id="asso">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_asso">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-at"></i> {% trans "Information about the organisation" %}</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_asso" class="panel-collapse panel-body collapse">
|
||||
|
||||
<h4>{% trans "General preferences" %}</h4>
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'GeneralOption' %}">
|
||||
<i class="fa fa-edit"></i>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<p>
|
||||
</p>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Website name" %}</th>
|
||||
<td>{{ generaloptions.site_name }}</td>
|
||||
<th>{% trans "Email address for automatic emailing" %}</th>
|
||||
<td>{{ generaloptions.email_from }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "Number of results displayed when searching" %}</th>
|
||||
<td>{{ generaloptions.search_display_page }}</td>
|
||||
<th>{% trans "Number of items per page (standard size)" %}</th>
|
||||
<td>{{ generaloptions.pagination_number }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "Number of items per page (large size)" %}</th>
|
||||
<td>{{ generaloptions.pagination_large_number }}</td>
|
||||
<th>{% trans "Time before expiration of the reset password link (in hours)" %}</th>
|
||||
<td>{{ generaloptions.req_expire_hrs }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "General message displayed on the website" %}</th>
|
||||
<td>{{ generaloptions.general_message }}</td>
|
||||
<th>{% trans "Main site url" %}</th>
|
||||
<td>{{ generaloptions.main_site_url }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{% trans "Summary of the General Terms of Use" %}</th>
|
||||
<td>{{ generaloptions.GTU_sum_up }}</td>
|
||||
<th>{% trans "General Terms of Use" %}</th>
|
||||
<td>{{ generaloptions.GTU }}</th>
|
||||
</tr>
|
||||
</table>
|
||||
<h4>{% trans "Information about the organisation" %}</h4>
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'AssoOption' %}">
|
||||
<i class="fa fa-edit"></i>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<p>
|
||||
</p>
|
||||
<p></p>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Name" %}</th>
|
||||
|
@ -269,13 +329,23 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<td>{{ assooptions.description|safe }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h4>{% trans "Custom email message" %}</h4>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default" id="mail">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_mail">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-comment"></i> Message pour les mails</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_mail" class="panel-collapse panel-body collapse">
|
||||
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'MailMessageOption' %}">
|
||||
<i class="fa fa-edit"></i>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<p>
|
||||
</p>
|
||||
<p></p>
|
||||
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Welcome email (in French)" %}</th>
|
||||
|
@ -286,29 +356,73 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<td>{{ mailmessageoptions.welcome_mail_en|safe }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h4>Options pour le mail de fin d'adhésion</h2>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default" id="rappels">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_rappels">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-bell"></i> Options pour le mail de fin d'adhésion</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_rappels" class="panel-collapse panel-body collapse">
|
||||
{% can_create preferences.Reminder%}
|
||||
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:add-reminder' %}"><i class="fa fa-plus"></i> Ajouter un rappel</a>
|
||||
<p></p>
|
||||
{% acl_end %}
|
||||
{% include "preferences/aff_reminder.html" with reminder_list=reminder_list %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h4>{% trans "List of services and homepage preferences" %}</h4>
|
||||
|
||||
<div class="panel panel-default" id="services">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_services">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-home"></i> {% trans "List of services and homepage preferences" %}</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_services" class="panel-collapse panel-body collapse">
|
||||
{% can_create preferences.Service%}
|
||||
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:add-service' %}"><i class="fa fa-plus"></i>{% trans " Add a service" %}</a>
|
||||
<p></p>
|
||||
{% acl_end %}
|
||||
{% 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>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<h2>{% trans "List of contact email addresses" %}</h2>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default" id="contact">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_contact">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-list-ul"></i> {% trans "List of contact email addresses" %}</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_contact" class="panel-collapse panel-body collapse">
|
||||
|
||||
{% can_create preferences.MailContact %}
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:add-mailcontact' %}"><i class="fa fa-plus"></i>{% trans "Add an address" %}</a>
|
||||
{% acl_end %}
|
||||
<a class="btn btn-danger btn-sm" role="button" href="{% url 'preferences:del-mailcontact' %}"><i class="fa fa-trash"></i>{% trans "Delete one or several addresses" %}</a>
|
||||
<p></p>
|
||||
{% include "preferences/aff_mailcontact.html" with mailcontact_list=mailcontact_list %}
|
||||
<p>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default" id="social">
|
||||
<div class="panel-heading" data-toggle="collapse" href="#collapse_social">
|
||||
<h4 class="panel-title">
|
||||
<a><i class="fa fa-facebook"></i><i class="fa fa-twitter"></i> Réseaux sociaux</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div id="collapse_social" class="panel-collapse panel-body collapse">
|
||||
|
||||
<a class="btn btn-primary btn-sm" role="button" href="{% url 'preferences:edit-options' 'HomeOption' %}">
|
||||
<i class="fa fa-edit"></i>
|
||||
{% trans "Edit" %}
|
||||
</a>
|
||||
<p></p>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th>{% trans "Twitter account URL" %}</th>
|
||||
|
@ -321,5 +435,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
<td>{{ homeoptions.facebook_url }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
||||
|
||||
|
|
|
@ -22,6 +22,8 @@ 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.
|
||||
{% endcomment %}
|
||||
{% load acl %}
|
||||
{% load i18n %}
|
||||
|
||||
|
||||
{% block sidebar %}
|
||||
|
|
Loading…
Reference in a new issue