Thursday, September 7, 2023
6 changes · master
Code cleanup and technical improvements
Odoo is standardizing how dates are handled by replacing the older Moment library with Luxon. This helps reduce loaded assets and simplifies ongoing maintenance without changing core business workflows.
Original PR description
luxon and moment are both used in the solution, but these two libraries facilitate the manipulation of dates. It was decided to replace all uses of moment with luxon so we can then remove moment.js from the code and lighten the assets. task-3391739 PR Ent : https://github.com/odoo/enterprise/pull/46987
This change streamlines how Odoo loads interface templates by replacing older loading functions with a centralized template registry. It should make the platform easier to maintain and reduce complexity across web-based apps, with little direct impact on day-to-day users.
Original PR description
In this commit, the loadXML function has been removed. We use registry with xml_templates to load XML templates for OWL Apps. task-3266441 PR Enterprise : https://github.com/odoo/enterprise/pull/47001
This update simplifies an internal part of the appointment page editor so it can identify nearby page elements more flexibly. It is a behind-the-scenes cleanup that should make future appointment editor changes easier and safer without changing the user experience.
Original PR description
To improve the api, make closestElement take a predicate as an argument. task-2984709
This change streamlines how several Odoo app screens load their interface templates. It is an internal cleanup that should make the web platform easier to maintain without changing day-to-day user workflows.
Original PR description
In this commit, the loadXML function has been removed. We use registry with xml_templates to load XML templates for OWL Apps. task-3266441 PR Community : https://github.com/odoo/odoo/pull/134520
The spreadsheet breadcrumb template was reorganized to remove repeated code. This is an internal cleanup that should make future maintenance easier without changing how users interact with spreadsheets.
Original PR description
This PR refactors `spreadsheet_breadcrumbs.xml` to reduce existing code duplicacy. Task ID : 3424046
The barcode product expiry area now uses one shared date-handling library instead of maintaining duplicate date tools. This internal cleanup helps reduce loaded assets and supports easier maintenance without changing user-facing workflows.
Original PR description
luxon and moment are both used in the solution, but these two libraries facilitate the manipulation of dates. It was decided to replace all uses of moment with luxon so we can then remove moment.js from the code and lighten the assets. task-3391739 PR Com : https://github.com/odoo/odoo/pull/134470