{% extends 'users/base.html' %} {% from '_switch.html' import switch %} {% from 'api/_messages.html' import get_enable_persistent_msg, get_disable_persistent_msg %} {% block user_content %}
{%- trans -%} You do not have an API key at the moment. If you would like to use our API, please create an API key using the button below. {%- endtrans -%}
{% else %}{% trans %}This is the list of old keys associated with this user.{% endtrans %}
{% if old_keys %}{{ old_key.token }}
{%- if not old_key.use_count -%}
{%- trans %}never used{% endtrans -%}
{%- else -%}
{%- trans n = old_key.use_count -%}
used once
{%- pluralize -%}
used {{ n }} times
{%- endtrans -%}
{%- if old_key.last_used_dt -%}
, {% trans date=old_key.last_used_dt|format_datetime('short')|ensure_unicode -%}
last used on {{ date }}
{%- endtrans %}
{%- endif -%}
{%- endif -%}
{% trans %}There are no old keys.{% endtrans %}
{% endif %}