now login is required for accessing stats and send_invi pages anoop
authornishanth
Mon, 07 Jun 2010 15:20:11 +0530
branchanoop
changeset 65 0ca63c964237
parent 64 3650417b0fda
child 66 8a5436485760
now login is required for accessing stats and send_invi pages
sdi/views.py
--- a/sdi/views.py	Mon Jun 07 15:13:16 2010 +0530
+++ b/sdi/views.py	Mon Jun 07 15:20:11 2010 +0530
@@ -1,6 +1,6 @@
 from django.shortcuts import render_to_response, redirect
 from django.http import HttpResponse
-
+from django.contrib.auth.decorators import login_required
 
 from sage_days.sdi.models import Registrant
 from sage_days.sdi.forms import RegisterForm, SearchForm, EmailForm
@@ -34,6 +34,7 @@
 
     return render_to_response("reg_complete.html")
 
+@login_required
 def list_stats(request):
     """ List the statiscs of registered participants.
     """
@@ -81,6 +82,7 @@
         form = SearchForm()
         return render_to_response("list_stats.html", {"form":form})
 
+@login_required
 def send_invi(request):
     """ Take a list of csv email addresses and send mails to them.
     """