From 1bf53ebfee2c911ed3aeca602c4e69ed6fb3bdce Mon Sep 17 00:00:00 2001 From: Charlie Denton Date: Fri, 24 Feb 2012 09:49:19 +0000 Subject: Restore *args to PDFTemplateView. --- wkhtmltopdf/views.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'wkhtmltopdf') diff --git a/wkhtmltopdf/views.py b/wkhtmltopdf/views.py index c92b117..c26d1fc 100644 --- a/wkhtmltopdf/views.py +++ b/wkhtmltopdf/views.py @@ -33,15 +33,13 @@ class PDFTemplateView(TemplateView): margin_top = 0 response = PDFResponse - def get(self, request, context_instance=None, **kwargs): + def get(self, request, context_instance=None, *args, **kwargs): if request.GET.get('as', '') == 'html': - return super(PDFTemplateView, self).get(request, **kwargs) + return super(PDFTemplateView, self).get(request, *args, **kwargs) - # Save arguments onto class (would have been done in super-class) self.context_instance = context_instance 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.get_filename()) -- cgit v1.2.3