mirror of
https://github.com/OCA/bank-payment.git
synced 2025-02-02 10:37:31 +02:00
[FIX] acount_payment_sale: set bank account only on out invoices
This commit is contained in:
@@ -8,7 +8,10 @@ class AccountMove(models.Model):
|
||||
|
||||
@api.model
|
||||
def create(self, vals_list):
|
||||
if vals_list.get("payment_mode_id"):
|
||||
if vals_list.get("payment_mode_id") and vals_list.get("type") in (
|
||||
"out_invoice",
|
||||
"out_refund",
|
||||
):
|
||||
payment_mode = self.env["account.payment.mode"].browse(
|
||||
vals_list["payment_mode_id"]
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user