summaryrefslogtreecommitdiff
path: root/bin/report/interface.py
diff options
context:
space:
mode:
authorFramework Team <>2010-03-30 13:30:26 +0200
committerOlivier Dony <odo@openerp.com>2010-03-30 13:30:26 +0200
commitb0e4c9b169a5cc1a700a9f02297b60b2649ca0cb (patch)
tree6556f5c3c91d36f23b2931868d0d56e757ed9f36 /bin/report/interface.py
parent415d714484c5d54d1cc8079746452135bb06741b (diff)
parentd69ca9424e26ef0b783f5357de564f252ace2b84 (diff)
[MERGE] merge from trunk-dev-framework
bzr revid: odo@openerp.com-20100330113026-u49ic0qxq1sa51bn
Diffstat (limited to 'bin/report/interface.py')
-rw-r--r--bin/report/interface.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/bin/report/interface.py b/bin/report/interface.py
index 9f67bdd6de1..6aecfe66133 100644
--- a/bin/report/interface.py
+++ b/bin/report/interface.py
@@ -138,7 +138,8 @@ class report_rml(report_int):
def create_rml(self, cr, xml, uid, context=None):
if not context:
context={}
- service = netsvc.LocalService("object_proxy")
+ pool = pooler.get_pool(cr.dbname)
+ ir_translation_obj = pool.get('ir.translation')
# In some case we might not use xsl ...
if not self.xsl:
@@ -159,9 +160,7 @@ class report_rml(report_int):
def translate(doc, lang):
for node in doc.xpath('//*[@t]'):
- translation = service.execute(
- cr.dbname, uid, 'ir.translation', '_get_source',
- self.name2, 'xsl', lang, node.text)
+ translation = ir_translation_obj._get_source(cr, uid, self.name2, 'xsl', lang, node.text)
if translation:
node.text = translation