From 226f3afe6ad0305c667e7f96d8c6109dd4649acf Mon Sep 17 00:00:00 2001 From: Sanj Date: Tue, 13 Dec 2011 18:21:01 +0530 Subject: [PATCH] participant page shows meetings attended --- itf/festival/models.py | 6 ++++-- itf/templates/modules/festival/participant.html | 8 ++++++++ 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/itf/festival/models.py b/itf/festival/models.py index 8931f72..98b3070 100755 --- a/itf/festival/models.py +++ b/itf/festival/models.py @@ -72,7 +72,8 @@ class Meeting(ItfModel): t.video = Video.objects.filter(talk__id=t.id) meeting_data['imagegallery'] = Image.objects.filter(meeting__id=meeting_id) - meeting_data['participants'] = Participant.objects.filter(meeting__id=meeting_id).order_by('name') +# meeting_data['participants'] = Participant.objects.filter(meeting__id=meeting_id).order_by('name') + meeting_data['participants'] = self.participants.all() return meeting_data class Participant(ItfModel): @@ -99,7 +100,8 @@ class Participant(ItfModel): 'id': self.id, 'name': self.name, 'title': self.title, - 'short_bio': self.short_bio + 'short_bio': self.short_bio, + 'meetings': self.meetings.all() } diff --git a/itf/templates/modules/festival/participant.html b/itf/templates/modules/festival/participant.html index 8ed5d24..df19cb3 100755 --- a/itf/templates/modules/festival/participant.html +++ b/itf/templates/modules/festival/participant.html @@ -1,3 +1,11 @@ {% load markup %}
{{ name }}:
{{ short_bio|markdown }} +
+
Meetings attended
+ +