{% extends "docbow/base_user.html" %} {% load i18n %} {% block title %} {% trans "Profile" %} {% endblock %} {% block extra_scripts %} {{ profile_form.media.css }} {{ delegate_form.media.css }} {% endblock %} {% block main-column %}

{% trans "profile_menu" %}

{% if profile_form %}

Notifications

{% csrf_token %} {% include "docbow/errors.html" with error_form=profile_form %} {% if profile_form.accept_notifications %} {% include "docbow/field.html" with field=profile_form.accept_notifications %} {% endif %} {% if profile_form.personal_email %} {% include "docbow/field.html" with field=profile_form.personal_email %} {% endif %} {% if profile_form.mobile_phone %}

{{ mobile_phone_paragraph }}

{% include "docbow/field.html" with field=profile_form.mobile_phone %} {% endif %}
{% endif %} {% if delegate_form %}

{% trans "Delegations" %}

Délégations attribuées

{% if delegations %}
{% csrf_token %} {% for delegation in delegations %} {% if delegation.journals %} {% else %} {% if delegation.to.date_joined != delegation.to.last_login %} {% else %} {% endif %} {% endif %} {% endfor %}
Prénom Nom Courriel Identifiant
{{ delegation.to.first_name }} {{ delegation.to.last_name }} {{ delegation.to.email }} {{ delegation.to.username }}
Dernière(s) connexion(s): {% for connection_time in delegation.journals %} {{ connection_time }} {% if not forloop.last %}, {% endif %} {% endfor %}Dernière connexion: {{ delegation.to.last_login }}Aucune connexion.
{% else %}

Aucune délégation attribuée

{% endif %} {% if delegate_form %}

{% trans "Create a new delegation" %}

{% csrf_token %} {% include "docbow/errors.html" with error_form=delegate_form %}

{% trans "You can delegate to a newly created user, then all following fields are mandatory:" %}

{% include "docbow/field.html" with field=delegate_form.first_name %} {% include "docbow/field.html" with field=delegate_form.last_name %} {% include "docbow/field.html" with field=delegate_form.email %} {% if delegate_to_existing_user %}

{% trans "or you can delegate to an existing user:" %}

{% include "docbow/field.html" with field=delegate_form.existing_user %} {% endif %}
{% endif %}

{% trans "Received delegations" %}

{% if received_delegations %} {% else %}

Aucune délégation reçue

{% endif %} {% endif %} {% if password_change_form %}

{% trans "Changing password" %}

{% csrf_token %} {% include "docbow/errors.html" with error_form=password_change_form %} {% include "docbow/field.html" with field=password_change_form.new_password1 %} {% include "docbow/field.html" with field=password_change_form.new_password2 %} {% include "docbow/field.html" with field=password_change_form.old_password %}
{% endif %}
{% include "docbow/notifications.html" with form=notifications_form %}
{% if email_form %}

{% trans "Changing email" %}

{% csrf_token %} {% include "docbow/field.html" with field=email_form.old_email %} {% include "docbow/field.html" with field=email_form.password %} {% include "docbow/field.html" with field=email_form.email %} {% include "docbow/field.html" with field=email_form.email2 %}
{% endif %} {% endblock main-column %} {% block endscripts %} {{ profile_form.media.js }} {{ delegate_form.media.js }} {{ notifications_form.media.js }} {% endblock endscripts %}