aboutsummaryrefslogtreecommitdiffstats
path: root/wkhtmltopdf/views.py
diff options
context:
space:
mode:
authorCharlie Denton <charlie@meshy.co.uk>2012-02-23 17:53:36 +0000
committerCharlie Denton <charlie@meshy.co.uk>2012-02-23 17:53:36 +0000
commit923c044e5d77e841a694ded1b9940ea6a9620596 (patch)
tree2e44b11ecfc7285a814f02d83ead57becdbd1f73 /wkhtmltopdf/views.py
parente625b44977915a8bf193f5fc974fba86758b7926 (diff)
downloaddjango-wkhtmltopdf-923c044e5d77e841a694ded1b9940ea6a9620596.tar.gz
django-wkhtmltopdf-923c044e5d77e841a694ded1b9940ea6a9620596.tar.bz2
django-wkhtmltopdf-923c044e5d77e841a694ded1b9940ea6a9620596.zip
Add get_filename method.
Diffstat (limited to 'wkhtmltopdf/views.py')
-rw-r--r--wkhtmltopdf/views.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/wkhtmltopdf/views.py b/wkhtmltopdf/views.py
index 53f11bd..561faf0 100644
--- a/wkhtmltopdf/views.py
+++ b/wkhtmltopdf/views.py
@@ -42,7 +42,10 @@ class PDFTemplateView(TemplateView):
page_path = template_to_temp_file(self.template_name, self.get_context_data(), self.context_instance)
pdf_kwargs = self.get_pdf_kwargs()
- return self.response(wkhtmltopdf(page_path, **pdf_kwargs), self.filename)
+ return self.response(wkhtmltopdf(page_path, **pdf_kwargs), self.get_filename())
+
+ def get_filename(self):
+ return self.filename
def get_pdf_kwargs(self):
kwargs = {