From: Guillaume Pellerin Date: Mon, 15 Jun 2015 07:32:52 +0000 (+0200) Subject: epub: fix cover title X-Git-Tag: 1.6a~4^2~31 X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=b536e5e3e37b28d2d2032619f152df473ed3d7d5;p=telemeta.git epub: fix cover title --- diff --git a/telemeta/views/epub.py b/telemeta/views/epub.py index da8b0ca9..dde884ba 100644 --- a/telemeta/views/epub.py +++ b/telemeta/views/epub.py @@ -56,6 +56,7 @@ class BaseEpubMixin(TelemetaBaseMixin): site = Site.objects.get_current() self.chapters = [] default_image_added = False + full_title = corpus.title + ' - ' + collection.title if not collection: self.filename = self.corpus.code @@ -182,7 +183,7 @@ class BaseEpubMixin(TelemetaBaseMixin): self.book.spine.insert(0,'nav') # create spin, add cover page as first page - cover = epub.EpubHtml(title='cover-bis', file_name='cover-bis' + '.xhtml') + cover = epub.EpubHtml(title=full_title, file_name='cover-bis' + '.xhtml') cover.content = render_to_string(self.template_cover, {'image': cover_filename}) self.book.add_item(cover) self.book.spine.insert(0, cover)