diff --git a/account_invoice_import/models/company.py b/account_invoice_import/models/company.py index d2092b374f..3b04213fb4 100644 --- a/account_invoice_import/models/company.py +++ b/account_invoice_import/models/company.py @@ -18,6 +18,8 @@ class ResCompany(models.Model): 'Mail Gateway: Destination E-mail', help="This field is used in multi-company setups to import the " "invoices received by the mail gateway in the appropriate company") + invoice_import_create_bank_account = fields.Boolean( + string='Auto-create Bank Account of Supplier') _sql_constraints = [( 'invoice_import_email_uniq', diff --git a/account_invoice_import/models/res_config_settings.py b/account_invoice_import/models/res_config_settings.py index 1aa978edbd..82f4707c03 100644 --- a/account_invoice_import/models/res_config_settings.py +++ b/account_invoice_import/models/res_config_settings.py @@ -13,3 +13,6 @@ class AccountConfigSettings(models.TransientModel): related='company_id.adjustment_debit_account_id', readonly=False) invoice_import_email = fields.Char( related='company_id.invoice_import_email', readonly=False) + invoice_import_create_bank_account = fields.Boolean( + related='company_id.invoice_import_create_bank_account', + readonly=False) diff --git a/account_invoice_import/views/res_config_settings.xml b/account_invoice_import/views/res_config_settings.xml index 309dc8004a..5a318758ba 100644 --- a/account_invoice_import/views/res_config_settings.xml +++ b/account_invoice_import/views/res_config_settings.xml @@ -35,6 +35,10 @@