[FIX] pass context as keyword argument to search()

closes #10080
This commit is contained in:
Holger Brunn
2015-12-16 11:42:05 +01:00
committed by Xavier Morel
parent 1ac94db8e8
commit f9f7669e60
+1 -1
View File
@@ -1588,7 +1588,7 @@ class Reports(http.Controller):
if 'name' not in action: if 'name' not in action:
reports = request.session.model('ir.actions.report.xml') reports = request.session.model('ir.actions.report.xml')
res_id = reports.search([('report_name', '=', action['report_name']),], res_id = reports.search([('report_name', '=', action['report_name']),],
0, False, False, context) context=context)
if len(res_id) > 0: if len(res_id) > 0:
file_name = reports.read(res_id[0], ['name'], context)['name'] file_name = reports.read(res_id[0], ['name'], context)['name']
else: else: