diff options
Diffstat (limited to 'addons/report/models/report.py')
| -rw-r--r-- | addons/report/models/report.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/addons/report/models/report.py b/addons/report/models/report.py index 45a9bd8c346..2eed9824bf2 100644 --- a/addons/report/models/report.py +++ b/addons/report/models/report.py @@ -136,8 +136,7 @@ class Report(models.Model): 'doc_model': report.model, 'docs': docs, } - return self.render(report.report_name, docargs).encode('utf-8') - + return self.render(report.report_name, docargs) @api.model def get_pdf(self, docids, report_name, html=None, data=None): """This method generates and returns pdf version of a report. @@ -172,6 +171,8 @@ class Report(models.Model): if isinstance(self.env.cr, TestCursor): return html + html = html.decode('utf-8') # Ensure the current document is utf-8 encoded. + # Get the ir.actions.report.xml record we are working on. report = self._get_report_from_name(report_name) # Check if we have to save the report or if we have to get one from the db. |
