replaced acco_required with user.acco_required in template and made change accordingly anoop
authornishanth
Tue, 20 Jul 2010 12:37:30 +0530
branchanoop
changeset 139 7eaaecef80f6
parent 138 c9ae768c55b7
child 140 73d6fedd9c22
child 141 ee39807aa6c8
replaced acco_required with user.acco_required in template and made change accordingly
sdi/views.py
templates/attending_sgd.html
--- a/sdi/views.py	Tue Jul 20 12:30:44 2010 +0530
+++ b/sdi/views.py	Tue Jul 20 12:37:30 2010 +0530
@@ -212,7 +212,7 @@
     user_info = user.registrantinfo_set.all()[0]
     status = user_info.status_of_attending_sagedays
     if status == "3":
-        return render_to_response("attending_sgd.html")
+        return render_to_response("attending_sgd.html", {"user":user})
     elif status != "2":
         raise Http404
 
@@ -230,9 +230,7 @@
         user_info.status_of_attending_sagedays = "3"
         user_info.save()
 
-        acco_required = user.acco_required
-
-        return render_to_response("attending_sgd.html", {"acco_required":acco_required})
+        return render_to_response("attending_sgd.html", {"user":user})
     else:
         return render_to_response("cnf_sgd_ptc.html", {"user":user})
 
--- a/templates/attending_sgd.html	Tue Jul 20 12:30:44 2010 +0530
+++ b/templates/attending_sgd.html	Tue Jul 20 12:37:30 2010 +0530
@@ -7,7 +7,7 @@
 Please make sure you are present at the venue by 8:30am on 9th Aug, 2010.
 <br /><br />
 
-{% if acco_required %}
+{% if user.acco_required %}
 The status of your accomodation will be mailed to you shortly.
 {% endif %}
 {% endblock %}