{# -*- coding: utf-8 -*- This file is part of Invenio. Copyright (C) 2023 Graz University of Technology. Copyright (C) 2025 TU Wien. Invenio-Config-TUW is free software; you can redistribute it and/or modify it under the terms of the MIT License; see LICENSE file for more details. #} {#- base: invenio_users_resources v5.2.0 -#} {#- file: invenio_users_resources/templates/semantic-ui/invenio_users_resources/settings/notifications.html -#} {#- changes: rewording & mild restructuring, adding input for secondary email; see "change:" comments in the code #} {%- extends config.USERPROFILES_SETTINGS_TEMPLATE %} {% from "invenio_userprofiles/settings/_macros.html" import render_field, form_errors %} {%- block settings_content scoped %}

{{ _("Notifications") }}

{%- set form = notifications_form %} {%- for field in form %} {%- if field.widget.input_type == 'hidden' %} {{ field() }} {%- endif %} {%- endfor %} {#- change: create vars for other fields -#} {%- set enabled_field = form.enabled %} {%- set secondary_email_field = form.secondary_email %} {%- set notif_enabled = current_user.preferences.get("notifications", {}).get("enabled", True) %}
{#- change: add contextual text, and restructure input #}

Note that this setting only affects automatic notifications. Contact requests will still be sent to both primary and secondary email address, regardless of this setting.

{#- change: remove use of url_for() #}

{#- change: remove mention of changing email address #} {% trans %} We use your primary email address for sending notifications. {% endtrans %}

{{ current_user.email }}
{#- change: add input for secondary email address #}

{{ secondary_email_field.description }}

{{ form.id }}
{{ _('Cancel') }}
{% endblock settings_content%}