mirror of
https://github.com/OCA/bank-payment.git
synced 2025-02-02 10:37:31 +02:00
Add print button on mandate
This commit is contained in:
@@ -114,3 +114,9 @@ class AccountBankingMandate(models.Model):
|
||||
)
|
||||
else:
|
||||
logger.info("0 SDD Mandates had to be set to Expired")
|
||||
|
||||
def print_report(self):
|
||||
self.ensure_one()
|
||||
xmlid = "account_banking_sepa_direct_debit.report_sepa_direct_debit_mandate"
|
||||
action = self.env.ref(xmlid).report_action(self)
|
||||
return action
|
||||
|
||||
@@ -12,6 +12,9 @@
|
||||
<field name="model">account.banking.mandate</field>
|
||||
<field name="inherit_id" ref="account_banking_mandate.view_mandate_form" />
|
||||
<field name="arch" type="xml">
|
||||
<button name="validate" position="before">
|
||||
<button name="print_report" type="object" string="Print" />
|
||||
</button>
|
||||
<field name="partner_id" position="after">
|
||||
<field
|
||||
name="scheme"
|
||||
|
||||
Reference in New Issue
Block a user