[FIX] Report: search associated qweb views: do not forward context
The context may be inconsistent (for instance, containing a group_by associated to another model). The client will take care of keeping it consistent. Fixes issue #1768
This commit is contained in:
parent
6202918754
commit
4b82cf666f
|
@ -143,13 +143,10 @@ class ir_actions_report(osv.Model):
|
||||||
"""Used in the ir.actions.report.xml form view in order to search naively after the view(s)
|
"""Used in the ir.actions.report.xml form view in order to search naively after the view(s)
|
||||||
used in the rendering.
|
used in the rendering.
|
||||||
"""
|
"""
|
||||||
if context is None:
|
|
||||||
context = {}
|
|
||||||
try:
|
try:
|
||||||
report_name = self.browse(cr, uid, ids[0], context).report_name
|
report_name = self.browse(cr, uid, ids[0], context).report_name
|
||||||
act_window_obj = self.pool.get('ir.actions.act_window')
|
act_window_obj = self.pool.get('ir.actions.act_window')
|
||||||
view_action = act_window_obj.for_xml_id(cr, uid, 'base', 'action_ui_view', context=context)
|
view_action = act_window_obj.for_xml_id(cr, uid, 'base', 'action_ui_view', context=context)
|
||||||
view_action['context'] = context
|
|
||||||
view_action['domain'] = [('name', 'ilike', report_name.split('.')[1]), ('type', '=', 'qweb')]
|
view_action['domain'] = [('name', 'ilike', report_name.split('.')[1]), ('type', '=', 'qweb')]
|
||||||
return view_action
|
return view_action
|
||||||
except:
|
except:
|
||||||
|
|
Loading…
Reference in New Issue