[REF] base,*: fix typo + privatize onboarding method
* = account, sale - Fix typo - Make private as very specific role - Allows to grep similar functionality from new onboarding module and previous common implementation of onboardings. Task-2852375 Part of Task-2900763 Part-of: odoo/odoo#97105
This commit is contained in:
@@ -217,7 +217,7 @@ class ResCompany(models.Model):
|
||||
def get_and_update_account_invoice_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(
|
||||
return self._get_and_update_onboarding_state(
|
||||
'account_invoice_onboarding_state',
|
||||
self.get_account_invoice_onboarding_steps_states_names()
|
||||
)
|
||||
@@ -234,7 +234,7 @@ 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(
|
||||
return self._get_and_update_onboarding_state(
|
||||
'account_dashboard_onboarding_state',
|
||||
self.get_account_dashboard_onboarding_steps_states_names()
|
||||
)
|
||||
|
||||
@@ -130,6 +130,6 @@ class ResCompany(models.Model):
|
||||
'sale_onboarding_order_confirmation_state',
|
||||
'sale_onboarding_sample_quotation_state',
|
||||
]
|
||||
return self.get_and_update_onbarding_state('sale_quotation_onboarding_state', steps)
|
||||
return self._get_and_update_onboarding_state('sale_quotation_onboarding_state', steps)
|
||||
|
||||
_sql_constraints = [('check_quotation_validity_days', 'CHECK(quotation_validity_days > 0)', 'Quotation Validity is required and must be greater than 0.')]
|
||||
|
||||
@@ -287,7 +287,7 @@ class Company(models.Model):
|
||||
if self[step_name] == 'not_done':
|
||||
self[step_name] = 'just_done'
|
||||
|
||||
def get_and_update_onbarding_state(self, onboarding_state, steps_states):
|
||||
def _get_and_update_onboarding_state(self, onboarding_state, steps_states):
|
||||
""" Needed to display onboarding animations only one time. """
|
||||
old_values = {}
|
||||
all_done = True
|
||||
|
||||
Reference in New Issue
Block a user