From d9d5b7bc7f432058fd3bccfb096c88438e5364a9 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20St=C4=99pniowski?= Date: Sat, 10 Jan 2009 19:31:06 +0100 Subject: [PATCH] Added MP3 and OGG to book short_html view. --- apps/catalogue/models.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/apps/catalogue/models.py b/apps/catalogue/models.py index 6ab090df7..0cd19cc0c 100644 --- a/apps/catalogue/models.py +++ b/apps/catalogue/models.py @@ -120,11 +120,15 @@ class Book(models.Model): if self.html_file: formats.append(u'Czytaj online' % reverse('book_text', kwargs={'slug': self.slug})) if self.pdf_file: - formats.append(u'Plik PDF' % self.pdf_file.url) + formats.append(u'PDF' % self.pdf_file.url) if self.odt_file: - formats.append(u'Plik ODT' % self.odt_file.url) + formats.append(u'ODT' % self.odt_file.url) if self.txt_file: - formats.append(u'Plik TXT' % self.txt_file.url) + formats.append(u'TXT' % self.txt_file.url) + if self.mp3_file: + formats.append(u'MP3' % self.mp3_file.url) + if self.ogg_file: + formats.append(u'OGG' % self.ogg_file.url) self._short_html = unicode(render_to_string('catalogue/book_short.html', {'book': self, 'tags': tags, 'formats': formats})) -- 2.20.1