[MIG] report_async: Migrated v15 to v16
parent
6f6f11bffd
commit
aff53d7b2d
|
@ -3,7 +3,7 @@
|
|||
{
|
||||
"name": "Report Async",
|
||||
"summary": "Central place to run reports live or async",
|
||||
"version": "15.0.1.0.0",
|
||||
"version": "16.0.1.0.0",
|
||||
"author": "Ecosoft, Odoo Community Association (OCA)",
|
||||
"license": "AGPL-3",
|
||||
"website": "https://github.com/OCA/reporting-engine",
|
||||
|
|
|
@ -140,7 +140,7 @@ class ReportAsync(models.Model):
|
|||
report = self.env["ir.actions.report"].browse(report_id)
|
||||
func = REPORT_TYPES_FUNC[report.report_type]
|
||||
# Run report
|
||||
out_file, file_ext = getattr(report, func)(docids, data)
|
||||
out_file, file_ext = getattr(report, func)(report.xml_id, docids, data)
|
||||
out_file = base64.b64encode(out_file)
|
||||
out_name = "{}.{}".format(report.name, file_ext)
|
||||
# Save report to attachment
|
||||
|
@ -170,5 +170,7 @@ class ReportAsync(models.Model):
|
|||
def _send_email(self, attachment):
|
||||
template = self.env.ref("report_async.async_report_delivery")
|
||||
template.send_mail(
|
||||
attachment.id, notif_layout="mail.mail_notification_light", force_send=False
|
||||
attachment.id,
|
||||
email_layout_xmlid="mail.mail_notification_light",
|
||||
force_send=False,
|
||||
)
|
||||
|
|
|
@ -3,3 +3,8 @@
|
|||
* Kitti U. <kittiu@ecosoft.co.th>
|
||||
* Saran Lim. <saranl@ecosoft.co.th>
|
||||
* Tharathip Chaweewongphan <tharathipc@ecosoft.co.th>
|
||||
|
||||
* Opensourceintegrators
|
||||
|
||||
* Daniel Reis <dreis@opensourceintegrators.com>
|
||||
* Nikul Chaudhary <nchaudhary@opensourceintegrators.com>
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
../../../../report_async
|
|
@ -0,0 +1,6 @@
|
|||
import setuptools
|
||||
|
||||
setuptools.setup(
|
||||
setup_requires=['setuptools-odoo'],
|
||||
odoo_addon=True,
|
||||
)
|
Loading…
Reference in New Issue