forked from Github-Mirrors/canaille
51 lines
2.1 KiB
HTML
51 lines
2.1 KiB
HTML
{#
|
|
The error page. Displayed for all kinds of errors (not found, internal server error etc.).
|
|
|
|
:param error_code: The code of the HTTP error (404, 500, etc.)
|
|
:type error_code: :class:`int`
|
|
:param description: The error code description.
|
|
:type description: :class:`str`
|
|
:param icon: An optional Font Awesome icon reference.
|
|
:type icon: :class:`str`
|
|
#}
|
|
{% extends theme('base.html') %}
|
|
|
|
{% block content %}
|
|
<div class="ui error icon message">
|
|
{% if icon is defined and (debug or (user and user.can_manage_oidc)) %}
|
|
<i class="{{ icon }} icon"></i>
|
|
{% elif error_code == 400 %}
|
|
<i class="question icon"></i>
|
|
{% elif error_code == 403 %}
|
|
<i class="hand paper icon"></i>
|
|
{% elif error_code == 404 %}
|
|
<i class="compass icon"></i>
|
|
{% elif error_code == 500 %}
|
|
<i class="bug icon"></i>
|
|
{% endif %}
|
|
<div class="content">
|
|
<div class="header">
|
|
{% if error_code == 400 %}
|
|
{% trans %}Bad request{% endtrans %}
|
|
{% elif error_code == 403 %}
|
|
{% trans %}Unauthorized{% endtrans %}
|
|
{% elif error_code == 404 %}
|
|
{% trans %}Page not found{% endtrans %}
|
|
{% elif error_code == 500 %}
|
|
{% trans %}Technical problem{% endtrans %}
|
|
{% endif %}
|
|
</div>
|
|
{% if description and (debug or (user and user.can_manage_oidc)) %}
|
|
<p>{{ description }}</p>
|
|
{% elif error_code == 400 %}
|
|
<p>{% trans %}The request you made is invalid{% endtrans %}</p>
|
|
{% elif error_code == 403 %}
|
|
<p>{% trans %}You do not have the authorizations to access this page{% endtrans %}</p>
|
|
{% elif error_code == 404 %}
|
|
<p>{% trans %}The page you are looking for does not exist{% endtrans %}</p>
|
|
{% elif error_code == 500 %}
|
|
<p>{% trans %}Please contact your administrator{% endtrans %}</p>
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|