bank-statement-import icon indicating copy to clipboard operation
bank-statement-import copied to clipboard

[19.0][MIG] account_statement_import_online: Migration to 19.0

Open mkoeck opened this issue 1 month ago • 1 comments

This PR ports the account_statement_import_online module to Odoo 19.0 and adapts it to framework and data model changes introduced in this version. It focuses on keeping the functional behavior unchanged while aligning with new conventions and APIs.

Changes

Menu & UI

  • Move the online_bank_statement_provider_menu under account.account_account_menu, since account.account_banks_menu no longer exists in Odoo 19.

Security & Actions

  • Update groups_id to group_ids on action_online_bank_statements_pull_wizard, reflecting the field rename in Odoo 19.

Tests

  • Remove the odoo_test_helper dependency in unit tests and use the newly introduced add_to_registry helper instead.
  • Manually create a suspense_account for the bank journal in tests, as a default suspense account is no longer provided due to changes in the demo data loading order (required to create bank.statement.line records).

Code Quality & API Updates

  • Replace imports of _ with self.env._ in line with pylint recommendations.
  • Fix string interpolations that did not follow Odoo/Python best practices.
  • Replace self.env.context.get("tz") occurrences with self.env.tz.
  • Migrate _sql_constraints definitions to models.Constraint to follow the new ORM API in Odoo 19.

mkoeck avatar Dec 02 '25 09:12 mkoeck

Ah sorry I just noticed that the commit 5ee5f16 slipped through which is from another pull request. Need to remove that one.

mkoeck avatar Dec 02 '25 09:12 mkoeck