added is_active filter in list_feedbacks view.
authornishanth
Thu, 15 Apr 2010 18:27:38 +0530
changeset 54 345d4413b85c
parent 53 0a4b2c49f718
child 55 53ff84c9192d
added is_active filter in list_feedbacks view.
reg/views.py
--- a/reg/views.py	Thu Apr 15 18:23:21 2010 +0530
+++ b/reg/views.py	Thu Apr 15 18:27:38 2010 +0530
@@ -372,7 +372,7 @@
     """
 
     user = request.user
-    if not user.is_authenticated():
+    if not ( user.is_authenticated() and user.is_active ):
         return redirect('/reg')
 
     user_profile = user.get_profile()
@@ -421,7 +421,7 @@
     except Event.DoesNotExist:
         return redirect('/reg')
 
-    if not user in event.organizers.all():
+    if not user in event.organizers.all() and user.is_active:
         return redirect('/reg')
     
     profile = user.get_profile()