{# .. screenshot:: |canaille|/consent :context: user :align: right :width: 275px The consented applications list. The consented applications list. Display a list of clients for which users have given or revoked their consent. :param scope_details: Description of the OIDC scopes. :type scope_details: :class:`dict` :param ignored_scopes: The scopes to hide. :type ignored_scopes: :class:`list` :param nb_consents: The number of consents. :type nb_consents: :class:`int` :param nb_preconsents: The number of preconsented clients. :type nb_preconsents: :class:`int` #} {% extends theme('base.html') %} {%- block title -%} {%- trans %}My consents{% endtrans -%} {%- endblock -%} {% block submenu %} {% trans %}My consents{% endtrans %} {% if nb_consents %}
{{ nb_consents|numberformat }}
{% endif %}
{% trans %}Pre-authorized applications{% endtrans %} {% if nb_preconsents %}
{{ nb_preconsents|numberformat }}
{% endif %}
{% endblock %} {% block content %}

{{ _("My consents") }}
{% trans %}Consult and revoke the authorization you gave to websites.{% endtrans %}

{% if consents %}
{% for consent in consents %}
{% if consent.client.logo_uri %} {% endif %} {% if consent.client.client_uri %} {{ consent.client.client_name }} {% else %}
{{ consent.client.client_name }}
{% endif %} {% if consent.issue_date %}
{% trans %}From:{% endtrans %} {{ consent.issue_date.strftime("%d/%m/%Y %H:%M:%S") }}
{% endif %} {% if consent.revokation_date %}
{% trans %}Revoked:{% endtrans %} {{ consent.revokation_date.strftime("%d/%m/%Y %H:%M:%S") }}
{% endif %}

{% if consent.revokation_date %} {% trans %}Had access to:{% endtrans %} {% else %} {% trans %}Has access to:{% endtrans %} {% endif %}

{% for scope in consent.scope %} {% if scope not in ignored_scopes %} {% if scope not in scope_details %}
{{ scope }}
{% else %}
{{ scope_details[scope][1] }}
{% endif %} {% endif %} {% endfor %}
{% if consent.client.policy_uri %} {% endif %} {% if consent.client.tos_uri %} {% endif %} {% if consent.revokation_date %} {% trans %}Restore access{% endtrans %} {% else %} {% trans %}Revoke access{% endtrans %} {% endif %}
{% endfor %}
{% else %}

{% trans %}You did not authorize applications yet.{% endtrans %}

{% endif %}
{% endblock %}