From bd54ca2949949b49f8ab3923ef9f47da157001ea Mon Sep 17 00:00:00 2001 From: Karthikeyan Date: Thu, 4 Apr 2024 01:11:10 +0530 Subject: [PATCH] [Karthi] | Fixed | Refactor. Print Summarized bill copy shortcut key added and button based report enabled. (#142) --- bahmni_account/models/account_invoice.py | 4 +++- bahmni_account/views/account_payment_view.xml | 12 ++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/bahmni_account/models/account_invoice.py b/bahmni_account/models/account_invoice.py index d5d6788..4612ab6 100644 --- a/bahmni_account/models/account_invoice.py +++ b/bahmni_account/models/account_invoice.py @@ -95,4 +95,6 @@ class AccountPayment(models.Model): def invoice_search(self): """ Using ref find the invoice obj """ return self.env['account.move'].search([('id', '=', self.reconciled_invoice_ids.id),('move_type', '=', 'out_invoice')], limit=1) - + + def generate_report_action(self): + return self.env.ref("bahmni_account.account_summarized_invoices_payment").report_action(self) diff --git a/bahmni_account/views/account_payment_view.xml b/bahmni_account/views/account_payment_view.xml index c9c9c30..0d0e25d 100644 --- a/bahmni_account/views/account_payment_view.xml +++ b/bahmni_account/views/account_payment_view.xml @@ -12,6 +12,18 @@ + + account.payment.form + account.payment + + + +