# HG changeset patch
# User nishanth
# Date 1271339348 -19800
# Node ID d321a507fc268959431a1f38f288aab951cbac61
# Parent 3858a9d0f376ef101548d641102d0d91185e9d48
updated view_event page .
diff -r 3858a9d0f376 -r d321a507fc26 reg/views.py
--- a/reg/views.py Thu Apr 15 19:00:23 2010 +0530
+++ b/reg/views.py Thu Apr 15 19:19:08 2010 +0530
@@ -192,19 +192,17 @@
except Event.DoesNotExist:
return redirect("/reg")
- is_guest = False if user.is_authenticated() and user.is_active else True
- is_attendee = True if user in event.attendees.all() else False
+ is_attendee = True if user.is_active and user in event.attendees.all() else False
is_org = True if user in event.organizers.all() else False
can_submit_feedback = False
- if not event.feedback_status == "0":
+ if not event.feedback_status == "0" and user.is_authenticated():
try:
FeedLog.objects.get(user=user,event=event,day=event.feedback_status)
except FeedLog.DoesNotExist:
can_submit_feedback = True
context = {'user': user,
- 'is_guest': is_guest,
'event': event,
'is_attendee': is_attendee,
'is_org': is_org,
diff -r 3858a9d0f376 -r d321a507fc26 templates/feedback.html
--- a/templates/feedback.html Thu Apr 15 19:00:23 2010 +0530
+++ b/templates/feedback.html Thu Apr 15 19:19:08 2010 +0530
@@ -1,8 +1,9 @@
{% extends "base.html" %}
{% block content %}
-Feedback on Day {{event.feedback_status}} of {{event.title}} at {{event.venue}}
+Feedback on Day {{event.feedback_status}} of {{event.title}} at {{event.venue}}
{% if submitted %}
- Your feedback has been successfully submitted.
+ Your feedback has been successfully submitted.
+ Return to the workshop page
{% else %}