Skip to content

Commit

Permalink
[FIX] aeroo#62: Printing multiple items directly to a printer only pr…
Browse files Browse the repository at this point in the history
…ints first item
  • Loading branch information
a0c committed Feb 17, 2022
1 parent 5f2d799 commit 65a20c3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions report_aeroo_direct_print/report_aeroo_direct_print.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ class report_print_actions(models.TransientModel):

def report_to_printer(self, cr, uid, ids, report_id, printer, context={}):
_logger.info('Printing with printer %s' % printer)
ids = context.get('active_ids', ids) # [FIX] #62: Printing multiple items directly to a printer only prints first item
context['active_ids'] = ids
report_xml = self.pool.get('ir.actions.report.xml').browse(cr, uid, report_id, context=context)
data = {'model': report_xml.model, 'id': context['active_ids'][0], 'report_type': 'aeroo'}
Expand Down

0 comments on commit 65a20c3

Please sign in to comment.