From: Marek Stępniowski Date: Sat, 10 Jan 2009 18:31:06 +0000 (+0100) Subject: Added MP3 and OGG to book short_html view. X-Git-Url: https://git.mdrn.pl/wolnelektury.git/commitdiff_plain/d9d5b7bc7f432058fd3bccfb096c88438e5364a9 Added MP3 and OGG to book short_html view. --- 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}))