[FIX]:printscreen report Title not getting translated value

lp bug: https://launchpad.net/bugs/728173 fixed

bzr revid: nch@tinyerp.com-20110421063628-1hy46os11im1qh0i
This commit is contained in:
Naresh (OpenERP)
2011-04-21 12:06:28 +05:30
parent 2030bc90f9
commit 4c65b5fbcc
+3 -2
View File
@@ -67,11 +67,12 @@ class report_printscreen_list(report_int):
self.groupby_no_leaf = context.get('group_by_no_leaf',False)
pool = pooler.get_pool(cr.dbname)
model = pool.get(datas['model'])
# Title come from description of model which are specified in py file.
model_id = pool.get('ir.model').search(cr, uid, [('model','=',model._name)])
model_desc = model._description
if model_id:
model_desc = pool.get('ir.model').browse(cr, uid, model_id[0], context).name
self.title = model_desc
datas['ids'] = ids
model = pooler.get_pool(cr.dbname).get(datas['model'])
result = model.fields_view_get(cr, uid, view_type='tree', context=context)
fields_order = self.groupby + self._parse_string(result['arch'])
if self.groupby: