mirror of
https://github.com/ansible/awx.git
synced 2026-04-09 12:09:20 -02:30
Added error handling views and templates, added setting to log request errors to a file.
This commit is contained in:
4
ansibleworks/templates/403.html
Normal file
4
ansibleworks/templates/403.html
Normal file
@@ -0,0 +1,4 @@
|
||||
{% extends "admin/403.html" %}
|
||||
|
||||
{% block breadcrumbs %}
|
||||
{% endblock %}
|
||||
4
ansibleworks/templates/404.html
Normal file
4
ansibleworks/templates/404.html
Normal file
@@ -0,0 +1,4 @@
|
||||
{% extends "admin/404.html" %}
|
||||
|
||||
{% block breadcrumbs %}
|
||||
{% endblock %}
|
||||
4
ansibleworks/templates/500.html
Normal file
4
ansibleworks/templates/500.html
Normal file
@@ -0,0 +1,4 @@
|
||||
{% extends "admin/500.html" %}
|
||||
|
||||
{% block breadcrumbs %}
|
||||
{% endblock %}
|
||||
20
ansibleworks/templates/admin/403.html
Normal file
20
ansibleworks/templates/admin/403.html
Normal file
@@ -0,0 +1,20 @@
|
||||
{% extends "admin/base_site.html" %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block title %}{% trans "Forbidden" %}{% endblock %}
|
||||
|
||||
{% block nav-global %}{% endblock %}
|
||||
|
||||
{% block content_title %}{% endblock %}
|
||||
|
||||
{% block breadcrumbs %}
|
||||
<div class="breadcrumbs">
|
||||
<a href="{% url "admin:index" %}">{% trans "Home" %}</a> ›
|
||||
{% trans "Forbidden" %}
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h1 style="margin-bottom: 0.7em;">{% trans 'Forbidden' %}</h1>
|
||||
<p>{% trans "You don't have permission to access the requested page." %}</p>
|
||||
{% endblock %}
|
||||
18
ansibleworks/templates/admin/404.html
Normal file
18
ansibleworks/templates/admin/404.html
Normal file
@@ -0,0 +1,18 @@
|
||||
{% extends "admin/base_site.html" %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block title %}{% trans "Not Found" %}{% endblock %}
|
||||
|
||||
{% block nav-global %}{% endblock %}
|
||||
|
||||
{% block breadcrumbs %}
|
||||
<div class="breadcrumbs">
|
||||
<a href="{% url "admin:index" %}">{% trans "Home" %}</a> ›
|
||||
{% trans "Not Found" %}
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h1 style="margin-bottom: 0.7em;">{% trans 'Not Found' %}</h1>
|
||||
<p>{% trans "We're sorry, but the requested page could not be found." %}</p>
|
||||
{% endblock %}
|
||||
20
ansibleworks/templates/admin/500.html
Normal file
20
ansibleworks/templates/admin/500.html
Normal file
@@ -0,0 +1,20 @@
|
||||
{% extends "admin/base_site.html" %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block title %}{% trans "Server Error" %}{% endblock %}
|
||||
|
||||
{% block nav-global %}{% endblock %}
|
||||
|
||||
{% block content_title %}{% endblock %}
|
||||
|
||||
{% block breadcrumbs %}
|
||||
<div class="breadcrumbs">
|
||||
<a href="{% url "admin:index" %}">{% trans "Home" %}</a> ›
|
||||
{% trans "Server Error" %}
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h1 style="margin-bottom: 0.7em;">{% trans 'Server Error' %}</h1>
|
||||
<p>{% trans "A server error has occurred." %}</p>
|
||||
{% endblock %}
|
||||
@@ -2,7 +2,7 @@
|
||||
{% extends "admin/base.html" %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block title %}{{ title }} | {% trans 'Ansible Commander Admin' %}{% endblock %}
|
||||
{% block title %}{{ title }} | {% trans 'AnsibleWorks Admin' %}{% endblock %}
|
||||
|
||||
{% block extrastyle %}
|
||||
{{ block.super }}
|
||||
@@ -172,7 +172,7 @@ if (django.jQuery) {
|
||||
{% endblock %}
|
||||
|
||||
{% block branding %}
|
||||
<h1 id="site-name">{% trans 'Ansible Commander Admin' %}</h1>
|
||||
<h1 id="site-name">{% trans 'AnsibleWorks Admin' %}</h1>
|
||||
{% endblock %}
|
||||
|
||||
{% block userlinks %}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{% extends 'rest_framework/base.html' %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block title %}{% trans 'Ansible Commander API' %}{% endblock %}
|
||||
{% block title %}{% trans 'AnsibleWorks API' %}{% endblock %}
|
||||
|
||||
{% block style %}
|
||||
{{ block.super }}
|
||||
@@ -52,7 +52,7 @@ html body .str a {
|
||||
{% endblock %}
|
||||
|
||||
{% block branding %}
|
||||
{% trans 'Ansible Commander API' %}
|
||||
{% trans 'AnsibleWorks API' %}
|
||||
<span class="powered-by">({% trans 'powered by' %} {{ block.super }})</span>
|
||||
{% endblock %}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user