[FIX] account_statement_import: Ensure the load of the view

In some cases, the loading was not working properly. By adding the require, the JS will wait until it is declared

Fixes #597
This commit is contained in:
Enric Tobella
2023-05-30 23:39:10 +02:00
parent ae69cd3885
commit b5fed9c87a

View File

@@ -4,6 +4,7 @@ odoo.define("account_statement_import.dashboard.kanban", function (require) {
var viewRegistry = require("web.view_registry");
var KanbanView = require("web.KanbanView");
require("account.dashboard.kanban");
var AccountDashboardView = viewRegistry.get("account_dashboard_kanban");
// Value can be undefined on some test scenarios. Avoid an error by checking if it is defined
if (AccountDashboardView !== undefined) {