2020-12-05 06:24:27 +01:00
|
|
|
{% extends "users/settings_base.html" %}
|
|
|
|
|
|
|
|
{% block title %}
|
|
|
|
{{ _("Email and Notifications | %(username)s", username=user.username) }}
|
|
|
|
{% endblock %}
|
|
|
|
|
|
|
|
{% block pane %}
|
|
|
|
<h2 class="mt-0">{{ _("Email and Notifications") }}</h2>
|
|
|
|
|
|
|
|
{% from "macros/forms.html" import render_field, render_submit_field, render_checkbox_field %}
|
|
|
|
<form action="" method="POST" class="form" role="form">
|
|
|
|
{{ form.hidden_tag() }}
|
|
|
|
|
2020-12-05 19:39:50 +01:00
|
|
|
<h3>Email Address</h3>
|
|
|
|
|
|
|
|
{{ render_field(form.email, tabindex=100) }}
|
|
|
|
|
|
|
|
<p>
|
2021-01-24 14:25:17 +01:00
|
|
|
{{ _("Your email is needed to recover your account if you forget your password, and to send (configurable) notifications.") }}
|
|
|
|
{{ _("Your email will never be shared with a third-party.") }}
|
2020-12-05 19:39:50 +01:00
|
|
|
</p>
|
|
|
|
|
2021-01-24 14:25:17 +01:00
|
|
|
{% if user.email_verifications.filter_by(is_password_reset=False).count() > 0 %}
|
|
|
|
<p>
|
|
|
|
<i>{{ _("There is at least one verification pending.") }}</i>
|
|
|
|
</p>
|
|
|
|
{% endif %}
|
2020-12-05 19:39:50 +01:00
|
|
|
|
|
|
|
<h3>Notification Settings</h3>
|
|
|
|
|
|
|
|
{% if is_new %}
|
|
|
|
<p class="alert alert-info">
|
2020-12-05 22:59:02 +01:00
|
|
|
{{ _("Email notifications are currently turned off. Click 'save' to enable.") }}
|
2020-12-05 19:39:50 +01:00
|
|
|
</p>
|
|
|
|
{% endif %}
|
|
|
|
|
2020-12-05 22:59:02 +01:00
|
|
|
<p>
|
|
|
|
Configure whether certain types of notifications are sent immediately, or as part of a daily digest. <br>
|
|
|
|
</p>
|
|
|
|
|
2020-12-05 06:24:27 +01:00
|
|
|
<table class="table">
|
|
|
|
<tr>
|
|
|
|
<th>Event</th>
|
|
|
|
<th>Description</th>
|
2020-12-05 22:59:02 +01:00
|
|
|
<td>Immediately</td>
|
|
|
|
<td>In digest</td>
|
2020-12-05 06:24:27 +01:00
|
|
|
</tr>
|
|
|
|
{% for type in types %}
|
|
|
|
<tr>
|
|
|
|
<td>{{ type.getTitle() }}</td>
|
|
|
|
<td>{{ type.get_description() }}</td>
|
2020-12-05 22:59:02 +01:00
|
|
|
<td style="text-align: center;">
|
|
|
|
{{ render_checkbox_field(form["pref_" + type.toName()]) }}
|
|
|
|
</td>
|
|
|
|
<td style="text-align: center;">
|
|
|
|
{{ render_checkbox_field(form["pref_" + type.toName() + "_digest"]) }}
|
|
|
|
</td>
|
2020-12-05 06:24:27 +01:00
|
|
|
</tr>
|
|
|
|
{% endfor %}
|
|
|
|
</table>
|
|
|
|
|
2020-12-05 19:39:50 +01:00
|
|
|
<p class="mt-5">
|
|
|
|
{{ render_submit_field(form.submit, tabindex=280) }}
|
|
|
|
</p>
|
2020-12-05 06:24:27 +01:00
|
|
|
</form>
|
|
|
|
{% endblock %}
|