1 {% extends 'page.html.twig' %}
4 <form action="{{ path_for('store-preferences') }}" method="post" enctype="multipart/form-data" class="ui form">
5 <div class="ui stackable pointing inverted menu tabbed">
6 <a class="item active" data-tab="general">{{ _T("General") }}</a>
7 <a class="item" data-tab="social">{{ _T("Social networks") }}</a>
8 <a class="item" data-tab="parameters">{{ _T("Parameters") }}</a>
9 <a class="item" data-tab="rights">{{ _T("Rights") }}</a>
10 <a class="item" data-tab="mail">{{ _T("E-Mail") }}</a>
11 <a class="item" data-tab="labels">{{ _T("Labels") }}</a>
12 <a class="item" data-tab="cards">{{ _T("Cards") }}</a>
13 {% if login.isAdmin() %}
14 <a class="item" data-tab="security">{{ _T("Security parameters") }}</a>
16 {% if login.isSuperAdmin() %}
17 <a class="item" data-tab="admin">{{ _T("Admin") }}</a>
20 <div class="ui active tab segment" data-tab="general">
21 <div class="ui stackable two column grid">
23 <div class="{% if required.pref_nom == 1 %}required {% endif %} field">
24 <label for="pref_nom">{{ _T("Name of the association:") }}</label>
25 <input{% if required.pref_nom == 1 %} required="required"{% endif %} type="text" name="pref_nom" id="pref_nom" value="{{ pref.pref_nom }}" maxlength="190"/>
27 <div class="{% if required.pref_slogan is defined and required.pref_slogan == 1 %}required {% endif %} field">
28 <label for="pref_slogan">{{ _T("Association's short description:") }}</label>
29 <div class="ui right corner labeled input">
30 <input{% if required.pref_slogan is defined and required.pref_slogan == 1 %} required="required"{% endif %} type="text" name="pref_slogan" id="pref_slogan" value="{{ pref.pref_slogan }}"/>
31 <div class="ui basic label">
33 href="{{ path_for("dynamicTranslations", { "text_orig": pref.pref_slogan|escape }) }}"
34 class="ui icon tooltip" title="{{ _T("Translate '%s'")|replace({'%s': pref.pref_slogan}) }}"
36 <i class="language icon"></i>
37 <span class="sr-only">{{ _T("Translate '%s'")|replace({'%s': pref.pref_slogan}) }}</span>
39 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Enter here a short description for your association, it will be displayed on the index page and into pages' title.") }}"></i>
46 <label for="logo_picture">{{ _T("Logo:") }}</label>
47 {% if logo.isCustom() %}
48 <img src="{{ path_for('logo') }}" class="picture" width="{{ logo.getOptimalWidth() }}" height="{{ logo.getOptimalHeight() }}" alt="{{ _T("Current logo") }}"/><br/>
49 <label for="del_logo">{{ _T("Delete image") }}</label><input type="checkbox" name="del_logo" id="del_logo" value="1" /><br />
51 <input type="file" name="logo" id="logo_picture"{% if constant('GALETTE_MODE') == constant('\\Galette\\Core\\Galette::MODE_DEMO') %} disabled="disabled"{% endif %}/>
55 <div class="ui stackable two column grid">
57 <div class="{% if required.pref_adresse is defined and required.pref_adresse == 1 %}required {% endif %} field">
58 <label for="pref_adresse">{{ _T("Address:") }}</label>
59 <input{% if required.pref_adresse is defined and required.pref_adresse == 1 %} required="required"{% endif %} type="text" name="pref_adresse" id="pref_adresse" value="{{ pref.pref_adresse }}" maxlength="190"/><br/>
62 <label for="pref_adresse2" class="libelle">{{ _T("Address:") }} {{ _T(" (continuation)") }}</label>
63 <input type="text" name="pref_adresse2" id="pref_adresse2" value="{{ pref.pref_adresse2 }}" maxlength="190"/>
65 <div class="{% if required.pref_cp is defined and required.pref_cp == 1 %}required {% endif %} field">
66 <label for="pref_cp">{{ _T("Zip Code:") }}</label>
67 <input{% if required.pref_cp is defined and required.pref_cp == 1 %} required="required"{% endif %} type="text" name="pref_cp" id="pref_cp" value="{{ pref.pref_cp }}" maxlength="10"/>
69 <div class="{% if required.pref_ville is defined and required.pref_ville == 1 %}required {% endif %} field">
70 <label for="pref_ville">{{ _T("City:") }}</label>
71 <input{% if required.pref_ville is defined and required.pref_ville == 1 %} required="required"{% endif %} type="text" name="pref_ville" id="pref_ville" value="{{ pref.pref_ville }}" maxlength="100"/>
73 <div class="{% if required.pref_pays is defined and required.pref_pays == 1 %}required {% endif %} field">
74 <label for="pref_pays">{{ _T("Country:") }}</label>
75 <input{% if required.pref_pays is defined and required.pref_pays == 1 %} required="required"{% endif %} type="text" name="pref_pays" id="pref_pays" value="{{ pref.pref_pays }}" maxlength="50"/>
77 <div class="{% if required.pref_website is defined and required.pref_website == 1 %}required {% endif %} field">
78 <label for="pref_website">{{ _T("Website:") }}</label>
79 <input{% if required.pref_website is defined and required.pref_website == 1 %} required="required"{% endif %} type="text" name="pref_website" id="pref_website" value="{{ pref.pref_website }}" maxlength="100"/>
85 {{ _T("Postal address:") }}
86 <i class="circular inverted primary small icon info tooltip" data-html="{{ _T("Use either the address setted below or select a staff member to retrieve he's address.") }}"></i>
88 <div class="inline fields">
90 <label for="pref_postal_adress_0">{{ _T("from preferences") }}</label>
91 <input type="radio" name="pref_postal_adress" id="pref_postal_adress_0" value=" {{ constant('Galette\\Core\\Preferences::POSTAL_ADDRESS_FROM_PREFS') }}}" {% if pref.pref_postal_adress == constant('Galette\\Core\\Preferences::POSTAL_ADDRESS_FROM_PREFS') %}checked="checked"{% endif %}/>
94 <label for="pref_postal_adress_1">{{ _T("from a staff user") }}</label>
95 <input type="radio" name="pref_postal_adress" id="pref_postal_adress_1" value=" {{ constant('Galette\\Core\\Preferences::POSTAL_ADDRESS_FROM_STAFF') }}}" {% if pref.pref_postal_adress == constant('Galette\\Core\\Preferences::POSTAL_ADDRESS_FROM_STAFF') %}checked="checked"{% endif %}/>
98 <label for="pref_postal_staff_member">{{ _T("Staff member") }}</label>
99 <select name="pref_postal_staff_member" id="pref_postal_staff_member" class="ui search dropdown nochosen">
100 <option value="-1">{{ _T("-- Choose a staff member --") }}</option>
101 {% for staff in staff_members %}
102 <option value="{{ staff.id }}"{% if staff.id == pref.pref_postal_staff_member %} selected="selected"{% endif %}>{{ staff.name }} ({{ staff.sstatus }})</option>
107 <label for="pref_footer">{{ _T("Footer text:") }}</label>
108 <div class="ui right corner labeled input">
109 <div class="ui corner label">
110 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Enter a text (HTML allowed) that will be displayed in the footer of every page") }}"></i>
112 <textarea name="pref_footer" id="pref_footer" rows="2">{{ pref.pref_footer }}</textarea>
117 {{ _T("Telemetry date:") }}
118 <i class="circular inverted primary small icon info tooltip" data-html="{{ _T("Last telemetry sent date.") }}"></i>
121 {{ preferences.getTelemetryDate() }}
122 - <a href="#" id="telemetry" class="ui labeled icon button"><i class="chart bar icon" aria-hidden="true"></i> {{ _T("send") }}</a>
127 {{ _T("Registration date:") }}
128 <i class="circular inverted primary small icon info tooltip" data-html="{{ _T("Date on which you registered your Galette instance.") }}"></i>
131 {% if pref.pref_registration_date %}
132 {% set regtxt = _T("Update your information") %}
133 {{ preferences.getRegistrationDate() }}
135 {% set regtxt = _T("Register") %}
136 {{ _T("Not registered") }}
138 - <a href="{{ constant('GALETTE_TELEMETRY_URI') }}reference?showmodal&uuid={{ pref.pref_registration_uuid }}" id="register" target="_blank" class="ui labeled icon button"><i class="pen alternate icon"></i>{{ regtxt }}</a>
142 </div>{# /column grid #}
143 </div>{# /tab segment #}
144 {% set socials = preferences.socials %}
145 {% include "elements/edit_socials.html.twig" %}
146 <div class="ui tab segment" data-tab="parameters">
147 <div class="ui stackable two column grid">
150 <label for="pref_lang" >{{ _T("Default language:") }}</label>
151 <select name="pref_lang" id="pref_lang" class="lang ui search dropdown nochosen">
152 {% for langue in languages %}
153 <option value="{{ langue.getID() }}" {% if pref.pref_lang == langue.getID() %}selected="selected"{% endif %}>{{ langue.getName()|capitalize }}</option>
157 {#<div class="field">
158 <label for="pref_theme">{{ _T("Default theme:") }}</label>
159 <select name="pref_theme" id="pref_theme" class="ui search dropdown nochosen">
160 {% for theme in themes %}
161 <option value="{{ theme }}" {% if pref.pref_theme == theme %}selected="selected"{% endif %}>{{ theme|capitalize }}</option>
166 <label for="pref_numrows">{{ _T("Lines / Page:") }}</label>
167 <select name="pref_numrows" id="pref_numrows" class="ui search dropdown nochosen">
168 {% for key, value in pref_numrows_options %}
169 <option value="{{ key }}"{% if key == pref.pref_numrows %} selected="selected"{% endif %}>{{ value }}</option>
174 <label for="pref_redirect_on_create">{{ _T("After member creation:") }}</label>
175 <select name="pref_redirect_on_create" id="pref_redirect_on_create" class="ui search dropdown nochosen">
176 <option value="{constant('Galette\\Entity\\Adherent::AFTER_ADD_DEFAULT')}"{% if pref.pref_redirect_on_create == constant('Galette\\Entity\\Adherent::AFTER_ADD_DEFAULT') %} selected="selected"{% endif %}>{{ _T("create a new contribution (default action)") }}</option>
177 <option value="{constant('Galette\\Entity\\Adherent::AFTER_ADD_TRANS')}"{% if pref.pref_redirect_on_create == constant('Galette\\Entity\\Adherent::AFTER_ADD_TRANS') %} selected="selected"{% endif %}>{{ _T("create a new transaction") }}</option>
178 <option value="{constant('Galette\\Entity\\Adherent::AFTER_ADD_NEW')}"{% if pref.pref_redirect_on_create == constant('Galette\\Entity\\Adherent::AFTER_ADD_NEW') %} selected="selected"{% endif %}>{{ _T("create another new member") }}</option>
179 <option value="{constant('Galette\\Entity\\Adherent::AFTER_ADD_SHOW')}"{% if pref.pref_redirect_on_create == constant('Galette\\Entity\\Adherent::AFTER_ADD_SHOW') %} selected="selected"{% endif %}>{{ _T("show member") }}</option>
180 <option value="{constant('Galette\\Entity\\Adherent::AFTER_ADD_LIST')}"{% if pref.pref_redirect_on_create == constant('Galette\\Entity\\Adherent::AFTER_ADD_LIST') %} selected="selected"{% endif %}>{{ _T("go to members list") }}</option>
181 <option value="{constant('Galette\\Entity\\Adherent::AFTER_ADD_HOME')}"{% if pref.pref_redirect_on_create == constant('Galette\\Entity\\Adherent::AFTER_ADD_HOME') %} selected="selected"{% endif %}>{{ _T("go to main page") }}</option>
185 <label for="pref_log">{{ _T("Logging level:") }}</label>
186 <select name="pref_log" id="pref_log" class="ui search dropdown nochosen">
187 <option value=" {{ constant('Galette\\Core\\Preferences::LOG_DISABLED') }}}" {% if pref.pref_log == constant('Galette\\Core\\Preferences::LOG_DISABLED') %}selected="selected"{% endif %}>{{ _T("Disabled") }}</option>
188 <option value=" {{ constant('Galette\\Core\\Preferences::LOG_ENABLED') }}}" {% if pref.pref_log == constant('Galette\\Core\\Preferences::LOG_ENABLED') %}selected="selected"{% endif %}>{{ _T("Enabled") }}</option>
192 <label for="pref_filter_account">{{ _T("Default account filter:") }}</label>
193 <select name="pref_filter_account" id="pref_filter_account" class="ui search dropdown nochosen">
194 {% for key, value in accounts_options %}
195 <option value="{{ key }}"{% if key == pref.pref_filter_account %} selected="selected"{% endif %}>{{ value }}</option>
200 <label for="pref_default_paymenttype">{{ _T("Default payment type:") }}</label>
201 <select name="pref_default_paymenttype" id="pref_default_paymenttype" class="ui search dropdown nochosen">
202 {% for key, value in paymenttypes %}
203 <option value="{{ key }}"{% if key == pref.pref_default_paymenttype %} selected="selected"{% endif %}>{{ value }}</option>
209 <div class="field inline">
210 <label for="pref_bool_publicpages">{{ _T("Public pages enabled?") }}</label>
211 <input type="checkbox" name="pref_bool_publicpages" id="pref_bool_publicpages" value="1" {% if pref.pref_bool_publicpages %} checked="checked"{% endif %}/>
213 <div class="field" id="publicpages_visibility"{% if not pref.pref_bool_publicpages %} class="hidden"{% endif %}>
214 <label for="pref_publicpages_visibility">{{ _T("Show public pages for") }}</label>
215 <select name="pref_publicpages_visibility" id="pref_publicpages_visibility" class="ui search dropdown nochosen">
216 <option value=" {{ constant('Galette\\Core\\Preferences::PUBLIC_PAGES_VISIBILITY_PUBLIC') }}}"{% if pref.pref_publicpages_visibility == constant('Galette\\Core\\Preferences::PUBLIC_PAGES_VISIBILITY_PUBLIC') %} selected="selected"{% endif %}>{{ _T("Everyone") }}</option>
217 <option value=" {{ constant('Galette\\Core\\Preferences::PUBLIC_PAGES_VISIBILITY_RESTRICTED') }}}"{% if pref.pref_publicpages_visibility == constant('Galette\\Core\\Preferences::PUBLIC_PAGES_VISIBILITY_RESTRICTED') %} selected="selected"{% endif %}>{{ _T("Up to date members") }}</option>
218 <option value=" {{ constant('Galette\\Core\\Preferences::PUBLIC_PAGES_VISIBILITY_PRIVATE') }}}"{% if pref.pref_publicpages_visibility == constant('Galette\\Core\\Preferences::PUBLIC_PAGES_VISIBILITY_PRIVATE') %} selected="selected"{% endif %}>{{ _T("Admin and staff only") }}</option>
221 <div class="field inline">
222 <label for="pref_bool_selfsubscribe">{{ _T("Self subscription enabled?") }}</label>
223 <input type="checkbox" name="pref_bool_selfsubscribe" id="pref_bool_selfsubscribe" value="1"{% if pref.pref_bool_selfsubscribe %} checked="checked"{% endif %}/>
226 <label for="pref_new_contrib_script" class="tooltip">{{ _T("Post new contribution script URI") }}</label>
227 <div class="ui right corner labeled input">
228 <div class="ui corner label">
229 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Enter a script URI that would be called after adding a new contribution.<br/>Script URI must be prefixed by one of '<em>galette://</em>' for Galette internal call. '<em>file://</em>' for a direct file call, '<em>get://</em>' or '<em>post://</em>' for HTTP calls (prefix will be replaced by http:// in those cases).") }}"></i>
231 <input type="text" name="pref_new_contrib_script" id="pref_new_contrib_script" value="{{ pref.pref_new_contrib_script }}"/>
235 <label for="pref_rss_url" class="tooltip">{{ _T("RSS feed URL") }}</label>
236 <div class="ui right corner labeled input">
237 <div class="ui corner label">
238 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Enter the full URL to the RSS feed. It will be displayed on Galette desktop.") }}"></i>
240 <input type="text" name="pref_rss_url" id="pref_rss_url" value="{{ pref.pref_rss_url }}"{% if required.pref_rss_url is defined and required.pref_rss_url == 1 %} required="required"{% endif %}/>
244 <label for="pref_galette_url" class="tooltip">{{ _T("Galette base URL") }}</label>
245 <div class="ui right corner labeled input">
246 <div class="ui corner label">
247 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Enter the base URL to your Galette instance. You should only change this parameter if the current page URL is not:<br/>%galette_url")|replace({ "%galette_url": preferences.getDefaultURL() ~ path_for('preferences') }) }}"></i>
249 <input type="text" name="pref_galette_url" id="pref_galette_url" placeholder="{{ preferences.getDefaultURL() }}" value="{{ pref.pref_galette_url }}"{% if required.pref_galette_url is defined and required.pref_galette_url == 1 %} required="required"{% endif %}/>
252 <div class="field inline">
253 <label for="pref_show_id" class="tooltip">{{ _T("Show identifiers") }}</label>
254 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Display database identifiers in related windows") }}"></i>
255 <input type="checkbox" name="pref_show_id" id="pref_show_id" value="1" {% if pref.pref_show_id %} checked="checked"{% endif %}/>
258 </div>{# /column grid #}
259 <div class="ui stackable two column grid">
262 <label for="pref_statut">{{ _T("Default membership status:") }}</label>
263 <select name="pref_statut" id="pref_statut" class="ui search dropdown nochosen">
264 {% for key, value in statuts %}
265 <option value="{{ key }}"{% if key == pref.pref_statut %} selected="selected"{% endif %}>{{ value }}</option>
270 <label for="pref_membership_ext">{{ _T("Default membership extension:") }}</label>
271 <div class="ui right labeled input">
272 <input type="text" name="pref_membership_ext" id="pref_membership_ext" value="{{ pref.pref_membership_ext }}" maxlength="2"{% if required.pref_membership_ext is defined and required.pref_membership_ext == 1 %} required="required"{% endif %}/>
273 <div class="ui basic label">
281 <label for="pref_beg_membership">{{ _T("Beginning of membership:") }}</label>
282 <input type="text" name="pref_beg_membership" id="pref_beg_membership" value="{{ pref.pref_beg_membership }}" maxlength="5"{% if required.pref_beg_membership is defined and required.pref_beg_membership == 1 %} required="required"{% endif %}/>
283 <span class="exemple">{{ _T("(dd/mm)") }}</span>
286 <label for="pref_membership_offermonths">{{ _T("Number of months offered:") }}</label>
287 <div class="ui right corner labeled input">
288 <div class="ui corner label">
289 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("When using the beginning of membership option; you can offer the last months of the year.") }}<br/>{{ _T("Let's say you offer last 2 months, and have a renewal on 31th of December. All created contributions in current year will be valid until this date, but as of October, they will be valid for the entire next year.") }}"></i>
291 <input type="number" name="pref_membership_offermonths" min="0" id="pref_membership_offermonths" value="{{ pref.pref_membership_offermonths }}" maxlength="5"{% if required.pref_membership_offermonths is defined and required.pref_membership_offermonths == 1 %} required="required"{% endif %}/>
295 </div>{# /column grid #}
296 </div>{# /tab segment #}
297 <div class="ui tab segment" data-tab="rights">
298 <div class="ui stackable two column grid">
300 <div class="field inline">
301 <label for="pref_bool_create_member">{{ _T("Can members create child?") }}</label>
302 <input type="checkbox" name="pref_bool_create_member" id="pref_bool_create_member" value="1" {% if pref.pref_bool_create_member == 1 %}checked="checked"{% endif %}/>
304 <div class="field inline">
305 <label for="pref_bool_groupsmanagers_edit_groups">{{ _T("Can group managers edit their groups?") }}</label>
306 <input type="checkbox" name="pref_bool_groupsmanagers_edit_groups" id="pref_bool_groupsmanagers_edit_groups" value="1" {% if pref.pref_bool_groupsmanagers_edit_groups == 1 %}checked="checked"{% endif %}/>
308 <div class="field inline">
309 <label for="pref_bool_groupsmanagers_create_member">{{ _T("Can group managers create members?") }}</label>
310 <input type="checkbox" name="pref_bool_groupsmanagers_create_member" id="pref_bool_groupsmanagers_create_member" value="1" {% if pref.pref_bool_groupsmanagers_create_member == 1 %}checked="checked"{% endif %}/>
312 <div class="field inline">
313 <label for="pref_bool_groupsmanagers_edit_member">{{ _T("Can group managers edit members?") }}</label>
314 <input type="checkbox" name="pref_bool_groupsmanagers_edit_member" id="pref_bool_groupsmanagers_edit_member" value="1" {% if pref.pref_bool_groupsmanagers_edit_member == 1 %}checked="checked"{% endif %}/>
316 <div class="field inline">
317 <label for="pref_bool_groupsmanagers_mailings">{{ _T("Can group managers send mailings?") }}</label>
318 <input type="checkbox" name="pref_bool_groupsmanagers_mailings" id="pref_bool_groupsmanagers_mailings" value="1" {% if pref.pref_bool_groupsmanagers_mailings == 1 %}checked="checked"{% endif %}/>
320 <div class="field inline">
321 <label for="pref_bool_groupsmanagers_exports" class="tooltip">{{ _T("Can group managers do exports?") }}</label>
322 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Groups managers will be allowed to export members as csv, pdf cards, attendence sheetss and groups pdf") }}"></i>
323 <input type="checkbox" name="pref_bool_groupsmanagers_exports" id="pref_bool_groupsmanagers_exports" value="1" {% if pref.pref_bool_groupsmanagers_exports == 1 %}checked="checked"{% endif %}/>
327 </div>{# /tab segment #}
328 <div class="ui tab segment" data-tab="mail">
329 <div class="ui stackable two column grid">
331 {% if constant('GALETTE_MODE') == constant('\\Galette\\Core\\Galette::MODE_DEMO') %}
332 <div class="ui negative message">
333 <p>{{ _T("Application runs under demo mode. This functionnality is not enabled, sorry.") }}</p>
337 <label for="pref_email_nom">{{ _T("Sender name:") }}</label>
338 <input type="text" name="pref_email_nom" id="pref_email_nom" value="{{ pref.pref_email_nom }}" maxlength="50"{% if required.pref_email_nom is defined and required.pref_email_nom == 1 %} required="required"{% endif %}/>
340 <div class="{% if required.pref_email is defined and required.pref_email == 1 %}required {% endif %}field">
341 <label for="pref_email">{{ _T("Sender Email:") }}</label>
342 {% set pref_email = preferences.vpref_email|join(',') %}
343 <input type="text" name="pref_email" id="pref_email" value="{{ pref_email }}" maxlength="100" size="30"{% if required.pref_email is defined and required.pref_email == 1 %} required="required"{% endif %}/>
344 <span class="exemple">{{ _T("(You can enter several emails separated with a comma. First address will be the default one.)") }}</span>
347 <label for="pref_email_reply_to" class="tooltip">{{ _T("Reply-To Email:") }}</label>
348 <div class="ui right corner labeled input">
349 <div class="ui corner label">
350 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Leave empty to use Sender Email as reply address") }}"></i>
352 <input type="text" name="pref_email_reply_to" id="pref_email_reply_to" value="{{ pref.pref_email_reply_to }}" maxlength="100" size="30"{% if required.pref_email_reply_to is defined and required.pref_email_reply_to == 1 %} required="required"{% endif %}/>
356 {% set pref_email = preferences.vpref_email_newadh|join(',') %}
357 <label for="pref_email_newadh" class="tooltip">{{ _T("Members administrator's Email:") }}</label>
358 <div class="ui right corner labeled input">
359 <div class="ui corner label">
360 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Recipient of new online registation and edition emails") }}"></i>
362 <input type="text" name="pref_email_newadh" id="pref_email_newadh" value="{{ pref.pref_email_newadh }}" maxlength="100" size="30"{% if required.pref_email_newadh is defined and required.pref_email_newadh == 1 %} required="required"{% endif %}/>
364 <span class="exemple">{{ _T("(You can enter several emails separated with a comma. First address will be the default one.)") }}</span>
366 <div class="field inline">
367 <label for="pref_bool_mailadh" class="tooltip">{{ _T("Send email to administrators?") }}</label>
368 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Sends an email each time a new member registers online or edit his/her account") }}"></i>
369 <input type="checkbox" name="pref_bool_mailadh" id="pref_bool_mailadh" value="1" {% if pref.pref_bool_mailadh == 1 %}checked="checked"{% endif %}{% if required.pref_bool_mailadh is defined and required.pref_bool_mailadh == 1 %} required="required"{% endif %}/>
371 <div class="field inline">
372 <label for="pref_bool_wrap_mails" class="tooltip">{{ _T("Wrap emails text?") }}</label>
373 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Automatically wrap emails texts before sending. Make sure to wrap yourself if you disable that. Please note that current editing mailing will not be affected by a change.") }}"></i>
374 <input type="checkbox" name="pref_bool_wrap_mails" id="pref_bool_wrap_mails" value="1" {% if pref.pref_bool_wrap_mails == 1 %}checked="checked"{% endif %}{% if required.pref_bool_wrap_mails is defined and required.pref_bool_wrap_mails == 1 %} required="required"{% endif %}/>
376 <div class="field inline">
377 <label for="pref_bool_mailowner" class="tooltip">{{ _T("Send email to members?") }}</label>
378 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Sends an email each time a member card or a contribution has been added or edited. This can be disabled for each case.") }}"></i>
379 <input type="checkbox" name="pref_bool_mailowner" id="pref_bool_mailowner" value="1" {% if pref.pref_bool_mailowner == 1 %}checked="checked"{% endif %}{% if required.pref_bool_mailowner is defined and required.pref_bool_mailowner == 1 %} required="required"{% endif %}/>
381 <div class="field inline">
382 <label for="pref_editor_enabled" class="tooltip">{{ _T("Activate HTML editor?") }}</label>
383 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Should HTML editor be activated on page load ?") }}"></i>
384 <input type="checkbox" name="pref_editor_enabled" id="pref_editor_enabled" value="1" {% if pref.pref_editor_enabled == 1 %}checked="checked"{% endif %}{% if required.pref_editor_enabled is defined and required.pref_editor_enabled == 1 %} required="required"{% endif %}/>
388 <div class="grouped fields">
389 <label{% if required.pref_mail_method is defined and required.pref_mail_method == 1 %} required="required"{% endif %}>{{ _T("Emailing method:") }}</label>
391 <div class="ui radio checkbox">
392 <input type="radio" name="pref_mail_method" id="no" value=" {{ constant('Galette\\Core\\GaletteMail::METHOD_DISABLED') }}" {% if pref.pref_mail_method == constant('Galette\\Core\\GaletteMail::METHOD_DISABLED') %}checked="checked"{% endif %}/><label for="no">{{ _T("Emailing disabled") }}</label>
396 <div class="ui radio checkbox">
397 <input type="radio" name="pref_mail_method" id="php" value=" {{ constant('Galette\\Core\\GaletteMail::METHOD_PHPMAIL') }}" {% if pref.pref_mail_method == constant('Galette\\Core\\GaletteMail::METHOD_PHPMAIL') %}checked="checked"{% endif %}/><label for="php">{{ _T("PHP mail() function") }}</label>
401 <div class="ui radio checkbox">
402 <input type="radio" name="pref_mail_method" id="smtp" value=" {{ constant('Galette\\Core\\GaletteMail::METHOD_SMTP') }}" {% if pref.pref_mail_method == constant('Galette\\Core\\GaletteMail::METHOD_SMTP') %}checked="checked"{% endif %}/><label for="smtp">{{ _T("Using a SMTP server (slower)") }}</label>
406 <div class="ui radio checkbox">
407 <input type="radio" name="pref_mail_method" id="gmail" value=" {{ constant('Galette\\Core\\GaletteMail::METHOD_GMAIL') }}" {% if pref.pref_mail_method == constant('Galette\\Core\\GaletteMail::METHOD_GMAIL') %}checked="checked"{% endif %}/><label for="gmail">{{ _T("Using GMAIL as SMTP server (slower)") }}</label>
411 <div class="ui radio checkbox">
412 <input type="radio" name="pref_mail_method" id="sendmail" value=" {{ constant('Galette\\Core\\GaletteMail::METHOD_SENDMAIL') }}" {% if pref.pref_mail_method == constant('Galette\\Core\\GaletteMail::METHOD_SENDMAIL') %}checked="checked"{% endif %}/><label for="sendmail">{{ _T("Using Sendmail server") }}</label>
416 <div class="ui radio checkbox">
417 <input type="radio" name="pref_mail_method" id="qmail" value=" {{ constant('Galette\\Core\\GaletteMail::METHOD_QMAIL') }}" {% if pref.pref_mail_method == constant('Galette\\Core\\GaletteMail::METHOD_QMAIL') %}checked="checked"{% endif %}/><label for="qmail">{{ _T("Using QMAIL server") }}</label>
422 href="{{ path_for('testEmail') }}#mail"
424 class="ui labeled icon button"
426 <i class="rocket icon" aria-hidden="true"></i>
427 {{ _T("Test email settings") }}
430 <div id="smtp_parameters"{% if pref.pref_mail_method != constant('Galette\\Core\\GaletteMail::METHOD_SMTP') %} style="display: none;"{% endif %}>
432 <label for="pref_mail_smtp_host">{{ _T("SMTP server:") }}</label>
433 <input type="text" name="pref_mail_smtp_host" id="pref_mail_smtp_host" value="{{ pref.pref_mail_smtp_host }}" maxlength="100" size="30"{% if required.pref_mail_smtp_host is defined and required.pref_mail_smtp_host == 1 %} required="required"{% endif %}/>
436 <label for="pref_mail_smtp_port">{{ _T("SMTP port:") }}</label>
437 <input type="text" name="pref_mail_smtp_port" id="pref_mail_smtp_port" value="{{ pref.pref_mail_smtp_port }}" size="10"{% if required.pref_mail_smtp_port is defined and required.pref_mail_smtp_port == 1 %} required="required"{% endif %}/>
439 <div class="grouped fields">
440 <div class="field inline">
441 <label for="pref_mail_smtp_auth" class="tooltip">{{ _T("Use SMTP authentication?") }}</label>
442 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Would emailing use any SMTP authentication? You'll have to provide username and password below. For GMail, authentication will always be on.") }}"></i>
443 <input type="checkbox" name="pref_mail_smtp_auth" id="pref_mail_smtp_auth" value="1" {% if pref.pref_mail_smtp_auth == 1 %}checked="checked"{% endif %}{% if required.pref_mail_smtp_auth is defined and required.pref_mail_smtp_auth == 1 %} required="required"{% endif %}/>
445 <div class="field inline">
446 <label for="pref_mail_smtp_secure" class="tooltip">{{ _T("Use TLS for SMTP?") }}</label>
447 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Do you want to use server's TLS capabilities?<br/>For GMail, this will always be on.") }}"></i>
448 <input type="checkbox" name="pref_mail_smtp_secure" id="pref_mail_smtp_secure" value="1" {% if pref.pref_mail_smtp_secure == 1 %}checked="checked"{% endif %}{% if required.pref_mail_smtp_secure is defined and required.pref_mail_smtp_secure == 1 %} required="required"{% endif %}/>
450 <div class="field inline">
451 <label for="pref_mail_allow_unsecure" class="tooltip">{{ _T("Allow unsecure TLS?") }}</label>
452 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Do you want to allow 'unsecure' connections? This may be usefull if you server uses a self-signed certificate, and on some other cases.") }}"></i>
453 <input type="checkbox" name="pref_mail_allow_unsecure" id="pref_mail_allow_unsecure" value="1" {% if pref.pref_mail_allow_unsecure == 1 %}checked="checked"{% endif %}{% if required.pref_mail_allow_unsecure is defined and required.pref_mail_allow_unsecure == 1 %} required="required"{% endif %}/>
457 <div id="smtp_auth"{% if pref.pref_mail_method != constant('Galette\\Core\\GaletteMail::METHOD_SMTP') and pref.pref_mail_method != constant('Galette\\Core\\GaletteMail::METHOD_GMAIL') %} style="display: none;"{% endif %}>
459 <label for="pref_mail_smtp_user">{{ _T("SMTP (or GMail) user:") }}</label>
460 <input type="text" name="pref_mail_smtp_user" id="pref_mail_smtp_user" value="{{ pref.pref_mail_smtp_user }}" maxlength="100" size="30"{% if required.pref_mail_smtp_user is defined and required.pref_mail_smtp_user == 1 %} required="required"{% endif %}/>
463 <label for="pref_mail_smtp_password">{{ _T("SMTP (or GMail) password:") }}</label>
464 <input type="password" name="pref_mail_smtp_password" id="pref_mail_smtp_password" value="{{ pref.pref_mail_smtp_password }}" autocomplete="off" maxlength="100" size="30"{% if required.pref_mail_smtp_password is defined and required.pref_mail_smtp_password == 1 %} required="required"{% endif %}/>
467 <div class="field mail_sign">
468 <label for="pref_mail_sign" class="tooltip">{{ _T("Mail signature") }}</label>
469 <div class="ui right corner labeled input">
470 <div class="ui corner label" id="mail_sign">
472 <textarea name="pref_mail_sign" id="pref_mail_sign" rows="5">{{ pref.pref_mail_sign }}</textarea>
477 </div>{# /column grid #}
478 </div>{# /tab segment #}
479 <div class="ui tab segment" data-tab="labels">
480 <div class="ui two column grid">
483 <label for="pref_etiq_marges_v">{{ _T("Vertical margins:") }}</label>
484 <div class="ui right labeled input">
485 <input type="number" name="pref_etiq_marges_v" id="pref_etiq_marges_v" value="{{ pref.pref_etiq_marges_v }}" maxlength="4"{% if required.pref_etiq_marges_v is defined and required.pref_etiq_marges_v == 1 %} required="required"{% endif %}/>
486 <div class="ui basic label">mm</div>
490 <label for="pref_etiq_marges_h">{{ _T("Horizontal margins:") }}</label>
491 <div class="ui right labeled input">
492 <input type="number" name="pref_etiq_marges_h" id="pref_etiq_marges_h" value="{{ pref.pref_etiq_marges_h }}" maxlength="4"{% if required.pref_etiq_marges_h is defined and required.pref_etiq_marges_h == 1 %} required="required"{% endif %}/>
493 <div class="ui basic label">mm</div>
497 <label for="pref_etiq_hspace">{{ _T("Horizontal spacing:") }}</label>
498 <div class="ui right labeled input">
499 <input type="number" name="pref_etiq_hspace" id="pref_etiq_hspace" value="{{ pref.pref_etiq_hspace }}" maxlength="4"{% if required.pref_etiq_hspace is defined and required.pref_etiq_hspace == 1 %} required="required"{% endif %}/>
500 <div class="ui basic label">mm</div>
504 <label for="pref_etiq_vspace">{{ _T("Vertical spacing:") }}</label>
505 <div class="ui right labeled input">
506 <input type="number" name="pref_etiq_vspace" id="pref_etiq_vspace" value="{{ pref.pref_etiq_vspace }}" maxlength="4"{% if required.pref_etiq_vspace is defined and required.pref_etiq_vspace == 1 %} required="required"{% endif %}/>
507 <div class="ui basic label">mm</div>
510 <div class="field inline">
511 <label for="pref_etiq_border" class="tooltip">{{ _T("Print border") }}</label>
512 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Check this box to print a grey border around each label.") }}"></i>
513 <input type="checkbox" name="pref_etiq_border" id="pref_etiq_border" value="1" {% if pref.pref_etiq_border == 1 %}checked="checked"{% endif %}/>
518 <label for="pref_etiq_hsize">{{ _T("Label width:") }}</label>
519 <div class="ui right labeled input">
520 <input type="number" name="pref_etiq_hsize" id="pref_etiq_hsize" value="{{ pref.pref_etiq_hsize }}" maxlength="4"{% if required.pref_etiq_hsize is defined and required.pref_etiq_hsize == 1 %} required="required"{% endif %}/>
521 <div class="ui basic label">mm</div>
525 <label for="pref_etiq_vsize">{{ _T("Label height:") }}</label>
526 <div class="ui right labeled input">
527 <input type="number" name="pref_etiq_vsize" id="pref_etiq_vsize" value="{{ pref.pref_etiq_vsize }}" maxlength="4"{% if required.pref_etiq_vsize is defined and required.pref_etiq_vsize == 1 %} required="required"{% endif %}/>
528 <div class="ui basic label">mm</div>
532 <label for="pref_etiq_cols">{{ _T("Number of label columns:") }}</label>
533 <input type="number" name="pref_etiq_cols" id="pref_etiq_cols" value="{{ pref.pref_etiq_cols }}" maxlength="4"{% if required.pref_etiq_cols is defined and required.pref_etiq_cols == 1 %} required="required"{% endif %}/>
536 <label for="pref_etiq_rows">{{ _T("Number of label lines:") }}</label>
537 <input type="number" name="pref_etiq_rows" id="pref_etiq_rows" value="{{ pref.pref_etiq_rows }}" maxlength="4"{% if required.pref_etiq_rows is defined and required.pref_etiq_rows == 1 %} required="required"{% endif %}/>
540 <label for="pref_etiq_corps">{{ _T("Font size:") }}</label>
541 <input type="number" name="pref_etiq_corps" id="pref_etiq_corps" value="{{ pref.pref_etiq_corps }}" maxlength="4"{% if required.pref_etiq_corps is defined and required.pref_etiq_corps == 1 %} required="required"{% endif %}/>
544 </div>{# /column grid #}
545 </div>{# /tab segment #}
546 <div class="ui tab segment" data-tab="cards">
547 <div class="ui message">
548 <p>{{ _T("Each card is 75mm width and 40mm height. Each page contains 2 columns and 6 rows.<br/>Double check margins and spacings ;)") }}</p>
550 <div class="ui two column grid">
553 <label for="pref_card_abrev">{{ _T("Short Text (Card Center):") }}</label>
554 <div class="ui action input">
555 <input type="text" name="pref_card_abrev" id="pref_card_abrev" value="{{ pref.pref_card_abrev }}" size="10" maxlength="10"{% if required.pref_card_abrev is defined and required.pref_card_abrev == 1 %} required="required"{% endif %}/>
557 href="{{ path_for("dynamicTranslations", { "text_orig": pref.pref_card_abrev|escape }) }}"
558 class="ui icon button tooltip"
559 data-html="{{ _T("Translate '%s'")|replace({ "%s": pref.pref_card_abrev}) }}"
561 <i class="language icon"></i>
564 <span class="exemple">{{ _T("(10 characters max)") }}</span>
567 <label for="pref_card_strip">{{ _T("Long Text (Bottom Line):") }}</label>
568 <div class="ui action input">
569 <input type="text" name="pref_card_strip" id="pref_card_strip" value="{{ pref.pref_card_strip }}" size="40" maxlength="65"{% if required.pref_card_strip is defined and required.pref_card_strip == 1 %} required="required"{% endif %}/>
571 href="{{ path_for("dynamicTranslations", { "text_orig": pref.pref_card_strip|escape }) }}"
572 class="ui icon button tooltip"
573 data-html="{{ _T("Translate '%s'")|replace({ "%s": pref.pref_card_strip}) }}"
575 <i class="language icon"></i>
578 <span class="exemple">{{ _T("(65 characters max)") }}</span>
580 <div class="grouped fields">
582 <label for="pref_card_tcol" class="tooltip">{{ _T("Strip Text Color:") }}</label>
583 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Hexadecimal color notation: #RRGGBB") }}"></i>
584 <input type="color" name="pref_card_tcol" id="pref_card_tcol" value="{{ pref.pref_card_tcol }}" size="7" maxlength="7"{% if required.pref_card_tcol is defined and required.pref_card_tcol == 1 %} required="required"{% endif %}/>
587 <label for="pref_card_scol" class="tooltip">{{ _T("Active Member Color:") }}</label>
588 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Hexadecimal color notation: #RRGGBB") }}"></i>
589 <input type="color" name="pref_card_scol" id="pref_card_scol" value="{{ pref.pref_card_scol }}" size="7" maxlength="7"{% if required.pref_card_scol is defined and required.pref_card_scol == 1 %} required="required"{% endif %}/>
592 <label for="pref_card_bcol" class="tooltip">{{ _T("Board Members Color:") }}</label>
593 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Hexadecimal color notation: #RRGGBB") }}"></i>
594 <input type="color" name="pref_card_bcol" id="pref_card_bcol" value="{{ pref.pref_card_bcol }}" size="7" maxlength="7"{% if required.pref_card_bcol is defined and required.pref_card_bcol == 1 %} required="required"{% endif %}/>
597 <label for="pref_card_hcol" class="tooltip">{{ _T("Honor Members Color:") }}</label>
598 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("Hexadecimal color notation: #RRGGBB") }}"></i>
599 <input type="color" name="pref_card_hcol" id="pref_card_hcol" value="{{ pref.pref_card_hcol }}" size="7" maxlength="7"{% if required.pref_card_hcol is defined and required.pref_card_hcol == 1 %} required="required"{% endif %}/>
601 </div>{# /group fields #}
603 <label for="card_logo"{% if required.card_logo is defined and required.card_logo == 1 %} required="required"{% endif %}>{{ _T("Logo:") }}</label>
604 {% if print_logo.isCustom() %}
605 <img src="{{ path_for('printLogo') }}" class="picture" width="{{ print_logo.getOptimalWidth() }}" height="{{ print_logo.getOptimalHeight() }}" alt="{{ _T("Current logo for printing") }}"/><br/>
606 <label for="del_card_logo">{{ _T("Delete image") }}</label><input type="checkbox" name="del_card_logo" id="del_card_logo" value="1" /><br />
608 <input type="file" name="card_logo" id="card_logo"{% if constant('GALETTE_MODE') == constant('Galette\\Core\\Galette::MODE_DEMO') %} disabled="disabled"{% endif %}/>
612 <div class="field inline">
613 <label for="pref_card_self">{{ _T("Allow members to print card ?") }}</label>
614 <input type="checkbox" name="pref_card_self" id="pref_card_self" value="1" {% if pref.pref_card_self == 1 %}checked="checked"{% endif %}{% if required.pref_bool_display_title is defined and required.pref_bool_display_title == 1 %} required="required"{% endif %}/>
616 <div class="field inline">
617 <label for="pref_bool_display_title" class="tooltip">{{ _T("Show title ?") }}</label>
618 <span class="tip">{{ _T("(Show or not title in front of name)") }}</span>
619 <input type="checkbox" name="pref_bool_display_title" id="pref_bool_display_title" value="1" {% if pref.pref_bool_display_title == 1 %}checked="checked"{% endif %}{% if required.pref_bool_display_title is defined and required.pref_bool_display_title == 1 %} required="required"{% endif %}/>
622 <label for="pref_card_address">{{ _T("Address type:") }}</label>
623 <select name="pref_card_address" id="pref_card_address" class="ui search dropdown nochosen">
624 <option value="0" {% if pref.pref_card_address == 0 %}selected="selected"{% endif %}>{{ _T("Email") }}</option>
625 <option value="5" {% if pref.pref_card_address == 5 %}selected="selected"{% endif %}>{{ _T("Zip - Town") }}</option>
626 <option value="6" {% if pref.pref_card_address == 6 %}selected="selected"{% endif %}>{{ _T("Nickname") }}</option>
627 <option value="7" {% if pref.pref_card_address == 7 %}selected="selected"{% endif %}>{{ _T("Profession") }}</option>
628 <option value="8" {% if pref.pref_card_address == 8 %}selected="selected"{% endif %}>{{ _T("Member nubmer") }}</option>
630 <span class="exemple">{{ _T("(Choose address printed below name)") }}</span>
633 <label for="pref_card_year">{{ _T("Year:") }}</label>
634 <div class="ui right corner labeled input">
635 <div class="ui corner label">
636 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("You can enter either:<br/>- a year,<br/>- two years with a slash as separator,<br/>- the string 'DEADLINE' to use member deadline") }}"></i>
638 <input type="text" name="pref_card_year" id="pref_card_year" value="{{ pref.pref_card_year }}" maxlength="9"{% if required.pref_card_year is defined and required.pref_card_year == 1 %} required="required"{% endif %}/>
642 <label for="pref_card_marges_v">{{ _T("Vertical margins:") }}</label>
643 <div class="ui right labeled input">
644 <input type="number" name="pref_card_marges_v" id="pref_card_marges_v" value="{{ pref.pref_card_marges_v }}" maxlength="4"{% if required.pref_card_marges_v is defined and required.pref_card_marges_v == 1 %} required="required"{% endif %}/>
645 <div class="ui basic label">mm</div>
649 <label for="pref_card_marges_h">{{ _T("Horizontal margins:") }}</label>
650 <div class="ui right labeled input">
651 <input type="number" name="pref_card_marges_h" id="pref_card_marges_h" value="{{ pref.pref_card_marges_h }}" maxlength="4"{% if required.pref_card_marges_h is defined and required.pref_card_marges_h == 1 %} required="required"{% endif %}/>
652 <div class="ui basic label">mm</div>
656 <label for="pref_card_vspace">{{ _T("Vertical spacing:") }}</label>
657 <div class="ui right labeled input">
658 <input type="number" name="pref_card_vspace" id="pref_card_vspace" value="{{ pref.pref_card_vspace }}" maxlength="4"{% if required.pref_card_vspace is defined and required.pref_card_vspace == 1 %} required="required"{% endif %}/>
659 <div class="ui basic label">mm</div>
663 <label for="pref_card_hspace">{{ _T("Horizontal spacing:") }}</label>
664 <div class="ui right labeled input">
665 <input type="number" name="pref_card_hspace" id="pref_card_hspace" value="{{ pref.pref_card_hspace }}" maxlength="4"{% if required.pref_card_hspace is defined and required.pref_card_hspace == 1 %} required="required"{% endif %}/>
666 <div class="ui basic label">mm</div>
670 </div>{# /column grid #}
671 </div>{# /tab segment #}
673 {% if login.isAdmin() %}
674 <div class="ui tab segment" data-tab="security">
676 <label for="pref_password_length" title="{{ _T("Minimum password length required for all accounts. Minimal size is 6.") }}">{{ _T("Password length:") }}</label>
677 <div class="ui right corner labeled input">
678 <div class="ui corner label">
679 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Minimum password length required for all accounts. Minimal size is 6.") }}"></i>
681 <input type="number" name="pref_password_length" id="pref_password_length" value="{{ pref.pref_password_length }}" min="6" size="7" required="required"/>
684 <div class="field inline">
685 <label for="pref_password_blacklist" title="{{ _T("Enable password blacklists") }}">{{ _T("Enable blacklists:") }}</label>
686 <i class="circular small inverted primary link icon info tooltip" data-html="{{ _T("If you enable blacklists; it will not be possible to use any of blacklisted passwords. A list is provided along with Galette, but you can add you owns.") }}"></i>
687 <input type="checkbox" name="pref_password_blacklist" id="pref_password_blacklist" value="1"{% if pref.pref_password_blacklist == 1 %} checked="checked"{% endif %}/>
690 <label for="pref_password_strength" title="{{ _T("Enforce password strength") }}">{{ _T("Password strength:") }}</label>
691 <div class="ui right corner labeled input">
692 <div class="ui corner label">
693 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Enforce minimal password strength for all password.") }}<br/><br/>
694 {{ _T("Levels are:") }}<br/>
695 <em>* {{ _T("None") }}</em> {{ _T("for no strength enforcement") }}<br/>
696 <em>* {{ _T("Weak") }}</em> {{ _T("require at least one matched rule") }}<br/>
697 <em>* {{ _T("Medium") }}</em> {{ _T("require at least two matched rules") }}<br/>
698 <em>* {{ _T("Strong") }}</em> {{ _T("require at least three matched rules (recommended for most usages)") }}<br/>
699 <em>* {{ _T("Very Strong") }}</em> {{ _T("requires all rules.") }}<br/><br/>
700 {{ _T("Rules include lower case characters, upper case characters, numbers, and special characters.") }}<br/><br/>
701 {{ _T("Note that with any enforcement level, user cannot use his personal information (name, login, ...) as password.") }}"></i>
703 <select name="pref_password_strength" id="pref_password_strength" class="ui fluid dropdown nochosen">
704 <option value=" {{ constant('Galette\\Core\\Preferences::PWD_NONE') }}}"{% if pref.pref_password_strength == constant('Galette\\Core\\Preferences::PWD_NONE') %} selected="selected"{% endif %}>{{ _T("None (default)") }}</option>
705 <option value=" {{ constant('Galette\\Core\\Preferences::PWD_WEAK') }}}"{% if pref.pref_password_strength == constant('Galette\\Core\\Preferences::PWD_WEAK') %} selected="selected"{% endif %}>{{ _T("Weak") }}</option>
706 <option value=" {{ constant('Galette\\Core\\Preferences::PWD_MEDIUM') }}}"{% if pref.pref_password_strength == constant('Galette\\Core\\Preferences::PWD_MEDIUM') %} selected="selected"{% endif %}>{{ _T("Medium") }}</option>
707 <option value=" {{ constant('Galette\\Core\\Preferences::PWD_STRONG') }}}"{% if pref.pref_password_strength == constant('Galette\\Core\\Preferences::PWD_STRONG') %} selected="selected"{% endif %}>{{ _T("Strong") }}</option>
708 <option value=" {{ constant('Galette\\Core\\Preferences::PWD_VERY_STRONG') }}}"{% if pref.pref_password_strength == constant('Galette\\Core\\Preferences::PWD_VERY_STRONG') %} selected="selected"{% endif %}>{{ _T("Very strong") }}</option>
713 <label for="test_password_strength"" title="{{ _T("Test a password with current selected values.") }}">{{ _T("Test a password:") }}</label>
714 <div class="ui right corner labeled input">
715 <div class="ui corner label">
716 <i class="circular inverted primary link icon info tooltip" data-html="{{ _T("Test a password with current selected values.") }}<br/>{{ _T("Do not forget to save your preferences if you're happy with the result ;)") }}"></i>
718 <input type="text" id="test_password_strength"/>
722 </div>{# /tab segment #}
724 {% if login.isSuperAdmin() %}
725 <div class="ui tab red inverted segment" data-tab="admin">
726 {% if constant('GALETTE_MODE') == constant('\\Galette\\Core\\Galette::MODE_DEMO') %}
727 <div class="ui negative message">
728 {{ _T("Application runs under demo mode. This functionnality is not enabled, sorry.") }}
732 <label for="pref_admin_login">{{ _T("Username:") }}</label>
733 <input type="text" name="pref_admin_login" id="pref_admin_login" value="{{ pref.pref_admin_login }}" maxlength="20"{% if required.pref_admin_login is defined and required.pref_admin_login == 1 %} required="required"{% endif %}/>
736 <label for="pref_admin_pass">{{ _T("Password:") }}</label>
737 <input type="password" name="pref_admin_pass" id="pref_admin_pass" value="" maxlength="20" autocomplete="off"{% if required.pref_admin_pass is defined and required.pref_admin_pass == 1 %} required="required"{% endif %}/>
740 <label for="pref_admin_pass_check">{{ _T("Retype password:") }}</label>
741 <input type="password" name="pref_admin_pass_check" id="pref_admin_pass_check" value="" maxlength="20"{% if required.pref_admin_pass_check is defined and required.pref_admin_pass_check == 1 %} required="required"{% endif %}/>
744 </div>{# /tab segment #}
746 <div class="button-container">
747 <input type="hidden" name="valid" value="1"/>
748 <input type="hidden" name="pref_theme" value="default"/>
749 <input type="hidden" name="pref_telemetry_date" value="{{ pref.pref_telemetry_date }}"/>
750 <input type="hidden" name="pref_instance_uuid" value="{{ pref.pref_instance_uuid }}"/>
751 <input type="hidden" name="pref_registration_date" value="{{ pref.pref_registration_date }}"/>
752 <input type="hidden" name="pref_registration_uuid" value="{{ pref.pref_registration_uuid }}"/>
753 <button type="submit" class="ui labeled icon button action">
754 <i class="save icon"></i> {{ _T("Save") }}
757 {% include "components/forms/csrf.html.twig" %}
760 {% include "modals/telemetry.html.twig" with { part: "dialog" } %}
761 {% include "modals/replacements_legend.html.twig" with { legends: preferences.getLegend(), cur_ref: 'prefs' } %}
764 {% block javascripts %}
765 <script type="text/javascript">
767 $('#no,#php,#qmail').click(function(){
768 $('#smtp_parameters,#smtp_auth').hide();
770 $('#smtp,#gmail').click(function(){
771 $('#smtp_parameters,#smtp_auth').show();
773 $('#gmail').click(function(){
774 $('#smtp_parameters').hide();
775 $('#smtp_auth').show();
778 $('#smtp,#gmail').checkbox({
779 onChange: function() {
780 $('#smtp_parameters,#smtp_auth').show();
785 $('#pref_bool_publicpages').change(function(){
786 $('#publicpages_visibility').toggleClass('hidden');
789 $('#btnmail').on('click', function(e) {
792 var _value = $('#pref_email_newadh').val();
793 var _input = '<div class="ui input"><input type="text" name="email_adress" id="email_adress" value="' + _value + '"/></div>';
795 title: '{{ _T("Enter the email adress")|e('js') }}',
799 text : '{{ _T("Send")|e('js') }}',
800 class : 'green approve',
804 url: _this.attr('href'),
807 adress: $('#email_adress').val()
809 {% include "elements/js/loader.js.twig" %},
810 success: function(res) {
813 url: '{{ path_for('ajaxMessages') }}',
815 success: function (message) {
816 $('#testEmail').prepend(message);
821 alert('{{ _T("An error occurred sending test email :(")|e('js') }}');
826 text : '{{ _T("Cancel")|e('js') }}',
832 _addLegenButton('#mail_sign');
835 {% include "elements/js/pwdcheck.js.twig" with { selector: "#pref_admin_pass" } %}
836 {% include "elements/js/pwdcheck.js.twig" with {
837 selector: "#test_password_strength",
838 extra_data: "pref_password_length: \$('#pref_password_length').val(),pref_password_blacklist: \$('#pref_password_blacklist').is(':checked'),pref_password_strength: \$('#pref_password_strength').val(),"
842 {% include "modals/telemetry.html.twig" with { part: "jsdialog"} %}
843 {% include "modals/telemetry.html.twig" with { part: "jsregister"} %}