[IMP] qweb.render: t-esc/t-raw rendered as `False` or `None` replaced by empty strings

bzr revid: odo@openerp.com-20140129180600-0c155g520gpvnqqf
This commit is contained in:
Olivier Dony 2014-01-29 19:06:00 +01:00
parent 958ecb84b0
commit 3d1b879049
1 changed files with 2 additions and 0 deletions

View File

@ -181,6 +181,8 @@ class QWeb(orm.AbstractModel):
val = self.eval(expr, qwebcontext)
if isinstance(val, unicode):
return val.encode("utf8")
if val is False or val is None:
return ''
return str(val)
def eval_format(self, expr, qwebcontext):