From 390af4f6cb839b18087359dfc55c0620cc3c7ecb Mon Sep 17 00:00:00 2001 From: wan Date: Tue, 3 Sep 2019 13:36:18 +0000 Subject: [PATCH] [REF] account: allow to add steps in onboarding Task 1902206 --- addons/account/models/company.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/addons/account/models/company.py b/addons/account/models/company.py index c4fa06f91a5..e40265d4f64 100644 --- a/addons/account/models/company.py +++ b/addons/account/models/company.py @@ -139,12 +139,19 @@ class ResCompany(models.Model): def get_and_update_account_dashboard_onboarding_state(self): """ This method is called on the controller rendering method and ensures that the animations are displayed only one time. """ - return self.get_and_update_onbarding_state('account_dashboard_onboarding_state', [ + return self.get_and_update_onbarding_state( + 'account_dashboard_onboarding_state', + self.get_account_dashboard_onboarding_steps_states_names() + ) + + def get_account_dashboard_onboarding_steps_states_names(self): + """ Necessary to add/edit steps from other modules (account_winbooks_import in this case). """ + return [ 'base_onboarding_company_state', 'account_setup_bank_data_state', 'account_setup_fy_data_state', 'account_setup_coa_state', - ]) + ] def _check_lock_dates(self, vals): '''Check the lock dates for the current companies. This can't be done in a api.constrains because we need