[IMP] account_ebics_batch_payment: restrict EBICS file format domain to upload formats defined in EBICS config

This commit is contained in:
Luc De Meyer
2026-08-05 12:51:54 +02:00
parent d14d0edf72
commit 1246590592
3 changed files with 16 additions and 1 deletions
@@ -1 +1 @@
from . import account_batch_payment, account_payment_method from . import account_batch_payment, account_journal, account_payment_method
@@ -0,0 +1,13 @@
# Copyright 2026 Noviat.
# License LGPL-3 or later (http://www.gnu.org/licenses/lgpl).
from odoo import fields, models
class AccountJournal(models.Model):
_inherit = "account.journal"
ebics_file_format_ids = fields.Many2many(
comodel_name="ebics.file.format",
related="ebics_config_id.ebics_file_format_ids",
)
@@ -13,6 +13,7 @@
name="ebics_file_format_id" name="ebics_file_format_id"
optional="hide" optional="hide"
options="{'no_create': True}" options="{'no_create': True}"
domain="[('id', 'in', parent.ebics_file_format_ids), ('type', '=', 'up')]"
/> />
</xpath> </xpath>
<xpath <xpath
@@ -23,6 +24,7 @@
name="ebics_file_format_id" name="ebics_file_format_id"
optional="hide" optional="hide"
options="{'no_create': True}" options="{'no_create': True}"
domain="[('id', 'in', parent.ebics_file_format_ids), ('type', '=', 'up')]"
/> />
</xpath> </xpath>
</field> </field>