From 0b637725be2472d68f3a1fa17833a3472fc40431 Mon Sep 17 00:00:00 2001 From: "Ravi Gohil (OpenERP)" Date: Fri, 15 Feb 2013 14:12:13 +0530 Subject: [PATCH] [FIX] report_webkit: If a certain translateable term happens to be the same src value as on another report (both webkit and non-webkit reports) the resulting translation on a webkit report uses the first translation found (which is highly likely to be from the other report). (Maintenance Case: 586086) lp bug: https://launchpad.net/bugs/1098602 fixed bzr revid: rgo@tinyerp.com-20130215084213-h38jfi447y4qpf94 --- addons/report_webkit/webkit_report.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/report_webkit/webkit_report.py b/addons/report_webkit/webkit_report.py index b6c273f8852..6ad950d8302 100644 --- a/addons/report_webkit/webkit_report.py +++ b/addons/report_webkit/webkit_report.py @@ -191,8 +191,9 @@ class WebKitParser(report_sxw): def translate_call(self, src): """Translate String.""" ir_translation = self.pool.get('ir.translation') + name = self.tmpl and 'addons/' + self.tmpl or None res = ir_translation._get_source(self.parser_instance.cr, self.parser_instance.uid, - None, 'report', self.parser_instance.localcontext.get('lang', 'en_US'), src) + name, 'report', self.parser_instance.localcontext.get('lang', 'en_US'), src) if not res : return src return res