[FIX] reporting: avoid unicode errors
authorChristophe Simonis <chs@openerp.com>
Mon, 15 Nov 2010 13:41:58 +0000 (14:41 +0100)
committerChristophe Simonis <chs@openerp.com>
Mon, 15 Nov 2010 13:41:58 +0000 (14:41 +0100)
bzr revid: chs@openerp.com-20101115134158-ppmtmh6xxufs2iyj

bin/report/report_sxw.py

index 8ad8451..747cfcc 100644 (file)
@@ -278,7 +278,8 @@ class rml_parse(object):
             ret_lst.append({name:id})
         return ret_lst
 
-    def _translate(self,text):
+    def _translate(self, text):
+        text = tools.ustr(text)
         lang = self.localcontext['lang']
         if lang and text and not text.isspace():
             transl_obj = self.pool.get('ir.translation')