Add cookie and return message for regstats view function. payments
authorMadhusudan.C.S <madhusudancs@gmail.com>
Mon, 15 Nov 2010 19:43:15 +0530
branchpayments
changeset 255 b20d55891709
parent 254 7d0bb6e94deb
child 256 3dedcb0a0233
Add cookie and return message for regstats view function.
project/scipycon/registration/views.py
--- a/project/scipycon/registration/views.py	Mon Nov 15 19:38:59 2010 +0530
+++ b/project/scipycon/registration/views.py	Mon Nov 15 19:43:15 2010 +0530
@@ -302,7 +302,9 @@
 
     if not request.user.is_staff:
         redirect_to = reverse('scipycon_login', kwargs={'scope': scope})
-
+        return set_message_cookie(
+            redirect_to, msg = u'You must be a staff on this website to '
+            'access this page.')
 
     q = Registration.objects.all()
     conf_num = q.filter(conference=True).count()