Moved the view of the HTTP 500 Internal Server Error from the Mia core application to the site URL settings, to reduce coupling between the site settings and the Mia core application.

This commit is contained in:
依瑪貓 2020-08-12 00:27:37 +08:00
parent 39efb65e2c
commit 5f18cc719c
2 changed files with 1 additions and 12 deletions

View File

@ -79,6 +79,7 @@ def cash(request, account, period):
Returns: Returns:
HttpResponse: The response. HttpResponse: The response.
""" """
a = 3 / 0
# The accounting records # The accounting records
if account.code == "0": if account.code == "0":
records = list( records = list(

View File

@ -63,18 +63,6 @@ def logout(request):
return redirect("home") return redirect("home")
def http500_view(request):
"""The view of the HTTP 500 Internal Server Error page.
Args:
request (HttpRequest): The request.
Returns:
HttpResponse: The response.
"""
return render(request, "500.html")
@method_decorator(require_GET, name="dispatch") @method_decorator(require_GET, name="dispatch")
@method_decorator(login_required, name="dispatch") @method_decorator(login_required, name="dispatch")
class UserListView(ListView): class UserListView(ListView):