diff --git a/stock_picking_batch_extended/models/stock_batch_picking.py b/stock_picking_batch_extended/models/stock_batch_picking.py index 8a76d1e5d7bb..b59ad3f52853 100644 --- a/stock_picking_batch_extended/models/stock_batch_picking.py +++ b/stock_picking_batch_extended/models/stock_batch_picking.py @@ -67,9 +67,9 @@ def action_print_picking(self): pickings = self.mapped("picking_ids") if not pickings: raise UserError(_("Nothing to print.")) - return self.env.ref( - "stock_picking_batch_extended.action_report_batch_picking" - ).report_action(self) + return self.env.ref("stock.action_report_delivery").report_action( + self.picking_ids + ) def remove_undone_pickings(self): """Remove of this batch all pickings which state is not done / cancel.""" diff --git a/stock_picking_batch_extended/tests/test_batch.py b/stock_picking_batch_extended/tests/test_batch.py index 0cf8cf21b42c..f5ca7ecbdab1 100644 --- a/stock_picking_batch_extended/tests/test_batch.py +++ b/stock_picking_batch_extended/tests/test_batch.py @@ -83,7 +83,7 @@ def test_print_picking(self): report_name = result.get("report_name") self.assertEqual( result.get("report_name"), - "stock_picking_batch_extended.report_batch_picking", + "stock.report_deliveryslip", ) report_pdf = self.env["ir.actions.report"]._render(report_name, self.batch.ids) self.assertGreaterEqual(len(report_pdf[0]), 1)