From aa87097f1cff052c603ce135d3f5f329024d988b Mon Sep 17 00:00:00 2001 From: dwickwire Date: Fri, 28 Oct 2011 10:57:34 -0500 Subject: [PATCH 1/1] Added 'remember me' functionality to view --- cas_provider/templates/cas/logout.html | 2 +- cas_provider/views.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/cas_provider/templates/cas/logout.html b/cas_provider/templates/cas/logout.html index e5e435f..f7b25e9 100644 --- a/cas_provider/templates/cas/logout.html +++ b/cas_provider/templates/cas/logout.html @@ -7,6 +7,6 @@ Logged out {% block content %}

Logged out

-

You have successfully logged out. To ensure that you are logged out of all services, please close your browser.

+

You have successfully logged out.

{% if url %}

Click here to return to {{ url }}

{% endif %} {% endblock %} diff --git a/cas_provider/views.py b/cas_provider/views.py index 47f1758..fd15c4a 100644 --- a/cas_provider/views.py +++ b/cas_provider/views.py @@ -27,7 +27,9 @@ def login(request, template_name='cas/login.html', success_redirect='/accounts/' password = request.POST.get('password', None) service = request.POST.get('service', None) lt = request.POST.get('lt', None) - + if not request.POST.get('remember_me', None): + request.session.set_expiry(0) + try: login_ticket = LoginTicket.objects.get(ticket=lt) except: -- 2.20.1