mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-24 20:33:11 +00:00
Ask to use another user
Make login page Django-complient so now other page can redirect to the login view if the user has unsufficient rights.
This commit is contained in:
parent
0bc1734cf3
commit
e4f78adeca
1 changed files with 9 additions and 0 deletions
|
@ -29,6 +29,15 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
{% block title %}{% trans "Log in" %}{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
{% if user.is_authenticated %}
|
||||
<p class="errornote">
|
||||
{% blocktrans trimmed %}
|
||||
You are authenticated as {{ username }}, but are not authorized to
|
||||
access this page. Would you like to login to a different account?
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
{% endif %}
|
||||
|
||||
<form method="post" action="">
|
||||
{% csrf_token %}
|
||||
{% bootstrap_form form %}
|
||||
|
|
Loading…
Reference in a new issue