Fix logout redirect

This commit is contained in:
Mark Veidemanis 2022-07-21 13:49:43 +01:00
parent b9fda0d654
commit 877396f149
Signed by: m
GPG Key ID: 5ACFCEED46C0904F
4 changed files with 32 additions and 13 deletions

View File

@ -31,13 +31,13 @@ ALLOWED_HOSTS = []
# Application definition # Application definition
INSTALLED_APPS = [ INSTALLED_APPS = [
"core",
"django.contrib.admin", "django.contrib.admin",
"django.contrib.auth", "django.contrib.auth",
"django.contrib.contenttypes", "django.contrib.contenttypes",
"django.contrib.sessions", "django.contrib.sessions",
"django.contrib.messages", "django.contrib.messages",
"django.contrib.staticfiles", "django.contrib.staticfiles",
"core",
"crispy_forms", "crispy_forms",
"crispy_bulma", "crispy_bulma",
] ]
@ -126,7 +126,9 @@ DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField"
AUTH_USER_MODEL = "core.User" AUTH_USER_MODEL = "core.User"
LOGIN_REDIRECT_URL = "/" LOGIN_REDIRECT_URL = "home"
LOGOUT_REDIRECT_URL = "home"
LOGIN_URL = "/accounts/login/"
# ALLOWED_PAYMENT_METHODS = ["bacs_debit", "card"] # ALLOWED_PAYMENT_METHODS = ["bacs_debit", "card"]
ALLOWED_PAYMENT_METHODS = ["card"] ALLOWED_PAYMENT_METHODS = ["card"]

View File

@ -1,10 +1,12 @@
{% extends "base.html" %} {% extends "base.html" %}
{% block content %} {% block content %}
<h1 class="title">Pathogen Data Insights</h1> <div class="box">
<div class="container"> <h1 class="title">Pathogen Data Insights</h1>
<h2 class="subtitle">Welcome to the Neptune system</h2> <div class="container">
<div class="col"> <h2 class="subtitle">Welcome to the Neptune system</h2>
<h2 class="subtitle">Hello!</h2> <div class="col">
<h2 class="subtitle">Hello!</h2>
</div>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

View File

@ -118,12 +118,27 @@
</table> </table>
</div> </div>
</div> </div>
<p>{{ card }} hits</p> <div class="box">
<p>{{ redacted }} redacted</p> <div class="columns">
{% if exemption is not None %} <div class="column">
<p>redaction overriden by superuser</p> <p>{{ card }} hits</p>
{% endif %} </div>
<p>{{ took }}ms</p> {% if redacted != 0 %}
<div class="column">
<p>{{ redacted }} redacted</p>
</div>
{% endif %}
{% if exemption is not None %}
<div class="column">
<p>god mode</p>
</div>
{% endif %}
<div class="column">
<p>{{ took }}ms</p>
</div>
</div>
</div>
{% endif %} {% endif %}
{% endblock %} {% endblock %}