diff --git a/account_financial_report_qweb/report/__init__.py b/account_financial_report_qweb/report/__init__.py index 231ff56b..329caec3 100644 --- a/account_financial_report_qweb/report/__init__.py +++ b/account_financial_report_qweb/report/__init__.py @@ -4,3 +4,4 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).- from . import common from . import general_ledger +from . import open_invoice diff --git a/account_financial_report_qweb/report/open_invoice.py b/account_financial_report_qweb/report/open_invoice.py new file mode 100644 index 00000000..0a1bb5cb --- /dev/null +++ b/account_financial_report_qweb/report/open_invoice.py @@ -0,0 +1,19 @@ +from openerp import models, api + +class OpenInvoiceReport(models.AbstractModel): + + _name = 'report.account_financial_report_qweb.open_invoice_report_qweb' + + @api.multi + def render_html(self, data=None): + report_obj = self.env['report'] + doc_ids = self._ids + docargs = { + 'doc_model': 'account.move.line', + 'doc_ids': doc_ids, + } + if data: + docargs.update(data) + return report_obj.render( + 'account_financial_report_qweb.open_invoice_report_qweb', + docargs) diff --git a/account_financial_report_qweb/report/templates/open_invoice_report.xml b/account_financial_report_qweb/report/templates/open_invoice_report.xml index d5c869cf..8cfc69da 100644 --- a/account_financial_report_qweb/report/templates/open_invoice_report.xml +++ b/account_financial_report_qweb/report/templates/open_invoice_report.xml @@ -2,7 +2,7 @@ -