diff --git a/odex25_takaful/odex_takaful/controllers/report_api.py b/odex25_takaful/odex_takaful/controllers/report_api.py index a8fe50d5c..d88796e3c 100644 --- a/odex25_takaful/odex_takaful/controllers/report_api.py +++ b/odex25_takaful/odex_takaful/controllers/report_api.py @@ -34,7 +34,7 @@ class ReportController(http.Controller): html = report.with_env(env).with_context(context)._render_qweb_html(docids, data=data)[0] return request.make_response(html) elif converter == 'pdf': - pdf = report.with_env(env).with_context(context)._render_qweb_pdf(docids) + pdf = report.with_env(env).with_context(context)._render_qweb_pdf(docids)[0] pdfhttpheaders = [('Content-Type', 'application/pdf'), ('Content-Length', len(pdf))] return request.make_response(pdf, headers=pdfhttpheaders) elif converter == 'text':