1

I am trying to use an automated action and a python expression to print a report which features a package's barcode when that package is initially created. I have my report setup with the barcode and other information I need. I have tried several ways to get this to work including:

  • Using report_action() to print the report
  • Using action = { ... } to print the report

I have not been able to find information on printing with an automated action and odoo studio and would appreciate any assistance, thanks.

holydragon
  • 6,158
  • 6
  • 39
  • 62

1 Answers1

0

If you need automated printing then you most likely need third party addon. Someting like thet: https://apps.odoo.com/apps/modules/15.0/printnode_base/

If you want to just open the pdf then you can create report action and then print it from the browser.

Paxmees
  • 1,540
  • 1
  • 15
  • 28
  • How would you go about creating a report action. I have tried doing something like env.ref('stock.action_report_quant_package_barcode_small').report_action(record) and it doesn't give me any error but it also doesn't download the report. I have also tried action = { 'type': 'ir.actions.report', 'name': 'Package Barcode with Content copy(1)', 'model': 'stock.quant.package', 'report_type': 'qweb-pdf', 'report_name': 'stock.action_report_quant_package_barcode_small', } but I run into the same issues where no errors are thrown, but nothing happens – Brendan Cariota Aug 16 '22 at 22:03