b4fdc6c01de4fd7987dde96d335e9f35d1119952
Before this commit, this flow was broken: - Install website - Create a new website of your own (not using the one created automatically from XML data) - Choose another color palette for that website - Uninstall the website app - Reinstall the website app - Try to choose another color palette for any website => It does not work Indeed, after the uninstallation, the DB is left in an invalid state: the SCSS customizations attachments of the website that was created by the user are not removed, they just have their website_id field emptied. Some code made at [1] was already there to remove those attachments. The problem is that it only worked for websites which were created by XML data (at website installation), not by the user. Indeed, the `unlink` method is not called during uninstallation to remove records that were created by the user, thus the `unlink` override was not called either. See [2] for some details. This fixes the issues by moving this attachment cleaning code in a dedicated method, called in `unlink` but also in the `uninstall_hook` of the website app. This also takes the opportunity to refactor the code involved, in particular to not even consider customized attachments which do not have a website_id. [1]: https://github.com/odoo/odoo/commit/2f361bec36dff09181b96d140d62c477cdf013a1 [2]: https://github.com/odoo/odoo/pull/97852#pullrequestreview-1067851656 opw-3127531 closes odoo/odoo#110338 X-original-commit: 988eafa03b57be3b3a7f110650c61ce8fda88e31 Signed-off-by: Romain Derie (rde) <rde@odoo.com>
…
Odoo
Odoo is a suite of web based open source business apps.
The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...
Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.
Getting started with Odoo
For a standard installation please follow the Setup instructions from the documentation.
To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%