This commit is contained in:
Yannick Vaucher
2015-08-18 14:47:50 +02:00
committed by Carlos Roca
parent 965028ac3a
commit 440d354e55
2 changed files with 7 additions and 5 deletions

View File

@@ -25,7 +25,8 @@
'name': "Report to printer", 'name': "Report to printer",
'version': '0.1.1', 'version': '0.1.1',
'category': 'Generic Modules/Base', 'category': 'Generic Modules/Base',
'author': "Agile Business Group & Domsense, Pegueroles SCP, NaN,Odoo Community Association (OCA)", 'author': "Agile Business Group & Domsense, Pegueroles SCP, NaN,"
"Odoo Community Association (OCA)",
'website': 'http://www.agilebg.com', 'website': 'http://www.agilebg.com',
'license': 'AGPL-3', 'license': 'AGPL-3',
"depends": ['base', "depends": ['base',

View File

@@ -46,9 +46,10 @@ class Report(models.Model):
@api.v8 @api.v8
def print_document(self, records, report_name, html=None, data=None): def print_document(self, records, report_name, html=None, data=None):
return self._model.print_document(self._cr, self._uid, return self._model.print_document(
records.ids, report_name, self._cr, self._uid,
html=html, data=data, context=self._context) records.ids, report_name,
html=html, data=data, context=self._context)
def _can_print_report(self, cr, uid, ids, behaviour, printer, document, def _can_print_report(self, cr, uid, ids, behaviour, printer, document,
context=None): context=None):
@@ -88,4 +89,4 @@ class Report(models.Model):
def get_pdf(self, records, report_name, html=None, data=None): def get_pdf(self, records, report_name, html=None, data=None):
return self._model.get_pdf(self._cr, self._uid, return self._model.get_pdf(self._cr, self._uid,
records.ids, report_name, records.ids, report_name,
html=html, data=data, context=self._context) html=html, data=data, context=self._context)