From 3ee9ce47a7a7372df47690fb71cad5a0f9f9980d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Marques?= Date: Fri, 26 Mar 2021 07:00:30 +0000 Subject: [PATCH 1/2] [FIX] account_payment_partner: Fix multi-company issues Make payment_mode fields limited to the correct company TT28906 --- account_payment_partner/models/res_partner.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/account_payment_partner/models/res_partner.py b/account_payment_partner/models/res_partner.py index b20ac942d..7b911593a 100644 --- a/account_payment_partner/models/res_partner.py +++ b/account_payment_partner/models/res_partner.py @@ -11,12 +11,14 @@ class ResPartner(models.Model): supplier_payment_mode_id = fields.Many2one( comodel_name="account.payment.mode", company_dependent=True, + check_company=True, domain="[('payment_type', '=', 'outbound')]", help="Select the default payment mode for this supplier.", ) customer_payment_mode_id = fields.Many2one( comodel_name="account.payment.mode", company_dependent=True, + check_company=True, domain="[('payment_type', '=', 'inbound')]", help="Select the default payment mode for this customer.", ) From e85d95a01b1dbe31a0a4ace494e00232aac9ee71 Mon Sep 17 00:00:00 2001 From: CarlosRoca13 Date: Thu, 5 Aug 2021 13:36:08 +0200 Subject: [PATCH 2/2] [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 --- account_payment_partner/views/report_invoice.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/account_payment_partner/views/report_invoice.xml b/account_payment_partner/views/report_invoice.xml index ec31f0739..daa9f47d5 100644 --- a/account_payment_partner/views/report_invoice.xml +++ b/account_payment_partner/views/report_invoice.xml @@ -10,7 +10,7 @@

-

+

Bank Account: