diff options
author | Andrea Lepori <alepori@student.ethz.ch> | 2024-01-28 11:12:19 +0100 |
---|---|---|
committer | Andrea Lepori <alepori@student.ethz.ch> | 2024-01-28 11:12:19 +0100 |
commit | 9e420199e43420ee6688fce7dea524dd39a1e7b5 (patch) | |
tree | 11b9b1f3e43c47be324cd9bb8194c138fddeda5d /templates/registration | |
parent | add impersonation (diff) | |
download | scout-subs-9e420199e43420ee6688fce7dea524dd39a1e7b5.tar.gz scout-subs-9e420199e43420ee6688fce7dea524dd39a1e7b5.zip |
add impersonate banner
Diffstat (limited to 'templates/registration')
-rw-r--r-- | templates/registration/base_admin.html | 12 | ||||
-rw-r--r-- | templates/registration/base_client.html | 12 |
2 files changed, 24 insertions, 0 deletions
diff --git a/templates/registration/base_admin.html b/templates/registration/base_admin.html index 1f484e6..9643e35 100644 --- a/templates/registration/base_admin.html +++ b/templates/registration/base_admin.html @@ -87,6 +87,18 @@ <title>{% block title %}Scout Brega{% endblock %}</title> </head> <body> + {% if request.user.is_impersonate %} + <div class="navbar-fixed" style="height: 32px; line-height: 32px;"> + <nav style="height: 32px; line-height: 32px;"> + <div class="nav-wrapper"> + <p style="margin-top: 0px; margin-bottom: 0px; margin-left: 10px; margin-right: 10px;"> + Stai impersonando l'utente {{request.user}} + <a href="{% url 'impersonate-stop' %}" style="text-decoration: underline;">Chiudi impersonazione</a> + </p> + </div> + </nav> + </div> + {% endif %} <nav class="nav-extended"> <form id="su_change" method="post" action="{% url 'server'%}"> {% csrf_token %} diff --git a/templates/registration/base_client.html b/templates/registration/base_client.html index 2518988..e23482a 100644 --- a/templates/registration/base_client.html +++ b/templates/registration/base_client.html @@ -107,6 +107,18 @@ <title>{% block title %}Scout Brega{% endblock %}</title> </head> <body> + {% if request.user.is_impersonate %} + <div class="navbar-fixed" style="height: 32px; line-height: 32px;"> + <nav style="height: 32px; line-height: 32px;"> + <div class="nav-wrapper"> + <p style="margin-top: 0px; margin-bottom: 0px; margin-left: 10px; margin-right: 10px;"> + Stai impersonando l'utente {{request.user}} + <a href="{% url 'impersonate-stop' %}" style="text-decoration: underline;">Chiudi impersonazione</a> + </p> + </div> + </nav> + </div> + {% endif %} <nav class="nav-extended"> <form id="user_form" method="post" action="{% url 'user_switcher'%}"> {% csrf_token %} |