Sunday, June 9, 2024
1 change · saas-17.1
Miscellaneous changes
Reproduce: * Create a database without demo data * Complete some information related to the main company (i.e. from the database manager form) * Install `account` * In the settings, in debug mode, trigger the installation of the demo data manually Result: The data manually set on the company is overridden to be in US, making the demo data of `account` lose its localized aspect. If for some reason the CoA could not be reloaded, we even don't have any demo at all because `try_loading` won'
Original PR description
Reproduce: * Create a database without demo data * Complete some information related to the main company (i.e. from the database manager form) * Install `account` * In the settings, in debug mode, trigger the installation of the demo data manually Result: The data manually set on the company is overridden to be in US, making the demo data of `account` lose its localized aspect. If for some reason the CoA could not be reloaded, we even don't have any demo at all because `try_loading` won't do anything at all. Solution: Do not override value possibly set by the user in the database configuration. We use the company name as a heuristic. If there is already a chart template installed (because the installation of a `l10n` module triggered it), then we try to load the dynamic demo data when loading the demo XML file. Forward-Port-Of: odoo/odoo#166315