[FIX] account_payment_partner: Error when salesperson tries to print invoices

This error is happening because the salesperson has not access to payment_method_id.

With this changes we avoid the error and the invoices are printed like normally.

TT31296
This commit is contained in:
CarlosRoca13
2021-08-05 13:36:08 +02:00
committed by Hai Lang
parent 3ee9ce47a7
commit e85d95a01b

View File

@@ -10,7 +10,7 @@
<span t-field="o.payment_mode_id.note" />
</p>
<t t-if="o.payment_mode_id and o.payment_mode_id.show_bank_account != 'no'">
<p t-foreach="o.partner_banks_to_show()" t-as="partner_bank">
<p t-foreach="o.sudo().partner_banks_to_show()" t-as="partner_bank">
<strong>Bank Account:</strong>
<t t-if="partner_bank.bank_id">
<t