[FIX] doc: fit code example to new API

When using this code as is, the 'ids' variable throws an exception for not
being defined. In the new API, 'ids' is no longer given as a function variable
but as a variable within 'self'.

close #3406
This commit is contained in:
Nicolas Bustillos 2014-10-30 18:34:48 -04:00 committed by Xavier Morel
parent fcf0b278a9
commit d0ff6df2f4
1 changed files with 2 additions and 2 deletions

View File

@ -65,9 +65,9 @@ render_html method. Classically, this method returns a call to the original
report_obj = self.env['report']
report = report_obj._get_report_from_name('<<module.reportname>>')
docargs = {
'doc_ids': ids,
'doc_ids': self._ids,
'doc_model': report.model,
'docs': self.env[report.model].browse(ids),
'docs': self,
}
return report_obj.render('<<module.reportname>>', docargs)