aboutsummaryrefslogtreecommitdiffstats
path: root/accounts
diff options
context:
space:
mode:
authorAndrea Lepori <alepori@student.ethz.ch>2024-01-27 18:06:05 +0100
committerAndrea Lepori <alepori@student.ethz.ch>2024-01-27 18:06:05 +0100
commit63874cf9820ee82050d3d11ba12212c197821fcd (patch)
tree676ad52e31e5dc3d3ca17ab09e9712a34ed7a1af /accounts
parentupdate group of docs when type changes (diff)
downloadscout-subs-63874cf9820ee82050d3d11ba12212c197821fcd.tar.gz
scout-subs-63874cf9820ee82050d3d11ba12212c197821fcd.zip
add impersonation
Diffstat (limited to 'accounts')
-rw-r--r--accounts/urls.py1
-rw-r--r--accounts/views.py5
2 files changed, 6 insertions, 0 deletions
diff --git a/accounts/urls.py b/accounts/urls.py
index 57a649d..76a54e6 100644
--- a/accounts/urls.py
+++ b/accounts/urls.py
@@ -14,4 +14,5 @@ urlpatterns = [
path('oauth_disconnect/', views.oauth_disconnect, name='oauth_disconnect'),
path('auth_connect/', views.auth_connect, name='auth_connect'),
path('user_switcher/', views.user_switcher, name='user_switcher'),
+ path('logout/', views.logout_view, name='logout'),
]
diff --git a/accounts/views.py b/accounts/views.py
index f04f495..9ecb15f 100644
--- a/accounts/views.py
+++ b/accounts/views.py
@@ -789,3 +789,8 @@ def edit(request, code):
def terms(request):
context = {}
return render(request, 'accounts/terms.html', context)
+
+
+def logout_view(request):
+ logout(request)
+ return HttpResponseRedirect('/') \ No newline at end of file