From 4d0e8fee31d2571dddcb4d90316a88fc0382d109 Mon Sep 17 00:00:00 2001 From: Sanj Date: Sat, 10 Sep 2011 08:33:22 +0530 Subject: [PATCH] er, ups --- itf/app/models.py | 11 ++++------- itf/festival/models.py | 5 ++++- itf/templates/modules/festival/project.html | 0 3 files changed, 8 insertions(+), 8 deletions(-) create mode 100644 itf/templates/modules/festival/project.html diff --git a/itf/app/models.py b/itf/app/models.py index 3722191..f7d6d04 100644 --- a/itf/app/models.py +++ b/itf/app/models.py @@ -81,13 +81,10 @@ class ItfModel(models.Model): return self.get(self._get_fields().keys()) def insidepage_dict(self): - if not exists(self.get_template_path()): - html = "Template not found at: " + self.get_template_path() - else: - try: - html = render_to_string(self.get_template_path(), self.info_dict()) - except: - html = "Template render error." + try: + html = render_to_string(self.get_template_path(), self.info_dict()) + except: + html = "Template path not found at : " + self.get_template_path() return { 'url': self.get_absolute_url(), 'title': self.get_title(), diff --git a/itf/festival/models.py b/itf/festival/models.py index fce1f5c..4fcac80 100644 --- a/itf/festival/models.py +++ b/itf/festival/models.py @@ -80,6 +80,9 @@ class Participant(ItfModel): def __unicode__(self): return self.name + def get_title(self): + return self.title + def list_dict(self): return { 'id': self.id, @@ -91,7 +94,7 @@ class Participant(ItfModel): 'id': self.id, 'name': self.name, 'title': self.title, - 'short_bio': self.short_bio, + 'short_bio': self.short_bio } class Talk(models.Model): diff --git a/itf/templates/modules/festival/project.html b/itf/templates/modules/festival/project.html new file mode 100644 index 0000000..e69de29