diff --git a/addons/account/wizard/setup_wizards.py b/addons/account/wizard/setup_wizards.py index 31011d55e22..7982ee91f70 100644 --- a/addons/account/wizard/setup_wizards.py +++ b/addons/account/wizard/setup_wizards.py @@ -100,6 +100,8 @@ class SetupBarBankConfigWizard(models.TransientModel): 'company_id': company.id, 'bank_account_id': record.res_partner_bank_id.id, }) + else: + selected_journal.bank_account_id = record.res_partner_bank_id.id def validate(self): """ Called by the validation button of this wizard. Serves as an diff --git a/addons/account_bank_statement_import/wizard/setup_wizards.py b/addons/account_bank_statement_import/wizard/setup_wizards.py index ef811b73029..81ca3b873f1 100644 --- a/addons/account_bank_statement_import/wizard/setup_wizards.py +++ b/addons/account_bank_statement_import/wizard/setup_wizards.py @@ -10,5 +10,5 @@ class SetupBarBankConfigWizard(models.TransientModel): """ Default the bank statement source of new bank journals as 'file_import' """ super(SetupBarBankConfigWizard, self).validate() - if self.create_or_link_option == 'new': + if self.create_or_link_option == 'new' or self.linked_journal_id.bank_statements_source == 'undefined': self.linked_journal_id.bank_statements_source = 'file_import'