added date tags in view event template and open_feedback template is now a lil better .
--- a/feedback/views.py Tue Apr 13 16:32:13 2010 +0530
+++ b/feedback/views.py Thu Apr 15 11:57:42 2010 +0530
@@ -4,6 +4,7 @@
from workshop.feedback.models import Feedback
from workshop.feedback.forms import FeedbackForm
+from workshop.feedback.utils import compile_report
from django.http import HttpResponse
@@ -61,6 +62,9 @@
if not user in event.organizers.all():
raise Http404
- feeds = Feedback.objects.filter(event=event)
- return render_to_response('list_feedbacks.html',{'feeds':feeds})
+ no_of_days = (event.stop_date - event.start_date).days
+ days = range(1,no_of_days+1)
+
+ return render_to_response('list_feedbacks.html',{'user':user, 'event':event})
+
--- a/templates/list_events.html Tue Apr 13 16:32:13 2010 +0530
+++ b/templates/list_events.html Thu Apr 15 11:57:42 2010 +0530
@@ -5,7 +5,7 @@
<table cellspacing=5 cellpadding=5>
{% for event in ongoing_events %}
<tr>
- <td align="center"><a href="/reg/event/view/{{event.key}}">{{event.title}}</a></td>
+ <td align="right"><a href="/reg/event/view/{{event.key}}">{{event.title}}</a></td>
<td>{{event.start_date|date:"d M Y"}} - {{event.stop_date|date:"d M Y"}}</td>
</tr>
{% endfor %}
@@ -17,7 +17,7 @@
<table cellspacing=5 cellpadding=5>
{% for event in upcoming_events %}
<tr>
- <td align="center"><a href="/reg/event/view/{{event.key}}">{{event.title}}</a></td>
+ <td align="right"><a href="/reg/event/view/{{event.key}}">{{event.title}}</a></td>
<td>{{event.start_date|date:"d M Y"}} - {{event.stop_date|date:"d M Y"}}</td>
</tr>
{% endfor %}
@@ -31,7 +31,7 @@
<table cellspacing=5 cellpadding=5>
{% for event in previous_events %}
<tr>
- <td align="center"><a href="/reg/event/view/{{event.key}}">{{event.title}}</a></td>
+ <td align="right"><a href="/reg/event/view/{{event.key}}">{{event.title}}</a></td>
<td>{{event.start_date|date:"d M Y"}} - {{event.stop_date|date:"d M Y"}}</td>
</tr>
{% endfor %}
--- a/templates/list_feedbacks.html Tue Apr 13 16:32:13 2010 +0530
+++ b/templates/list_feedbacks.html Thu Apr 15 11:57:42 2010 +0530
@@ -1,6 +1,8 @@
{% extends "base.html" %}
{% block content %}
-{% for feed in feeds %}
- {{ feed }}<br />
-{% endfor %}
+Report of the workshop <a href="/reg/event/view/{{event.key}}">{{event.title}}</a>
+conducted at {{event.venue}} from {{event.start_date|date:"d M Y"}} to
+{{event.stop_date|date:"d M Y"}}<br />
+<br />
+{{workshop_report|unordered_list}}
{% endblock %}
--- a/templates/open_feedback.html Tue Apr 13 16:32:13 2010 +0530
+++ b/templates/open_feedback.html Thu Apr 15 11:57:42 2010 +0530
@@ -1,10 +1,10 @@
{% extends "base.html" %}
{% block content %}
{% if success %}
- The feedback for day {{day}} of {{event.title}} has been opened.<br />
- <a href="/reg/event/view/{{event.key}}">Click here</a> to return to the event page.
+ The feedback for day {{day}} of <a href="/reg/event/view/{{event.key}}">{{event.title}}</a> has been opened.<br />
+ <a href="/reg/event/view/{{event.key}}">Return to view the event page</a>
{% else %}
- Select the day for workshop {{event.title}} to start accepting feedbacks.
+ Select the day of workshop <a href="/reg/event/view/{{event.key}}">{{event.title}}</a> to start accepting feedbacks.
<form action="" method="post">
Day:<br />
<select name="day">
--- a/templates/view_event.html Tue Apr 13 16:32:13 2010 +0530
+++ b/templates/view_event.html Thu Apr 15 11:57:42 2010 +0530
@@ -20,9 +20,9 @@
{% endif %}
{% if can_submit_feedback %}
- <a href="/feedback/submit/{{event.key}}">Click here</a> to submit feedback for day {{event.feedback_status}}.<br />
+ <a href="/feedback/submit/{{event.key}}">Submit feedback for day {{event.feedback_status}} of {{event.title}}<br />
{% endif %}
-
+ <br />
{% if is_org %}
<a href="/reg/event/attendees/{{event.key}}">View list of people registered for the workshop</a> <br />
<a href="/feedback/list/{{event.key}}">View submitted feedbacks</a><br /><br />