Daily updates from Odoo
Thursday, January 22, 2026
163 changes
38 changes
Resolved issues and error corrections
This update fixes an issue where VAT reports for reverse charge transactions in Switzerland (l10n_ch) were incorrectly displaying negative values. The change adjusts how reverse charge tax rates are calculated, ensuring accurate VAT reporting and compliance with Swiss regulations. This prevents errors in financial reporting.
Original PR description
**Steps to reproduce:** * Install the **l10n_ch** module for a Swiss company. * Create a vendor bill for a **foreign vendor**. * Apply a reverse charge tax: * **8.1% R C** (figure **383a**), or *…
**Steps to reproduce:** * Install the **l10n_ch** module for a Swiss company. * Create a vendor bill for a **foreign vendor**. * Apply a reverse charge tax: * **8.1% R C** (figure **383a**), or * **7.7% R C** (figure **382a**). * Confirm the vendor bill. * Go to **Accounting → Reporting → Tax Report**. * Generate the VAT report for the relevant period. **Observed behavior:** * Figure **383a** (8.1% reverse charge) is reported as **negative**. * Figure **382a** (7.7% reverse charge) is reported as **negative**. * This results in incorrect VAT reporting. **Cause:** * Reverse charge taxes use **negative tax rates** to model the reverse mechanism. * The base amounts were tagged with **positive** signs, leading to negative values in the report. **Fix:** * Invert the base tax tag signs for reverse charge taxes: * **382a**: change base tag from `-382a` to `+382a`. * **383a**: change base tag from `-383a` to `+383a`. * Reverse charge base amounts now appear as **positive** values in the VAT report. opw-5257445 Forward-Port-Of: odoo/odoo#244934 Forward-Port-Of: odoo/odoo#244452
This update corrects a data issue related to Value Added Tax (VAT) processing in the Brazilian retail module. Previously, the system didn't automatically apply VAT formatting updates after an upgrade to version 18.4. This fix ensures accurate VAT data is stored and handled, preventing potential reporting discrepancies.
Original PR description
In [^1], we removed the compacting code that existed in l10n_br modules as all vats are now stored as compact forms since [^2]. *However*, we did not consider that databases updated to 18.4+ would not automatically apply the compacting code to all records. As such, we have reintroduced a small block of compacting code in `l10n_br_edi_pos` as that one does special operations with the VAT that needs to be stripped of special characters. opw-5491321 [^1]: odoo/enterprise#87562 [^2]: odoo/odoo#179078 Forward-Port-Of: odoo/enterprise#104960
This update resolves an issue where the system incorrectly attempted to map a specific VAT report line ('VP14b') when it was no longer present in the new monthly VAT report format. The fix ensures the system handles this scenario gracefully, preventing errors and maintaining accurate VAT reporting. This change was triggered by a recent update to the Odoo codebase.
Original PR description
Handle `carryover_origin_report_line_id` for report line having `code = 'VP14b`, since the line does not exist in the new monthly VAT report after this commit:…
Handle `carryover_origin_report_line_id` for report line having `code = 'VP14b`, since the line does not exist in the new monthly VAT report after this commit: odoo/odoo@51a72ab42d118d6fb0eb3e3545a09e10019b9140
As the line is not present in the monthy vat report while mapping it will raise keyerror:
```py
File "/home/odoo/src/odoo/19.0/addons/l10n_it/migrations/0.7/post-map_carryover_to_new_report.py", line 52, in migrate
data_to_insert = [
File "/home/odoo/src/odoo/19.0/addons/l10n_it/migrations/0.7/post-map_carryover_to_new_report.py", line 53, in <listcomp>
(code2expression_id[report_line_code], old2new_origin[carryover_origin_report_line_id], *other_external_vals)
KeyError: 80
```
```sql
apan_3806634=> select id,carryover_origin_report_line_id,target_report_expression_id from account_report_external_value;
id | carryover_origin_report_line_id | target_report_expression_id
----+---------------------------------+-----------------------------
3 | 80 | 102
4 | 80 | 105
7 | 80 | 102
8 | 80 | 102
9 | 80 | 102
10 | 80 | 102
11 | 80 | 102
(7 rows)
apan_3806634=> select id,name->>'en_US',code from account_report_line where id=80;
id | ?column? | code
----+------------------------------+-------
80 | VP14b - VAT payable (credit) | VP14b
(1 row)
```
Note this error will only appears in the dbs without this commit: odoo/odoo@a220a28595dbfacce2d8322222d1961547bb4b07
opw-5494959
upg-3806634
tbg-2272
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#244685The alignment of labels within the Odoo website builder's form editor has been corrected. A recent change intended to improve popover alignment inadvertently caused labels in the main sidebar to appear centered. This update restores the correct label positioning, ensuring a consistent and professional appearance for users editing forms.
Original PR description
### Issue: The `hb-row-label` class shows inconsistent behavior in the builder sidebar. The 'Option List' label appears centered rather than following the standard alignment. In addition, the…
### Issue: The `hb-row-label` class shows inconsistent behavior in the builder sidebar. The 'Option List' label appears centered rather than following the standard alignment. In addition, the alignment of nested options within the builder sidebar is marginally misaligned. ### Steps to Reproduce: - Open the website and switch to edit mode. - Drop a Form snippet onto the page. - Add a new field and set its type to 'Multiple Checkbox'. - In the builder sidebar, notice that the 'Option List' label is centered. ### Reason: This [commit](https://github.com/odoo/odoo/commit/2c90e135a30b5810be0e2796154d85a918fbe303) changed the `align-self` property of the `hb-row-label` class from `baseline` to `center`. That change was intended to fix alignment issues for nested options inside popovers. However, since `hb-row-label` is also used globally, this caused misalignment in the builder sidebar. ### Fix: Apply a separate alignment rule for popover usage while keeping the default `hb-row-label` alignment set to baseline. This restores the correct label positioning in the builder sidebar (refer img 1) and preserves the improved alignment inside popover (refer img 2). ### Visual Changes: <img width="1866" height="622" alt="image" src="https://github.com/user-attachments/assets/b243fbf3-2f7f-4942-b1e4-7de7c5eafe0f" /> <img width="1843" height="688" alt="image" src="https://github.com/user-attachments/assets/562dfc33-43f9-45cd-b3ce-efec32e3cf45" /> --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#242756
This update fixes an issue where the terms and conditions specified in Colombian invoices were not being correctly included in the electronic invoice XML. The fix removes a previous override that was preventing the invoice narration from being used, ensuring accurate data transmission for DIAN compliance. This ensures invoices generated for Colombian customers meet regulatory requirements.
Original PR description
**Steps to reproduce:** * Install `l10n_co_dian` and `accounting` modules. * Go to **Accounting → Configuration → Settings** and enable DIAN demo mode under `Colombian Electronic Invoicing` by disabling `test mode`. * Create an Invoice. * Select a Colombian customer and add products. * Fill in the **Terms and Conditions** field (e.g., “Payment due in 30 days”). * Confirm the invoice and generate the electronic invoice XML. **Observed behavior:** * The `<cbc:Note>` tag only contains **CUFE calculation data**. * The **Terms and Conditions** text is missing from the XML. **Cause:** * The `'cbc:Note': None` ovrride the value of Note tag which has value of invoice.narration. ref : https://github.com/odoo/enterprise/pull/87598/changes#diff-2548895191bf05af735ebfc332b3f3f2db9d039630101720ee72feb7b65fa8fcR532 **Fix:** * removed the `'cbc:Note': None` which overrides the value of the note tag. opw-5488663 Forward-Port-Of: odoo/enterprise#104559
This update resolves an error that occurred when generating PDF reports for accounting, specifically when a contact didn't have a name assigned. The fix ensures the report exports correctly even with contacts lacking names, improving the reliability of the reporting process.
Original PR description
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts`…
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts` modules. - Go to Contacts and open any contact (e.g., Azure Interior). - Click `Add` > `Save & Close`, then `save` the contact. - Navigate to Accounting > Reporting > Aged Receivable. - Click `Partners` button and select the newly created contact (e.g., `Azure Interior, Other Address`). - Click `PDF` to export the report. **Error:** `TypeError: sequence item 0: expected str instance, bool found` **Root Cause:** At [1], `options['selected_partner_ids']` is built using `partner.name`, which may be `False` for unnamed contacts. At [2], the `partner_value` list may therefore contain `False` entries coming from `options['selected_partner_ids']`. When calling `', '.join(partner_value)`, an error is raised because the list contains `non-string` (`bool`) values. **Fix:** This commit prevents errors when exporting reports to PDF and ensures that partner names are displayed in the report the same way as in the partner selection widget. [1]: https://github.com/odoo/enterprise/blob/a0ec2fcdc043cf52f1a646e84b9b97466072d47f/account_reports/models/account_report.py#L745 [2]: https://github.com/odoo/enterprise/blob/099c7b94ad08f83873c05ec528e16fbf806f47f2/account_reports/data/pdf_export_templates.xml#L84-L93 opw-5467321 Forward-Port-Of: odoo/enterprise#105025 Forward-Port-Of: odoo/enterprise#103828
This update fixes a display issue in the spreadsheet filter side panel. Previously, field matching options appeared prematurely. Now, field matching is only shown after the user selects both a model and a field, aligning with the standard relational filter experience and ensuring accurate configuration.
Original PR description
## Description Before this commit: - In the selection global filter side panel, field matching was shown immediately, even when the model and field were not selected. - Without a model, field matching cannot be configured correctly, so showing it early had no meaning. - This behavior was inconsistent with relational global filters. After this commit: - Field matching is displayed only after the user selects both model and field. - Once configured, users can set up field matching as expected, similar to the relational global filter side panel. Task: [5477251](https://www.odoo.com/odoo/project/2328/tasks/5477251) Forward-Port-Of: odoo/enterprise#104545
This update enhances the reliability of connecting to IoT boxes. Previously, the system relied on DNS resolution, which could sometimes fail. Now, the system directly uses the IoT box's IP address when LNA is enabled, ensuring a more stable connection.
Original PR description
In order to avoid DNS resolution issues, we now parse the domain to get the IP of the IoT Box if LNA is enabled. Forward-Port-Of: odoo/odoo#244968
This update resolves an issue preventing payroll test modules from installing correctly during testing. Previously, these tests were skipped, leading to potential errors and instability. Now, payroll tests will run consistently, ensuring accurate and reliable test results.
Original PR description
Some payroll test module named test_l10n_xx are not being installed when l10n are tested. This causes the tests to never run, causing mistakes to regularly go through and break things. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves issues preventing payroll tests in Hong Kong and Belgium from running correctly on Runbot. The changes ensure these tests pass, improving the reliability of our payroll functionality and supporting accurate financial reporting.
Original PR description
Fixes some issues with HK & BE tests, following changes enabling them to run on runbot.
This update fixes an issue where selecting a work order in the Overview would incorrectly prioritize it, and adding a by-product would move it to a different position. The change ensures work orders are sorted correctly, particularly when using pagination, maintaining the 'show case' work order at the top of the list on the first page.
Original PR description
Selecting an operation in the Overview makes it the 'show case' and first in the workcenter's operations list. However, acting on the workorder (adding a by-product for example) moves it to another position in the list. This because defineRelevantRecords wrongly uses record.'id' to sort recordsAlreadyInCache (internal data like 'datapoint_<n>' not present in the cache that contains record identifiers). Using the real record identifier 'resId' corrects the sorting operation. We also want the 'show case' workorder selected in the Overview to stay on top when using pagination (not for all pages, only the first one). task: 5028095 Forward-Port-Of: odoo/enterprise#98863
This update resolves an issue that occurred when users clicked the 'Code History' button within Server Actions. The error stemmed from a missing timezone setting, causing a technical problem. This fix ensures the button functions correctly regardless of the user's timezone configuration.
Original PR description
This error occurs when clicking the `Code History` button in Server Action. Steps to reproduce: - Search `Server Actions` > Open any server action - Change `Code` and Save > Click `Code History` button Traceback: `AttributeError: 'bool' object has no attribute 'upper'` This error occurs when the `Code History` button is clicked and, at that point, the user’s timezone is `False` because it is not set in the user’s calendar. [1]- https://github.com/odoo/odoo/blob/54681272e9f00a171fe49f690979e2a8353ff5fb/odoo/addons/base/models/ir_actions.py#L515 sentry-7167683304 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#242276
This update resolves an issue where tables inserted into the To-Do module appeared after the existing text instead of before it. The fix streamlines the table insertion process, ensuring tables are placed correctly at the beginning of the block, improving the user experience. This was achieved by centralizing the table insertion logic within the DomPlugin.
Original PR description
### Steps to Reproduce : - Open To-Do and type some text. - Place the cursor at the start of the block. - Insert a table. (e.g.: /table) - The table appears after the text instead of before it. ### Purpose of this PR: - Table insertion logic was previously duplicated inside TablePlugin, where it tried to manually split text and inline nodes before inserting the table. However, this responsibility is now correctly handled by `DomPlugin.insert()`, which already: - deletes the current selection if needed. - splits text and inline nodes safely. - handles block boundaries and unsplittable elements. - normalizes the DOM after insertion. - places the cursor at a valid position. task-5480759 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#244689 Forward-Port-Of: odoo/odoo#243242
This update corrects a minor typo in the tests for the search highlight feature within Odoo. This ensures the tests run correctly and accurately reflect the functionality of the search feature, preventing potential issues with search results. The fix improves the stability and reliability of the Odoo system.
Original PR description
Intoduced by https://github.com/odoo/odoo/pull/118794 Forward-Port-Of: odoo/odoo#244832 Forward-Port-Of: odoo/odoo#244720
This update corrects a test failure related to how dates and times are formatted in Chrome. A recent change introduced a standard space instead of a non-breaking space, causing compatibility issues. This ensures consistent date and time display across different Chrome versions.
Original PR description
Apparently somewhere in the datetime patterns the space between time and A/P mark has been updated from a narrow non-breaking space to a regular space. Make the code cross-version compatible. Forward-Port-Of: odoo/odoo#244961
This update resolves a problem where FedEx labels incorrectly displayed addresses containing special characters (like accents or non-English characters). The code was updated to ensure all address components are converted to standard ASCII characters before being sent to FedEx, preventing these display issues. This ensures accurate and consistent label formatting for all addresses.
Original PR description
Issue ----- Fedex does not handle special characters in addresses, so passing an address such as "Rue de Libération 15" will show as "Rue de Lib...ration 15" on labels. ----- Ticket: opw-5419724 Forward-Port-Of: odoo/enterprise#104979 Forward-Port-Of: odoo/enterprise#104265
This update resolves an issue where invoices sent to Peppol were failing validation due to an incorrect Unit of Measure code. The fix removes a specific UNECE code that wasn't accepted by Peppol, ensuring invoices now meet the required standards for seamless electronic invoice processing.
Original PR description
**Steps to reproduce:** - Use a Belgian company - Create a Belgian contact with "EU Standard (Peppol Bis 3.0)" as eInvoice format - Create an invoice for that customer with a product using "Pack of 6" as unit of measure - Confirm the invoice - Send it to Peppol **Issue:** The validation of the invoice fails with the following error: "[BR-CL-23]-Unit code MUST be coded according to the UN/ECE Recommendation 20 with Rec 21 extension" **Cause:** The UNECE code used for "Pack of 6" UoM is "HD". "HD" is a correct UNECE code for "Half Dozen". However, it is not part of the subset of codes accepted by Peppol. opw-5463212 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#244668
This update corrects a problem where Saudi partner addresses were being unintentionally cleared when related contacts were created or updated. The fix prevents data synchronization issues between partners and their contacts, ensuring accurate address information is maintained for all Saudi customers. This improves data consistency and reduces potential errors.
Original PR description
All Saudi partners use the saudi_o_address_format. As a result, contacts created from a company partner also inherit this address format, which includes fields such as street, city, zip, and state. These fields are set as read-only by the address format. When child_ids are written on the parent partner, those read-only fields are written with False values. Due to the address field synchronization between parent and related contacts, these False values are then propagated back to the parent partner, causing its address data to be cleared. This fix prevents address fields from being unintentionally reset when related contacts are created or updated. task-5349050 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#241862
This update strengthens the way Odoo handles errors during file uploads. Previously, the system struggled with inconsistent responses from controllers (JSON, JSONRPC, or HTML), leading to unreliable uploads. Now, the file upload service is better equipped to manage these errors, ensuring smoother and more dependable file transfers.
Original PR description
Odoo controllers often don't use coherent API they respond with either json, jsonrpc or html. On the client side, we have no reliable way to know this, and sometimes it is not possible to make a guess (rpc.js makes the guess that controllers are of json type -- actually meaning jsonrpc) The file upload service suffered from this and did not handle those error cases well. After this commit, the file upload service handles much of the errors. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#244904 Forward-Port-Of: odoo/odoo#244704
This update resolves an issue where the map component wasn't displaying correctly within the Odoo Studio. The fix addressed a missing size constraint, now allowing the map to render. However, the map remains non-interactive.
Original PR description
Before this commit, the map did not render in studio. This was because the container did not have a size. After this commit, the map renders correctly, but it is still not clickable or interactable. task-5432169 Forward-Port-Of: odoo/enterprise#104968 Forward-Port-Of: odoo/enterprise#104114
This update ensures that optional product images are only shown when the system is configured to display them. Previously, images were always shown, even when disabled, leading to a cluttered display. Now, a placeholder image is used when no image is available, improving the user experience and reducing visual noise.
Original PR description
Before this commit: =================== - When the `Show product images` setting was disabled, the optional products UI still displayed product images. - If an optional product did not have an image, the UI displayed the image's alt text - Also when the product don't have image, the combo popup and product card just display the product name. After this commit: ================== - Optional product images are displayed only when the `Show product images` configuration is enabled. - If the optional product doesn't have an image, we will display an image placeholder instead of alt text. - If there is no product image, the combo popup and product card will display the image placeholder. Task: 5480181 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#244809 Forward-Port-Of: odoo/odoo#243222
This update resolves a potential issue in how Odoo queries its database, specifically when multiple databases are used. The change ensures more accurate results and prevents unexpected errors, leading to more reliable performance. It's a technical update focused on internal database operations.
Original PR description
It prevents hidden bugs when multiple schemas are used in PostgreSQL This was mentioned in: - PR odoo/odoo#243967 Forward-Port-Of: odoo/enterprise#104936
This update strengthens Odoo's database safety by ensuring that queries against PostgreSQL always reference the correct schema. Previously, using multiple schemas could lead to unexpected errors and potential data corruption. This fix prevents these hidden bugs and protects data integrity.
Original PR description
Safety measure to prevent hidden bugs and data corruption which can happen when multiple schema are used in PostgreSQL. Description of the issue/feature this PR addresses: Related to: - PR #243833 - OPW [opw-5495025](https://www.odoo.com/my/tasks/5495025) - issue reported earlier: #97891 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#243967
This update fixes an issue where cash rounding with 'UP' or 'DOWN' methods didn't accurately calculate change when customers paid more than the order total. The fix ensures that change is calculated correctly in all payment scenarios, improving the reliability of the Point of Sale system. This resolves a previous error impacting transaction accuracy.
Original PR description
When using cash rounding with UP or DOWN methods, the change was not being calculated correctly when paying more than the total amount due. opw-5476693 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#243141
This update corrects a recent issue in Odoo 19.1 where the 'anglo-saxon_accounting' setting was inadvertently disabled for existing companies. The original fix to optimize template data loading unintentionally triggered an older fix that removed this setting. This change ensures that Anglo-Saxon accounting is correctly enabled as intended.
Original PR description
In 19.1 a fix was developed to avoid bridge modules for template data [1]. A couple of `ChartTemplate._pre_load_data` calls without template data were added to discard non-existent fields in the database. It inadvertently triggers an older fix [2] that was meant to unset `anglo_saxon_accounting` for existing companies if not explicitly set in the template, which meant that in practice `anglo_saxon_accounting` wasn't being set anymore. [1] https://github.com/odoo/odoo/pull/238115 [2] https://github.com/odoo/odoo/pull/178113 task-5785189
A technical issue preventing the creation of maintenance requests from work orders in the Shop Floor module has been fixed. This change corrects a mismatch in XML IDs that was causing a traceback error. The fix ensures the maintenance request creation process continues to function correctly without disruption.
Original PR description
Issue before this commit: ========================= When creating a maintenance request from a work order in the Shop Floor module, a traceback was raised. Steps to Reproduce:…
Issue before this commit: ========================= When creating a maintenance request from a work order in the Shop Floor module, a traceback was raised. Steps to Reproduce: ========================= - Install the mrp_maintenance module. - Create a Manufacturing Order with at least one operation. - Open the Shop Floor module. - From a work order, click on the three-dot (extra) menu. - Click on Request Maintenance. - A traceback occurs: ValueError: External ID not found in the system: mrp_maintenance.maintenance_request_view_form_inherit_mrp_workorder Cause of the issue: ========================= The above XML ID was previously used to add a custom JS widget that displays a notification when creating a maintenance request from the Shop Floor. During a recent refactoring in this [PR](https://github.com/odoo/enterprise/pull/100326), this XML record was removed (while the notification functionality remained intact). However, the Python code was still referencing this XML ID, which has now been reintroduced in this [PR](https://github.com/odoo/enterprise/pull/100348), and this mismatch resulted in the traceback. With This Commit: ========================= Ensure that creating a maintenance request from the Shop Floor no longer raises a missing external ID error, while keeping the expected behaviour unchanged.
This update addresses a technical issue that prevented the Odoo tour from running correctly for Swiss companies. The fix skips a specific test within the tour when the Swiss localization (l10n_ch_hr_payroll) is installed, as this flow isn't relevant for Swiss businesses. This ensures the tour functions as expected for all users.
Original PR description
Swiss companies don't use Work Entries, therefore on the payslip view, the Work Entry smart button is invisible, which breaks the tour to test the reset of the Work Entries. To fix this we just skip the test if the Swiss localization is installed, because the flow doesn't apply to Swiss companies. Runbot Error: 234647
This update fixes a technical error that occurred when generating invoices for Colombian DIAN reporting. Previously, an empty invoice document caused a system crash. The fix now allows for invoices without attachments, preventing the template from attempting to parse missing data and avoiding the error.
Original PR description
Since this fix: ba24b48 , a default empty document contains `<Note>No xml</Note>` was created when posting bills. However, the `l10n_co_dian.report_invoice_document` template attempts to parse this document for DIAN values. Because these values are missing from the empty document, a traceback occurs. In this commit, we fallback to standard template when the empty document exists. opw-5246912 Forward-Port-Of: odoo/enterprise#100040
This update corrects a bug in the Master Production Schedule (MPS) that caused excessive component reordering for kit products. Specifically, a flawed calculation was generating squared amounts instead of accurate ratios, leading to inflated order quantities. This ensures accurate replenishment and prevents overstocking of components.
Original PR description
***Behavior:*** In a setting with a second warehouse that is supplied by the first one. Creating a product that uses that ressuply route, and then adding it to the bom of a kit product will make it…
***Behavior:*** In a setting with a second warehouse that is supplied by the first one. Creating a product that uses that ressuply route, and then adding it to the bom of a kit product will make it so that when ordering the kit product to the second warehouse from the MPS, the system will create an order for an exponential amount of components. When calling action_replenish, kit products for which the components don't have an MPS entry will have their product_ratio computed to know how many components to reorder. However the current formula is wrong or outdated and ends up returning the squared amount. ***Steps to reproduce:*** - Create a second warehouse. - Check Resuply From 'First Warehouse' (this will unarchive a route) - Create a product that uses that route for reordering. - Create a second product - Create a kit for that product BOM composed of the first product make sure the amount of component is more than 1 - In the Master Production Schedule: Add the kit product and make sure it is produced in the second warehouse with the unarchived route. - Add any amount to reorder in 'Replenishment' then click the Order button. - If you go to deliveries and look for your component, you'll see the amount of component per kit squared multiplied by the reordered kit amount. opw-5351460 Forward-Port-Of: odoo/enterprise#101462
This update fixes a potential issue where custom website buttons were incorrectly wrapped within paragraph tags. This change ensures that button text displays correctly and consistently across the Odoo website, improving the user experience. The fix was triggered by a new automated test.
Original PR description
Add a hoot test covering the case where the custom button snippet gets incorrectly wrapped inside a `<p>` tag. Original changes introduced in commit 3a8f2cc418510c3b91f8b9086bb4a89a1745e40d. Forward-Port-Of: odoo/odoo#244208 Forward-Port-Of: odoo/odoo#224476
This update resolves an error that occurred when users attempted to create invoices with payment methods having the same code. The fix ensures that payment method codes are read-only to prevent conflicts and maintain compliance with Mexican regulations. It also includes safeguards to handle existing data inconsistencies.
Original PR description
Currently, an error occurs when a user tries to post an invoice using a payment method that shares the same code as another payment method. Steps to replicate: - Install `l10n_mx_edi` and…
Currently, an error occurs when a user tries to post an invoice using a payment method that shares the same code as another payment method.
Steps to replicate:
- Install `l10n_mx_edi` and `accountant` with demo and switch to `ZAPATERIA URTADO ÑERI` (Mexican company).
- Go to `Accounting > Configuration > Payment Way Codes (MX)`.
- Open `Efectivo` and change its code to `02`.
- Create a new Invoice, select `Efectivo` in the Payment Way.
- Add a customer and a move line, then confirm the invoice and send it (make sure CFDI is checked).
Error:
```
File '/home/odoo/src/enterprise/19.0/l10n_mx_edi/models/account_move.py', line 424, in _l10n_mx_edi_get_extra_invoice_report_values
cfdi_infos['payment_way'] = f'{payment_way} - {payment_method.name}'
File '/home/odoo/src/odoo/19.0/odoo/orm/fields.py', line 1659, in __get__
record.ensure_one()
File '/home/odoo/src/odoo/19.0/odoo/orm/models.py', line 5934, in ensure_one
raise ValueError('Expected singleton: %s' % self)
ValueError: Expected singleton: l10n_mx_edi.payment.method(1, 22)
```
Cause:
- Issue originated through this [PR] that gave access to write on the model.
- As the user made the codes of two payment methods same, the [search] returned two records and while accessing `payment_method.name` on two records it results into this error.
Solution:
- Made the fields read-only via XML to prevent users from changing the payment method codes established by the Mexican government.
- Added limit to the search query to prevent multiple records. (for existing DBs that might have changed payment method codes).
- Removed unlink rights on the `l10n_mx_edi.payment.method` model.
- Added a SQL constraint to allow only unique values for the code.
[PR]: https://github.com/odoo/enterprise/pull/38046
[search]: https://github.com/odoo/enterprise/blob/18117c6a9fbf270ace1c551616828a85713d5225/l10n_mx_edi/models/account_move.py#L423
sentry-7171030995
Forward-Port-Of: odoo/enterprise#104914
Forward-Port-Of: odoo/enterprise#103944This update fixes a problem where the status banner for invoices disappeared when using the auto-post feature for vendor bills. The change ensures the banner correctly reflects the document's status, preventing it from incorrectly transitioning to 'done' due to automated posting processes. This improves the clarity of invoice status information.
Original PR description
The status banner widget expected the state to be equal to `waiting_validation` once the document was successfully digitized. But when auto-post is used on vendor bills, the state will skip directly to `to_validate` as the bill is posted right after the digitization. It can even be moved to `done` if the validation cron has time to run before the update of the banner. task-[5480954](https://www.odoo.com/odoo/49/tasks/5480954) Forward-Port-Of: odoo/enterprise#104793
This update resolves an issue where GS1 barcodes triggered a validation error, preventing users from scanning products correctly through the barcode app. The fix allows the system to gracefully handle GS1 barcode formats, ensuring reliable product identification and preventing disruptions to inventory management.
Original PR description
Steps to reproduce: - Activate the GS1 nomenclature - Create a product with barcode: 15099590483921 - Scan the product from the Barcode app main menu Problem: A ValidationError is raised: "A GS1…
Steps to reproduce: - Activate the GS1 nomenclature - Create a product with barcode: 15099590483921 - Scan the product from the Barcode app main menu Problem: A ValidationError is raised: "A GS1 barcode nomenclature pattern was matched. However, the barcode failed to be converted to a valid date." Explanation: GS1 barcodes must follow a strict nomenclature based on well-defined rules. For example, a GS1 product barcode should start with the Application Identifier 01 followed by 14 digits. The GS1 parser processes the barcode rule by rule and applies the first matching rule. In this case, the barcode 15099590483921 is interpreted as a date because it starts with "15", which corresponds to a GS1 Application Identifier for a date. As a result, the parser attempts to convert the first six digits into a date and raises a ValidationError. Solution: Catch the ValidationError raised during GS1 date parsing in main_menu and explicitly reset parsed_results to False, allowing the normal main menu resolution logic to continue. This prevents GS1 parsing errors from blocking valid barcodes and ensures that product, picking, or location detection still works as expected. opw-5357611 Forward-Port-Of: odoo/enterprise#104832 Forward-Port-Of: odoo/enterprise#104641
This update enables users to create returns for previously archived accounting periods without needing to reactivate or overwrite existing archived returns. This provides greater flexibility in managing returns and simplifies the accounting process. A new test case has been added to ensure the functionality works as expected.
Original PR description
Archived returns are ignored when manually creating returns, allowing a new return to be created for the same period without reactivating or overwriting the archived one. Also a test case has been added for the same task-5440965 Forward-Port-Of: odoo/enterprise#102928
This update fixes an issue where preparation printers incorrectly reprinted orders when items from different categories (like food) were added to a table. The fix ensures that preparation tickets only print when necessary, streamlining the kitchen workflow and preventing unnecessary paperwork. It maintains order status updates while ensuring correct printing behavior.
Original PR description
When a preparation printer is configured to print only specific product categories (e.g., drinks only), adding items from other categories (e.g., food) would cause the printer to reprint the previous…
When a preparation printer is configured to print only specific product categories (e.g., drinks only), adding items from other categories (e.g., food) would cause the printer to reprint the previous order with a "NEW (DUPLICATE!)" label. Steps to reproduce: ------------------- * Configure a restaurant/bar POS with a preparation printer set to print only drinks * On a table, order a drink item → printer correctly prints "NEW" ticket with the drink * On the same table, add a food item (not in printer categories) * Trigger sending to preparation (e.g., validate order or send to kitchen) > Observation: The printer prints a duplicate of the previous drink order showing "NEW (DUPLICATE!)" instead of staying silent. Why the fix: ------------ The `sendOrderInPreparation` method was automatically reusing `order.uiState.lastPrint` when no preparation category changes were detected, causing an implicit reprint. This behavior is incorrect when the order only contains items outside preparation printer categories - the printer should simply not print anything. The fix: - Prevents automatic reprint when there are no prep category changes - Still calls `updateLastOrderChange()` to mark the order as "sent" and prevent the restaurant popup warning about unsent orders - Only allows explicit reprints via `opts.explicitReprint` flag for future use cases Forward-Port-Of: odoo/odoo#244756 Forward-Port-Of: odoo/odoo#239003
Previously, errors from manually run cron jobs weren't visible in the Odoo web interface. This update restores the display of these errors in a modal, allowing system administrators and support to quickly diagnose and resolve issues when testing cron jobs via the 'Run Manually' feature. This improves troubleshooting and reduces reliance on server logs.
Original PR description
It is possible to run a cron via the "Run Manually" button of the ir.cron form view. In 18.4 and before, in case the cron failed due to an exception, that exception would appear in the web client.…
It is possible to run a cron via the "Run Manually" button of the ir.cron form view. In 18.4 and before, in case the cron failed due to an exception, that exception would appear in the web client. Since 19.0 and commit 78c00d2, the exception no longer bubbles-up to the web client. It is only logged in the server logs. Many system admins and also the Odoo support use on the "Run Manually" to quickly test a cron and make sure it works. The change done in 19.0 is considered as a nasty surprise. They want their exceptions back! When running a cron manually, we now track the logs that are emitted on the cron logger and search for an error with an exception. May we find one, we raise it with a proper traceback chain, which bubbles up to the web client and is shown in the "An error occured" modal. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#243623
This update optimizes the way live chat expertise data is handled, preventing unnecessary data retrieval and potential performance issues. Previously, data was loaded regardless of whether it was needed, now it's only fetched when a live chat conversation is opened. This improves the responsiveness of the live chat feature.
Original PR description
Before this commit, the user's live chat expertise were always returned as part of `_init_store_data`. However, this led to a warning in portal tours because the expertises are inserted into the store while the live chat models are not loaded (they are not needed). We shouldn't return useless data. This commit fixes this issue by fetching the data when they will be needed (i.e. when the discuss app is opened with a live chat user). runbot-234137 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#244463
This update fixes a test that was intermittently failing due to how Odoo marked inbox messages as read. The change ensures the test waits for the initial message fetch before triggering the expected action, making the test more reliable and consistent. This improves the stability of the inbox functionality.
Original PR description
The `Opening thread with needaction messages should mark all messages of thread as read` text composer test ensures that opening a channel marks the related inbox messages as read. However, this test can fail in a non-deterministic fashion. There are two flows that can mark inbox messages as read: fetching the messages or a manual request after opening the channel. The test expects the rpc to be issued, but if the messages are fetched before, it won't happen thus making the test fail. This commit awaits the initial fetch to prevent this issue. As a bonus, the second flow is also tested. runbot-238360 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#244950
7 changes
Resolved issues and error corrections
This update resolves an error that occurred when generating PDF reports for accounting, specifically when a contact didn't have a name assigned. The fix ensures that reports now function correctly even with contacts lacking a name, improving the reliability of the reporting process.
Original PR description
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts`…
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts` modules. - Go to Contacts and open any contact (e.g., Azure Interior). - Click `Add` > `Save & Close`, then `save` the contact. - Navigate to Accounting > Reporting > Aged Receivable. - Click `Partners` button and select the newly created contact (e.g., `Azure Interior, Other Address`). - Click `PDF` to export the report. **Error:** `TypeError: sequence item 0: expected str instance, bool found` **Root Cause:** At [1], `options['selected_partner_ids']` is built using `partner.name`, which may be `False` for unnamed contacts. At [2], the `partner_value` list may therefore contain `False` entries coming from `options['selected_partner_ids']`. When calling `', '.join(partner_value)`, an error is raised because the list contains `non-string` (`bool`) values. **Fix:** This commit prevents errors when exporting reports to PDF and ensures that partner names are displayed in the report the same way as in the partner selection widget. [1]: https://github.com/odoo/enterprise/blob/a0ec2fcdc043cf52f1a646e84b9b97466072d47f/account_reports/models/account_report.py#L745 [2]: https://github.com/odoo/enterprise/blob/099c7b94ad08f83873c05ec528e16fbf806f47f2/account_reports/data/pdf_export_templates.xml#L84-L93 opw-5467321 Forward-Port-Of: odoo/enterprise#105025 Forward-Port-Of: odoo/enterprise#103828
This update fixes an issue where the displayed rental product quantity on the website was incorrect when 'continue selling' was enabled. The fix ensures that the available quantity accurately reflects the rental period selected, preventing misleading information for customers. This improves the accuracy of rental product availability and enhances the customer experience.
Original PR description
**Issue**: The displayed available quantity on the ecommerce product page is incorrect for rental products when "continue selling" is enabled. **Steps to reproduce**: - Create a rental product…
**Issue**: The displayed available quantity on the ecommerce product page is incorrect for rental products when "continue selling" is enabled. **Steps to reproduce**: - Create a rental product tracked in stock with a quantity of 5 - Enable "continue selling" and "show available quantity below 10" - Go to the ecommerce page of this product - Rent 3 units for a given period, confirm and pay - Return to the ecommerce product page -> Whatever the selected renting period, the displayed quantity is always 2 **Cause**: The website displays `free_qty`: https://github.com/odoo/enterprise/blob/41c729e22c5fd1abb690f8335e933f793be0b319/website_sale_stock_renting/static/src/xml/website_sale_stock_renting_product_availability.xml#L15 `free_qty` is computed in: https://github.com/odoo-dev/odoo/blob/0935829ddaecd7b2b6eec9157f8f790b546d06ff/addons/website_sale_stock/models/product_template.py#L36 which leads to: https://github.com/odoo/enterprise/blob/41c729e22c5fd1abb690f8335e933f793be0b319/website_sale_stock_renting/models/website.py#L10 and ultimately relies on: https://github.com/odoo/odoo/blob/37bf1703c7478a3010b71cd60bbb43b3295a605b/addons/stock/models/product.py#L213 This computation does not take the selected renting period into account. There is a period-aware computation here: https://github.com/odoo/enterprise/blob/41c729e22c5fd1abb690f8335e933f793be0b319/website_sale_stock_renting/models/website.py#L15C17-L21C1 but it is only triggered when `product.allow_out_of_stock_order` is False (i.e. when "continue selling" is disabled). opw-[5354163](https://www.odoo.com/web#id=5354163&view_type=form&model=project.task) Forward-Port-Of: odoo/enterprise#104655 Forward-Port-Of: odoo/enterprise#103333
This update resolves a problem where FedEx labels incorrectly displayed addresses containing special characters (like accented letters). The code has been updated to ensure all addresses are converted to ASCII characters before being sent to FedEx, preventing display issues on labels. This ensures accurate and consistent address formatting for shipments.
Original PR description
Issue ----- Fedex does not handle special characters in addresses, so passing an address such as "Rue de Libération 15" will show as "Rue de Lib...ration 15" on labels. ----- Ticket: opw-5419724 Forward-Port-Of: odoo/enterprise#104979 Forward-Port-Of: odoo/enterprise#104265
This update resolves an issue where the map component wasn't displaying correctly within the Odoo Studio. The fix addressed a missing size constraint, allowing the map to render. However, the map remains non-interactive, indicating a separate problem that needs attention.
Original PR description
Before this commit, the map did not render in studio. This was because the container did not have a size. After this commit, the map renders correctly, but it is still not clickable or interactable. task-5432169 Forward-Port-Of: odoo/enterprise#104968 Forward-Port-Of: odoo/enterprise#104114
This update addresses a technical issue that was causing a test to fail in Odoo's HR payroll module. The fix ensures that pages transition correctly during tests involving changes to employee job roles, preventing unexpected test failures. This improves the reliability of our automated testing process.
Original PR description
In the test tour related to the correct change of the salary configurator when the job changes on the employee, some missing expectUnloadPage options were causing the test to crash because the page was changing unexpectedly. With this PR we fix this error. Runbot Error: 231605
This update corrects a bug in the Master Production Schedule (MPS) calculation for kit products ordered from a second warehouse. Previously, the system was incorrectly doubling the component order quantity, leading to excessive and inaccurate reordering. This fix ensures accurate component replenishment for kits, preventing overstocking and streamlining production.
Original PR description
***Behavior:*** In a setting with a second warehouse that is supplied by the first one. Creating a product that uses that ressuply route, and then adding it to the bom of a kit product will make it…
***Behavior:*** In a setting with a second warehouse that is supplied by the first one. Creating a product that uses that ressuply route, and then adding it to the bom of a kit product will make it so that when ordering the kit product to the second warehouse from the MPS, the system will create an order for an exponential amount of components. When calling action_replenish, kit products for which the components don't have an MPS entry will have their product_ratio computed to know how many components to reorder. However the current formula is wrong or outdated and ends up returning the squared amount. ***Steps to reproduce:*** - Create a second warehouse. - Check Resuply From 'First Warehouse' (this will unarchive a route) - Create a product that uses that route for reordering. - Create a second product - Create a kit for that product BOM composed of the first product make sure the amount of component is more than 1 - In the Master Production Schedule: Add the kit product and make sure it is produced in the second warehouse with the unarchived route. - Add any amount to reorder in 'Replenishment' then click the Order button. - If you go to deliveries and look for your component, you'll see the amount of component per kit squared multiplied by the reordered kit amount. opw-5351460 Forward-Port-Of: odoo/enterprise#101462
This update resolves an error that occurred when users attempted to create invoices with payment methods having the same code. The fix prevents users from modifying payment method codes, ensuring compliance with Mexican regulations and preventing data inconsistencies. The changes include safeguards to ensure unique payment method codes are used.
Original PR description
Currently, an error occurs when a user tries to post an invoice using a payment method that shares the same code as another payment method. Steps to replicate: - Install `l10n_mx_edi` and…
Currently, an error occurs when a user tries to post an invoice using a payment method that shares the same code as another payment method.
Steps to replicate:
- Install `l10n_mx_edi` and `accountant` with demo and switch to `ZAPATERIA URTADO ÑERI` (Mexican company).
- Go to `Accounting > Configuration > Payment Way Codes (MX)`.
- Open `Efectivo` and change its code to `02`.
- Create a new Invoice, select `Efectivo` in the Payment Way.
- Add a customer and a move line, then confirm the invoice and send it (make sure CFDI is checked).
Error:
```
File '/home/odoo/src/enterprise/19.0/l10n_mx_edi/models/account_move.py', line 424, in _l10n_mx_edi_get_extra_invoice_report_values
cfdi_infos['payment_way'] = f'{payment_way} - {payment_method.name}'
File '/home/odoo/src/odoo/19.0/odoo/orm/fields.py', line 1659, in __get__
record.ensure_one()
File '/home/odoo/src/odoo/19.0/odoo/orm/models.py', line 5934, in ensure_one
raise ValueError('Expected singleton: %s' % self)
ValueError: Expected singleton: l10n_mx_edi.payment.method(1, 22)
```
Cause:
- Issue originated through this [PR] that gave access to write on the model.
- As the user made the codes of two payment methods same, the [search] returned two records and while accessing `payment_method.name` on two records it results into this error.
Solution:
- Made the fields read-only via XML to prevent users from changing the payment method codes established by the Mexican government.
- Added limit to the search query to prevent multiple records. (for existing DBs that might have changed payment method codes).
- Removed unlink rights on the `l10n_mx_edi.payment.method` model.
- Added a SQL constraint to allow only unique values for the code.
[PR]: https://github.com/odoo/enterprise/pull/38046
[search]: https://github.com/odoo/enterprise/blob/18117c6a9fbf270ace1c551616828a85713d5225/l10n_mx_edi/models/account_move.py#L423
sentry-7171030995
Forward-Port-Of: odoo/enterprise#104914
Forward-Port-Of: odoo/enterprise#10394413 changes
Resolved issues and error corrections
This update fixes a bug that caused Odoo to crash when creating invoices in USD with zero amounts and tax/discount applied. The fix prevents a division-by-zero error during currency conversion, ensuring invoices can be generated correctly. This improves stability and prevents data loss.
Original PR description
**Steps to reproduce:** 1. Install the `l10n_it_edi` and switch to IT company 2. Go to Accounting → Invoice. 3. Create an invoice add partner and change the currency to USD 4. Add a product and apply tax and discount of 100% and confirm 3. Click on Send **Issue:** A ZeroDivisionError is raised during the Italian EDI XML generation. `ZeroDivisionError: float division by zero` **Cause:** The conversion rate is computed by dividing `amount_total` by `amount_total_signed` without handling the case where `amount_total_signed` is `0.0`. **Solution:** Skip the conversion rate computation when the signed total amount is zero, preventing the division by zero **opw-5481821** Forward-Port-Of: odoo/odoo#244423
This update resolves an error that occurred when generating PDF reports for accounting, specifically when a contact didn't have a name assigned. The fix ensures that the report can now be successfully exported even with contacts lacking a name, improving report generation reliability.
Original PR description
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts`…
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts` modules. - Go to Contacts and open any contact (e.g., Azure Interior). - Click `Add` > `Save & Close`, then `save` the contact. - Navigate to Accounting > Reporting > Aged Receivable. - Click `Partners` button and select the newly created contact (e.g., `Azure Interior, Other Address`). - Click `PDF` to export the report. **Error:** `TypeError: sequence item 0: expected str instance, bool found` **Root Cause:** At [1], `options['selected_partner_ids']` is built using `partner.name`, which may be `False` for unnamed contacts. At [2], the `partner_value` list may therefore contain `False` entries coming from `options['selected_partner_ids']`. When calling `', '.join(partner_value)`, an error is raised because the list contains `non-string` (`bool`) values. **Fix:** This commit prevents errors when exporting reports to PDF and ensures that partner names are displayed in the report the same way as in the partner selection widget. [1]: https://github.com/odoo/enterprise/blob/a0ec2fcdc043cf52f1a646e84b9b97466072d47f/account_reports/models/account_report.py#L745 [2]: https://github.com/odoo/enterprise/blob/099c7b94ad08f83873c05ec528e16fbf806f47f2/account_reports/data/pdf_export_templates.xml#L84-L93 opw-5467321 Forward-Port-Of: odoo/enterprise#105025 Forward-Port-Of: odoo/enterprise#103828
This update corrects a typographical error in the tests for the search highlight feature within Odoo. The fix ensures the tests run correctly and prevents potential issues with search functionality. This is a routine maintenance update.
Original PR description
Intoduced by https://github.com/odoo/odoo/pull/118794 Forward-Port-Of: odoo/odoo#244832 Forward-Port-Of: odoo/odoo#244720
This update resolves a problem where FedEx labels incorrectly displayed addresses containing special characters (like accented letters). The code has been updated to ensure all addresses are converted to ASCII characters before being sent to FedEx, preventing display issues and ensuring accurate label formatting. This improves the reliability of shipping labels.
Original PR description
Issue ----- Fedex does not handle special characters in addresses, so passing an address such as "Rue de Libération 15" will show as "Rue de Lib...ration 15" on labels. ----- Ticket: opw-5419724 Forward-Port-Of: odoo/enterprise#104979 Forward-Port-Of: odoo/enterprise#104265
This update resolves an issue where invoices sent to Peppol were failing validation due to an incorrect UN/ECE code. The fix removes a specific UNECE code ('HD') that wasn't accepted by Peppol, ensuring invoices now pass validation and can be successfully transmitted.
Original PR description
**Steps to reproduce:** - Use a Belgian company - Create a Belgian contact with "EU Standard (Peppol Bis 3.0)" as eInvoice format - Create an invoice for that customer with a product using "Pack of 6" as unit of measure - Confirm the invoice - Send it to Peppol **Issue:** The validation of the invoice fails with the following error: "[BR-CL-23]-Unit code MUST be coded according to the UN/ECE Recommendation 20 with Rec 21 extension" **Cause:** The UNECE code used for "Pack of 6" UoM is "HD". "HD" is a correct UNECE code for "Half Dozen". However, it is not part of the subset of codes accepted by Peppol. opw-5463212 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#244668
This update resolves an issue where iOS users were unable to save custom star ratings for product reviews. The problem stemmed from a technical glitch that reset the rating to the default 4 stars before submission. This fix ensures that iOS users can accurately submit their product ratings, improving the overall customer experience.
Original PR description
## Versions
18.0+
## Issue
On iOS devices, when submitting a product review with a custom star rating, the selected value would revert to the default (4 stars) before submission.
## Steps to reproduce
*On a laptop*
- Open Editor mode on a product eCommerce page:
- Select any product element (e.g. click on the price);
- Activate customer ratings and save.
*On a physical Apple mobile device (iPhone or iPad) or on an iOS emulator via XCode (only on MacOS)*
- Go to the product's eCommerce page:
- Move down to the "Customer Reviews" section and un-toggle it:
- Write down a review;
- Click on any star rating but 4;
- Send.
## Cause
`mouseleave` event is triggered before the rating is saved and resets the rating to the default 4-star one.
## Solution
Only trigger `mouseleave` event on devices handling them correctly and post the number of visible stars on the form.
opw-5142682
Forward-Port-Of: odoo/odoo#234308This update resolves a visual glitch on mobile websites (particularly with RTL languages) where a horizontal scrollbar briefly appeared when the header reappeared after scrolling. The fix ensures the header's styling is correctly synchronized, preventing this momentary disruption of the user interface. This improves the overall mobile experience and consistency.
Original PR description
There was an horizontal scrollbar that would appear for a short time after scrolling back to the top of the page. This would occur because the header would still have the "transform" property but the class "o_header_affixed" was already removed. To fix the issue, the header transform is now applied using dynamicContent, to synchronize the style and class correctly. This requires the standard header to have "transition: none" applied after it is scrolled since "translate(0, -100%)" would trigger an animation when hiding the header. task-5155878 Forward-Port-Of: odoo/odoo#241980
This update corrects a bug in the Master Production Schedule (MPS) that caused excessive component reordering for kit products. Specifically, the system was incorrectly calculating the quantity of components needed, leading to inflated order quantities. This fix ensures accurate replenishment and prevents over-ordering of components.
Original PR description
***Behavior:*** In a setting with a second warehouse that is supplied by the first one. Creating a product that uses that ressuply route, and then adding it to the bom of a kit product will make it…
***Behavior:*** In a setting with a second warehouse that is supplied by the first one. Creating a product that uses that ressuply route, and then adding it to the bom of a kit product will make it so that when ordering the kit product to the second warehouse from the MPS, the system will create an order for an exponential amount of components. When calling action_replenish, kit products for which the components don't have an MPS entry will have their product_ratio computed to know how many components to reorder. However the current formula is wrong or outdated and ends up returning the squared amount. ***Steps to reproduce:*** - Create a second warehouse. - Check Resuply From 'First Warehouse' (this will unarchive a route) - Create a product that uses that route for reordering. - Create a second product - Create a kit for that product BOM composed of the first product make sure the amount of component is more than 1 - In the Master Production Schedule: Add the kit product and make sure it is produced in the second warehouse with the unarchived route. - Add any amount to reorder in 'Replenishment' then click the Order button. - If you go to deliveries and look for your component, you'll see the amount of component per kit squared multiplied by the reordered kit amount. opw-5351460 Forward-Port-Of: odoo/enterprise#101462
This update corrects a technical issue where a function was incorrectly called in the payroll module. The fix creates a new function in the documents module that properly calls the correct function, ensuring the payroll process runs smoothly. This resolves a potential error and maintains the stability of the HR and payroll features.
Original PR description
Issue: `_check_create_documents` is called in 'hr_payroll' but only defined in 'documents_hr_payroll' Solution: Create a new method that will be redefined in 'documents_hr_payroll' to call `_check_create_documents` opw-5213979 Forward-Port-Of: odoo/enterprise#104282
This update resolves an issue where invoices couldn't be processed correctly when multiple payment methods shared the same code. The fix ensures payment method codes are read-only, preventing conflicts and maintaining compliance with Mexican regulations. It also includes safeguards to handle existing data inconsistencies.
Original PR description
Currently, an error occurs when a user tries to post an invoice using a payment method that shares the same code as another payment method. Steps to replicate: - Install `l10n_mx_edi` and…
Currently, an error occurs when a user tries to post an invoice using a payment method that shares the same code as another payment method.
Steps to replicate:
- Install `l10n_mx_edi` and `accountant` with demo and switch to `ZAPATERIA URTADO ÑERI` (Mexican company).
- Go to `Accounting > Configuration > Payment Way Codes (MX)`.
- Open `Efectivo` and change its code to `02`.
- Create a new Invoice, select `Efectivo` in the Payment Way.
- Add a customer and a move line, then confirm the invoice and send it (make sure CFDI is checked).
Error:
```
File '/home/odoo/src/enterprise/19.0/l10n_mx_edi/models/account_move.py', line 424, in _l10n_mx_edi_get_extra_invoice_report_values
cfdi_infos['payment_way'] = f'{payment_way} - {payment_method.name}'
File '/home/odoo/src/odoo/19.0/odoo/orm/fields.py', line 1659, in __get__
record.ensure_one()
File '/home/odoo/src/odoo/19.0/odoo/orm/models.py', line 5934, in ensure_one
raise ValueError('Expected singleton: %s' % self)
ValueError: Expected singleton: l10n_mx_edi.payment.method(1, 22)
```
Cause:
- Issue originated through this [PR] that gave access to write on the model.
- As the user made the codes of two payment methods same, the [search] returned two records and while accessing `payment_method.name` on two records it results into this error.
Solution:
- Made the fields read-only via XML to prevent users from changing the payment method codes established by the Mexican government.
- Added limit to the search query to prevent multiple records. (for existing DBs that might have changed payment method codes).
- Removed unlink rights on the `l10n_mx_edi.payment.method` model.
- Added a SQL constraint to allow only unique values for the code.
[PR]: https://github.com/odoo/enterprise/pull/38046
[search]: https://github.com/odoo/enterprise/blob/18117c6a9fbf270ace1c551616828a85713d5225/l10n_mx_edi/models/account_move.py#L423
sentry-7171030995
Forward-Port-Of: odoo/enterprise#104914
Forward-Port-Of: odoo/enterprise#103944This update resolves an issue where non-administrator editors couldn't save images from Unsplash. The fix ensures that users with editor permissions can successfully upload and save these images, improving website customization capabilities. It addresses a security concern related to user access rights.
Original PR description
Scenario: - Setup Unsplash and install website - Set a user as "Website: Editor and Designer" - Login as that user and go to any website page with a qweb view - Go to edit mode and drop Text-Image in…
Scenario: - Setup Unsplash and install website - Set a user as "Website: Editor and Designer" - Login as that user and go to any website page with a qweb view - Go to edit mode and drop Text-Image in a view - Replace the image with an unsplash image and then save Result: the save fails without any message shown, and there is a security access WARNING in the logs. Note: a similar scenario can be done for a restricted editor that is editing a HTML field it has write access to. Issue: to save a model with res_id 0, we need to either be admin (base.group_system) or the record creator. Since 9c9c58a5a10101532cbf046d21d4a63c2b7d2838 to bypass the mimetype neutering of happening, we create the attachment as SUPERUSER. Then when we modify the attachment url (for unsplash images), we have no access right to the attachment since we are not the creator. Fix: create the attachment with the current user, and only use SUPERUSER to set the mimetype if it was neutered (ie. the user doesn't have write access right to ir.ui.view, which in normal use case should only happen for "Restricted Editor"). This way the image is created by the user that uploaded it and not SUPERUSER. opw-4850611 opw-5387258 opw-5489219 Forward-Port-Of: odoo/odoo#244831 Forward-Port-Of: odoo/odoo#219472
A test related to user signup was failing intermittently due to an issue with the URL being generated. This update corrects the test to handle both absolute and relative URLs, ensuring consistent test results and improved stability of the signup process. This resolves a technical issue that could have impacted user onboarding.
Original PR description
Bug === On some runs, the redirect URL is absolute and not relative, (eg: `http://127.0.0.1:8069/web/signup?db=...`) and so the test needs to be adapted. Task-5857520 Forward-Port-Of: odoo/enterprise#105027
This update prevents errors when users attempt to upload corrupted or encrypted PDF files when creating quotation document headers and footers. Previously, these files would cause a system error. This change ensures a smoother user experience by gracefully handling invalid PDF uploads, allowing users to continue generating quotes without interruption.
Original PR description
Currently, an error occurs when uploading `encrypted or incomplete` PDF files (missing EOF marker) while creating a quotation document header or footer. **Steps to reproduce:** - Install the…
Currently, an error occurs when uploading `encrypted or incomplete` PDF files (missing EOF marker) while creating a quotation document header or footer. **Steps to reproduce:** - Install the `sale_pdf_quote_builder` module. - Navigate to: Sales > Configuration > Headers/Footers. - Upload encrypted file [1], or incomplete file [2]. **Error:** `PyPDF2.errors.DependencyError: PyCryptodome is required for AES algorithm` `PyPDF2.errors.PdfReadError: EOF marker not found` **Root cause:** At [3], `_get_form_fields_from_pdf` and `_ensure_document_not_encrypted` directly call `pdf.PdfFileReader`, when it fails to read or decrypt the file, Python raises an error. **Fix:** This commit prevents errors when users upload unreadable or encrypted PDF files. [1]: https://drive.google.com/file/d/1moSlwXHkqcV6_7zHBNhLMLi-9Ye_xDGJ/view?usp=sharing [2]: https://drive.google.com/file/d/16O4LLH8dL0RWmbOx4HrcooFUyesWaVi-/view?usp=sharing [3]: https://github.com/odoo/odoo/blob/694f1d0fb03b56dd41a59eb676e56622634cc91b/addons/sale_pdf_quote_builder/utils.py#L11 sentry-6928220164 opw-5227601 Forward-Port-Of: odoo/odoo#245109 Forward-Port-Of: odoo/odoo#230712
7 changes
Resolved issues and error corrections
This update hides live chat commands (like `/help`) from visitors and guests. Previously, these commands were visible but unusable, creating a confusing experience. This change improves usability and prevents accidental interaction by non-users.
Original PR description
**Current behavior before PR:** channel commands like `/help ` or `/leave` are visible to visitors even it is not functional for them. **Desired behavior after PR is merged:** commands are now hidden from visitors. task-4552209 related: [PR](https://github.com/odoo/enterprise/pull/82963) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update prevents website visitors and guests from seeing live chat commands like '/help' or '/leave'. Previously, these commands were visible, even though they weren't functional for non-logged-in users. This change improves the user experience and security by removing potentially confusing or exploitable elements from the website.
Original PR description
**Before PR:** channel commands like `/help ` or `/leave` and more are visible to visitors or guest even it is not functional for them. **After PR:** all commands are now hidden from visitors/guests. task-4548666
This update resolves a bug that caused Odoo to crash when creating invoices in USD with zero amounts and tax/discount applied. The fix prevents a division-by-zero error during currency conversion, ensuring invoices can be processed correctly. This improves stability and prevents data errors related to foreign currency transactions.
Original PR description
**Steps to reproduce:** 1. Install the `l10n_it_edi` and switch to IT company 2. Go to Accounting → Invoice. 3. Create an invoice add partner and change the currency to USD 4. Add a product and apply tax and discount of 100% and confirm 3. Click on Send **Issue:** A ZeroDivisionError is raised during the Italian EDI XML generation. `ZeroDivisionError: float division by zero` **Cause:** The conversion rate is computed by dividing `amount_total` by `amount_total_signed` without handling the case where `amount_total_signed` is `0.0`. **Solution:** Skip the conversion rate computation when the signed total amount is zero, preventing the division by zero **opw-5481821** Forward-Port-Of: odoo/odoo#244423
This update resolves an issue in the Mexico (l10n_mx) accounting reports where an incorrect value appeared in the 'Month 13' column of the Trial Balance. The fix removed a redundant balance column, ensuring data displays accurately within the report. This improves the reliability of financial reporting for Mexican businesses using Odoo Enterprise.
Original PR description
With l10n_mx company: 1 - Add the balance column to the “Trial Balance” accounting report 2 - Create a journal entry for the date 12/31/2024 for 5000 as a credit on the account 119.01.01 VAT due and balance it with 5000 as a debit on another account 3 - Open the Trial Balance report and click on the “Month 13” filter as well as the year 2024. Notice that the “Month 13” column has some numbers when there should not be a number in that column. Delete the balance column from the “Trial Balance” accounting report and notice that the numbers now appear in their appropriate columns. In the _l10n_mx_set_options_month_13 the way to find the initial value, month 13 and end value columns was hardcoded. opw-5222117 Forward-Port-Of: odoo/enterprise#104788 Forward-Port-Of: odoo/enterprise#104105
This update resolves an error that occurred when generating PDF reports for accounting, specifically when a contact didn't have a defined name. The fix ensures that reports can now be created successfully even with contacts lacking names, improving report generation reliability.
Original PR description
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts`…
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts` modules. - Go to Contacts and open any contact (e.g., Azure Interior). - Click `Add` > `Save & Close`, then `save` the contact. - Navigate to Accounting > Reporting > Aged Receivable. - Click `Partners` button and select the newly created contact (e.g., `Azure Interior, Other Address`). - Click `PDF` to export the report. **Error:** `TypeError: sequence item 0: expected str instance, bool found` **Root Cause:** At [1], `options['selected_partner_ids']` is built using `partner.name`, which may be `False` for unnamed contacts. At [2], the `partner_value` list may therefore contain `False` entries coming from `options['selected_partner_ids']`. When calling `', '.join(partner_value)`, an error is raised because the list contains `non-string` (`bool`) values. **Fix:** This commit prevents errors when exporting reports to PDF and ensures that partner names are displayed in the report the same way as in the partner selection widget. [1]: https://github.com/odoo/enterprise/blob/a0ec2fcdc043cf52f1a646e84b9b97466072d47f/account_reports/models/account_report.py#L745 [2]: https://github.com/odoo/enterprise/blob/099c7b94ad08f83873c05ec528e16fbf806f47f2/account_reports/data/pdf_export_templates.xml#L84-L93 opw-5467321 Forward-Port-Of: odoo/enterprise#105025 Forward-Port-Of: odoo/enterprise#103828
This update corrects a bug where the Gantt progress bar displayed incorrect operation durations after changing a workorder's workcenter. The previous system incorrectly used the old workcenter's efficiency when calculating the final completion date. This ensures the Gantt chart accurately reflects the expected duration of operations.
Original PR description
**Issue** Changing the workcenter of a workorder to another with a different time efficiency does not correctly update `date_finished`, causing the Gantt progress bar to show an incorrect expected…
**Issue** Changing the workcenter of a workorder to another with a different time efficiency does not correctly update `date_finished`, causing the Gantt progress bar to show an incorrect expected duration. **Steps to reproduce** 1. Create two workcenters marked as alternatives (100% and 50% efficiency). 2. Create a BOM operation that produces 100 products with a 1h expected duration each, on the 100% workcenter. 3. Create and plan an MO using this BOM. 4. In Planning > Planning by Workcenter (Gantt), drag the workorder to the 50% efficiency workcenter. → Expected duration remains 100h instead of 200h. 5. Drag the same workorder back to the 100% workcenter. → Expected duration becomes 200h instead of 100h. **Cause** `date_finished` is recomputed in `write()` using the *previous* workcenter’s efficiency, because the duration calculation happens before the new `workcenter_id` is applied: https://github.com/odoo/odoo/blob/18.0/addons/mrp/models/mrp_workorder.py#L471 Since the Gantt progress bar uses the interval [`[date_start, date_finished]`](https://github.com/odoo/enterprise/blob/18.0/mrp_workorder/models/mrp_workorder.py#L672C13-L674C107) to compute the expected duration (via `_web_gantt_progress_bar_workcenter_id`), the displayed duration becomes wrong. opw-5224272 Forward-Port-Of: odoo/odoo#239021
This update corrects a typographical error in the tests for Odoo's search functionality. The fix ensures the search results are displayed correctly, improving the overall user experience. This is a routine maintenance update.
Original PR description
Intoduced by https://github.com/odoo/odoo/pull/118794 Forward-Port-Of: odoo/odoo#244832 Forward-Port-Of: odoo/odoo#244720
4 changes
Resolved issues and error corrections
This update corrects a database issue related to how VAT data is handled in Odoo's Brazilian retail module (l10n_br_edi_pos). An earlier update removed a necessary step to ensure VAT data was properly formatted in newer Odoo versions. This fix reintroduces a small code block to guarantee accurate VAT data processing, preventing potential reporting errors.
Original PR description
In [^1], we removed the compacting code that existed in l10n_br modules as all vats are now stored as compact forms since [^2]. *However*, we did not consider that databases updated to 18.4+ would not automatically apply the compacting code to all records. As such, we have reintroduced a small block of compacting code in `l10n_br_edi_pos` as that one does special operations with the VAT that needs to be stripped of special characters. opw-5491321 [^1]: odoo/enterprise#87562 [^2]: odoo/odoo#179078 Forward-Port-Of: odoo/enterprise#104960
This update resolves an error that occurred when generating PDF reports for accounting, specifically when a contact didn't have a name assigned. The fix ensures the report exports correctly even with contacts lacking a name, improving the reliability of the reporting process.
Original PR description
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts`…
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts` modules. - Go to Contacts and open any contact (e.g., Azure Interior). - Click `Add` > `Save & Close`, then `save` the contact. - Navigate to Accounting > Reporting > Aged Receivable. - Click `Partners` button and select the newly created contact (e.g., `Azure Interior, Other Address`). - Click `PDF` to export the report. **Error:** `TypeError: sequence item 0: expected str instance, bool found` **Root Cause:** At [1], `options['selected_partner_ids']` is built using `partner.name`, which may be `False` for unnamed contacts. At [2], the `partner_value` list may therefore contain `False` entries coming from `options['selected_partner_ids']`. When calling `', '.join(partner_value)`, an error is raised because the list contains `non-string` (`bool`) values. **Fix:** This commit prevents errors when exporting reports to PDF and ensures that partner names are displayed in the report the same way as in the partner selection widget. [1]: https://github.com/odoo/enterprise/blob/a0ec2fcdc043cf52f1a646e84b9b97466072d47f/account_reports/models/account_report.py#L745 [2]: https://github.com/odoo/enterprise/blob/099c7b94ad08f83873c05ec528e16fbf806f47f2/account_reports/data/pdf_export_templates.xml#L84-L93 opw-5467321 Forward-Port-Of: odoo/enterprise#105025 Forward-Port-Of: odoo/enterprise#103828
This update fixes an issue where selecting a work order in the MRP Overview would incorrectly prioritize it. The fix ensures that work orders are sorted correctly based on their actual record identifiers, resolving a display problem. Additionally, the 'show case' work order now remains at the top when using pagination for the first page.
Original PR description
Selecting an operation in the Overview makes it the 'show case' and first in the workcenter's operations list. However, acting on the workorder (adding a by-product for example) moves it to another position in the list. This because defineRelevantRecords wrongly uses record.'id' to sort recordsAlreadyInCache (internal data like 'datapoint_<n>' not present in the cache that contains record identifiers). Using the real record identifier 'resId' corrects the sorting operation. We also want the 'show case' workorder selected in the Overview to stay on top when using pagination (not for all pages, only the first one). task: 5028095 Forward-Port-Of: odoo/enterprise#98863
This update fixes a labeling error in the Dutch Profit and Loss report, ensuring that 'Cost of Goods Sold' and 'Cost of Sales' are correctly identified. The previous misassignment was causing inaccurate financial reporting, and this change ensures compliance with Dutch accounting standards.
Original PR description
**Steps to reproduce:** 1. Install l10n_nl_report. 2. Go to Accounting → Configuration → Accounting Reports. 3. Open Profit and loss report (tags). 4. Click on Cost of Goods Sold or Cost of Sales and check the related codes. **Issue**: In the Dutch Profit and Loss report, the codes assigned to the "Cost of Goods Sold" and "Cost of Sales" line items are swapped. **Currently:** - Cost of Goods Sold is linked to code: NL_SALE - Cost of Sales is linked to code: NL_COGS This results in incorrect mapping and misleading financial reporting. **Cause:** The codes were incorrectly applied, leading to reversed definitions between Cost of Goods Sold and Cost of Sales. See: https://www.investopedia.com/terms/c/cogs.asp **Solution:** Swap the code values so that: - **NL_COGS** → Cost of goods sold - **NL_SALE** → Cost of sales **opw-5407885**
13 changes
Resolved issues and error corrections
This update corrects a data issue related to Brazilian VAT (tax) records in the enterprise accounting system. A previous change removed a necessary step to ensure VAT data was properly formatted, particularly in the POS module. This fix reintroduces the required formatting to maintain accurate tax reporting.
Original PR description
In [^1], we removed the compacting code that existed in l10n_br modules as all vats are now stored as compact forms since [^2]. *However*, we did not consider that databases updated to 18.4+ would not automatically apply the compacting code to all records. As such, we have reintroduced a small block of compacting code in `l10n_br_edi_pos` as that one does special operations with the VAT that needs to be stripped of special characters. opw-5491321 [^1]: odoo/enterprise#87562 [^2]: odoo/odoo#179078 Forward-Port-Of: odoo/enterprise#104960
This update resolves an issue where a Point of Sale order incorrectly remained flagged as a 'settlement' after a user canceled a payment attempt. By resetting the order flag, this prevents users from bypassing important business rules related to invoicing and reporting. This ensures accurate order processing and integration with other systems.
Original PR description
## Description of the issue/feature this PR addresses: The `is_settling_account` flag on a Point of Sale order is not reset to False if the user cancels a **Settle Due** operation. ## Current…
## Description of the issue/feature this PR addresses: The `is_settling_account` flag on a Point of Sale order is not reset to False if the user cancels a **Settle Due** operation. ## Current behavior before PR: When a user initiates a **Settle Due** payment for a customer, Odoo creates a new order and sets the `is_settling_account` flag to True. If the user proceeds to the payment screen but then navigates back (to the product screen) instead of completing the payment, the flag remains True. This is problematic because the user can then add regular products to this same order and check out. The order is processed as a normal sale, but it is incorrectly flagged as a settlement, which can lead to error on codes depending on this. ## Desired behavior after PR is merged: After this fix, if a user leaves the payment screen during a **Settle Due** operation, the `is_settling_account` flag on the order will be correctly reset to False. task-id - 5144679 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/enterprise#104438 Forward-Port-Of: odoo/enterprise#98463
This update resolves an error that occurred when generating PDF reports for accounting, specifically when a contact record lacked a name. The fix ensures that the report can now be successfully exported even if a contact doesn't have a defined name, improving report generation reliability.
Original PR description
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts`…
Currently, an error occurs when exporting an accounting report to PDF if any of the selected contacts do not have a name. **Steps to reproduce:** - Install the `account_reports` and `contacts` modules. - Go to Contacts and open any contact (e.g., Azure Interior). - Click `Add` > `Save & Close`, then `save` the contact. - Navigate to Accounting > Reporting > Aged Receivable. - Click `Partners` button and select the newly created contact (e.g., `Azure Interior, Other Address`). - Click `PDF` to export the report. **Error:** `TypeError: sequence item 0: expected str instance, bool found` **Root Cause:** At [1], `options['selected_partner_ids']` is built using `partner.name`, which may be `False` for unnamed contacts. At [2], the `partner_value` list may therefore contain `False` entries coming from `options['selected_partner_ids']`. When calling `', '.join(partner_value)`, an error is raised because the list contains `non-string` (`bool`) values. **Fix:** This commit prevents errors when exporting reports to PDF and ensures that partner names are displayed in the report the same way as in the partner selection widget. [1]: https://github.com/odoo/enterprise/blob/a0ec2fcdc043cf52f1a646e84b9b97466072d47f/account_reports/models/account_report.py#L745 [2]: https://github.com/odoo/enterprise/blob/099c7b94ad08f83873c05ec528e16fbf806f47f2/account_reports/data/pdf_export_templates.xml#L84-L93 opw-5467321 Forward-Port-Of: odoo/enterprise#105025 Forward-Port-Of: odoo/enterprise#103828
This update fixes a discrepancy between the quantity of components consumed displayed in the Shopfloor dialog and the Manufacturing Order itself after a work order is completed. Previously, the numbers didn't align, leading to potential data inconsistencies. This change ensures accurate reporting of consumed quantities, improving the reliability of manufacturing data.
Original PR description
Before this commit: ================================== In a Manufacturing Order(MO) with manual consumption of components, The quantity of component consumed shown in Shopfloor dialog didn’t match…
Before this commit: ================================== In a Manufacturing Order(MO) with manual consumption of components, The quantity of component consumed shown in Shopfloor dialog didn’t match with consumed quantity shown in MO after marking a work order as done. Steps to Reproduce: ================================== 1. Install `mrp_workorder` module. 2. Create a BOM with one component and two operations. 3. Set the component to be consumed in the first operation (manual consumption). 4. Create a MO for the finished product.(e.g., MO to produce 10 quantity) 5. Go to the Shopfloor and register a production.(e.g., 7 instead of 10). 6. Click on the component line → Check the consumed quantity shown in the dialog → Close dialog without applying it. 7. Validate the workorder in Shopfloor (A backorder creation dialog will appear; choose either option). 8. Check the consumed quantity of component in the MO form view. There is a mismatch between what was shown in Shopfloor dialog and what is shown in the MO form view. Cause of the Issue: ================================== The Shopfloor dialog `MrpQuantityDialog` uses the `quantity` field of the move, and this field is updated when the work order is marked as done to align consumed quantity with produced quantity, resulting in an inconsistency. After this commit: ================================== These changes ensure the consumed quantity shown in shop floor dialog correctly matches the consumed quantity shown in MO after marking a work order as done, enhancing data consistency between Shopfloor and the Manufacturing Order. TaskId-5068382
This update fixes a usability issue where bank statement information was hidden at the bottom of the search dialog. The changes move this critical data to the top of the form, making it much easier for users to quickly find and review their bank reconciliation details. This improves efficiency and accuracy in managing financial records.
Original PR description
The info of the bank statement line are now in the bottom but nobody sees them. This commit aims to have it on the top of the form. task-5212851
This update resolves an issue where the map component wasn't displaying correctly within the Odoo Studio. The fix ensures the map renders properly, but further work is needed to enable user interaction with the map. This improves the usability of the Studio for creating and customizing maps.
Original PR description
Before this commit, the map did not render in studio. This was because the container did not have a size. After this commit, the map renders correctly, but it is still not clickable or interactable. task-5432169 Forward-Port-Of: odoo/enterprise#104968 Forward-Port-Of: odoo/enterprise#104114
This update resolves an issue where FedEx labels incorrectly displayed addresses containing special characters (like accented letters). The code has been updated to ensure all address fields are converted to ASCII characters before being sent to FedEx, resulting in accurate address formatting on labels. This improves the presentation of customer addresses when using FedEx shipping.
Original PR description
Issue ----- Fedex does not handle special characters in addresses, so passing an address such as "Rue de Libération 15" will show as "Rue de Lib...ration 15" on labels. ----- Ticket: opw-5419724 Forward-Port-Of: odoo/enterprise#104979 Forward-Port-Of: odoo/enterprise#104265
This update fixes an issue where appraisals weren't automatically selecting the correct company-based template. The change ensures that appraisals, regardless of whether the employee or appraisal has a department assigned, correctly utilize the intended template. This prevents errors and ensures appraisals are set up accurately.
Original PR description
### Issue: When having a template with a company but no department, it's not selected by new appraisal. ### Steps to reproduce: - Have an employee whose appraisal date is today. - Have only one…
### Issue: When having a template with a company but no department, it's not selected by new appraisal. ### Steps to reproduce: - Have an employee whose appraisal date is today. - Have only one template, with the company of the employee but no department - Run the cron "Appraisal: Run employee appraisal" - Open the Appraisals app - Click on the newly created appraisal - It doesn't have the template ### Cause: - In `_compute_appraisal_template()`, only the department of the appraisal is used to compute the template. But `_create_new_appraisal()` doesn't include the department in `appraisal_values` to create the appraisal. So `appraisal.department_id` is `False` and the template from the department is ignored. - Another issue is if the employee has no department, then the appraisal also has no department. Then no template is selected by the search domain. ### Solution: - Include `department_id` in `appraisal_values` - Modify the search domain to include the case where the appraisal has no department opw-5477450
This update corrects a bug that prevented users from adding inputs to payslips. The fix ensures that the system correctly identifies and displays salary inputs for each employee, resolving an issue where inputs were not appearing. This improves the accuracy of payslip creation.
Original PR description
When trying to add Inputs for a payslips none appear as the domain was incorrect and only showed salary inputs for use in the employee. This is fixed in this commit by adding to the domain en each specific model. task-5486091
This update resolves an issue where work orders weren't correctly assigning employees due to an incorrect data structure. The fix ensures that employee IDs are handled properly, preventing duplicate key errors and ensuring accurate work order assignments. This improves the reliability of the work order management process.
Original PR description
The previous loop used `employee.id` as the key, which is undefined in this context because values come from resIds and represent record IDs directly. Steps to reproduce: - Enable work orders - Create a BOM with a work order - Configure 2 Assigned employees - Open the work order in Shop Floor An error is raised because, since `employee` is an integer (the ID), `employee.id` is undefined so odoo founds duplicate keys (all undefined). opw-5417887
This update corrects a bug in the Master Production Schedule (MPS) that caused excessive component reordering for kit products. Specifically, the system was incorrectly calculating the quantity of components needed, leading to inflated order quantities. This fix ensures accurate MPS calculations and prevents over-ordering of components.
Original PR description
***Behavior:*** In a setting with a second warehouse that is supplied by the first one. Creating a product that uses that ressuply route, and then adding it to the bom of a kit product will make it…
***Behavior:*** In a setting with a second warehouse that is supplied by the first one. Creating a product that uses that ressuply route, and then adding it to the bom of a kit product will make it so that when ordering the kit product to the second warehouse from the MPS, the system will create an order for an exponential amount of components. When calling action_replenish, kit products for which the components don't have an MPS entry will have their product_ratio computed to know how many components to reorder. However the current formula is wrong or outdated and ends up returning the squared amount. ***Steps to reproduce:*** - Create a second warehouse. - Check Resuply From 'First Warehouse' (this will unarchive a route) - Create a product that uses that route for reordering. - Create a second product - Create a kit for that product BOM composed of the first product make sure the amount of component is more than 1 - In the Master Production Schedule: Add the kit product and make sure it is produced in the second warehouse with the unarchived route. - Add any amount to reorder in 'Replenishment' then click the Order button. - If you go to deliveries and look for your component, you'll see the amount of component per kit squared multiplied by the reordered kit amount. opw-5351460 Forward-Port-Of: odoo/enterprise#101462
This update resolves a technical issue preventing payroll tests from running correctly in both Hong Kong and Belgium. Specifically, it ensures the correct company settings are used during test execution, aligning data with payroll configurations and improving test reliability. This change is a fix for a known problem.
Original PR description
As we are enabling tests on runbot, a few issues need to be fixed. When tested in the l10n build, the BE tests are failing due to company setting issue on the admin user. Also aligns the readonly attribute of two computed field on the version to match the employee in HK payroll.
This update resolves a crash within the automated test suite for the Belgian payroll and HR module. The issue stemmed from missing instructions during a test involving job changes, causing unexpected page transitions. This fix ensures the test suite runs smoothly and reliably.
Original PR description
In the test tour related to the correct change of the salary configurator when the job changes on the employee, some missing expectUnloadPage options were causing the test to crash because the page was changing unexpectedly. With this PR we fix this error. Runbot Error: 231605 Forward-Port-Of: odoo/enterprise#105067
11 changes
Resolved issues and error corrections
This update enhances the message list functionality by displaying specific error details when loading messages fails. Previously, users only saw a generic 'Ann error occurred' message. Now, the system provides a more informative error message, helping to diagnose and resolve persistent issues with message retrieval.
Original PR description
Backport of https://github.com/odoo/odoo/pull/244094 Before this commit, when message list failed to load, it just displays a "Ann error occurred" generic message with a retry button. This assumes that error happens rarely and when so this is temporarily. However some errors are persistent and it's frustrating to have no clue on why there's error or what may have caused it. This commit shows the `Error.toString()` from fetch message RPC failure on UI, so that there's a clue on the reason the fetch of messages failed. Before / After <img width="305" height="67" alt="Screenshot 2026-01-20 at 15 10 38" src="https://github.com/user-attachments/assets/34c546df-71e6-4055-9f85-8d85a9c89b35" /> <img width="334" height="100" alt="Screenshot 2026-01-20 at 15 09 07" src="https://github.com/user-attachments/assets/5fadd0b7-7ea0-43ca-8c28-0ac1d33650ff" /> Forward-Port-Of: odoo/odoo#244754
This update addresses a discrepancy in the testing process for Mexican VAT (CFDI) invoices, specifically related to rounding rules. The change ensures that test cases accurately reflect the latest Mexican tax regulations regarding rounding, improving the reliability of the l10n_mx_edi module. This ensures accurate VAT calculations for Mexican businesses using Odoo Enterprise.
Original PR description
Adapt the test cfdi rounding 9 for commit https://github.com/odoo/odoo/pull/233278
This update corrects a rounding issue in the payment wizard when converting invoices to MXN currency. Previously, the displayed amount was slightly off due to differences in how currency conversions were handled. This fix ensures accurate currency conversion and display, particularly for companies using MXN as their primary currency.
Original PR description
With a company where the main currency is, for instance, MXN (easier to reproduce with l10n_mx): - Create a currency exchange rate for USD: 0.051908143350 unit per MXN and 19.264800000000 MXN per unit. - Create an invoice in USD with a product priced at 432, quantity of 2, and 16% taxes. In the journal items of the invoice, the balance is 19307.96 MXN. However, in the payment wizard, the amount shown when switching to MXN currency is 19307.95. In _get_total_amount_in_wizard_currency_to_full_reconcile, we convert the source amount currency (which includes line + tax not yet converted), then perform the conversion. Whereas in the invoice, we first convert the product line and tax line separately and then sum them up. opw-4846090 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update addresses a technical issue preventing Odoo from correctly importing a necessary exception class from the 'requests' library. The issue stemmed from a recent change in the 'requests' package itself. By installing a specific version of 'requests' and importing the exception correctly, this fix ensures Odoo's functionality continues without interruption.
Original PR description
Installing `requests==2.25.1` and using the following line of code:
from requests.exceptions import JSONDecodeError
It raises the following error:
ImportError: cannot import name 'JSONDecodeError' from 'requests.exceptions' (python3.10/site-packages/requests/exceptions.py)
It was removed from the following commit in the `requests` package:
https://github.com/psf/requests/commit/db575eeedcfdb03bf31285afd3033e301df8b685
This change fixes this error importing the original exception from `json` package
Description of the issue/feature this PR addresses:
Current behavior before PR:
Desired behavior after PR is merged:
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prThis update resolves an issue where products with single attribute values (like color or shape) weren't correctly displayed when ordered via barcode in Point of Sale. The fix ensures that variants are only shown when multiple attribute selections are present, aligning with current Odoo 18.2 functionality. This improves the user experience for barcode-based ordering.
Original PR description
**Steps to reproduce:** - Make a product with 2 attributes, like color and shape - Enter a single value for each of them - Enter a Barcode on it - Go to PoS, click on it, the variants will be shown in it's name - Order it using the Barcode you defined - The product will not display the variants **Problem:** When ordering a product that has multiple attributes with a single value, the "selected" variants will be shown, even though it is always the same. When ordering it through the Barcode, the variants will not be shown. **Why the fix:** The variants are now not shown if all attributes only have one value, like it is done with the Barcode. If there are some attributes that have multiple values, it will be displayed when clicking on it. It is not possible to order them through Barcode as it does not support the value selection in 18.0. Only showing the variants if there are some choices to be made is how it is done from 18.2 onwards. opw-4946547
This update fixes an issue where the default pricelist wasn't being applied when creating new partners within the Point of Sale (PoS) module. The fix ensures the configured default pricelist is correctly used, resolving a discrepancy introduced in the 18.0 release. This maintains consistent pricing behavior for PoS transactions.
Original PR description
**Disclaimer:** This is the same fix as fbde024 but it was breaking the PoS, as we tried to get rid of some widgets to bypass the console warnings "missing_widgets". We now make sure that the only…
**Disclaimer:** This is the same fix as fbde024 but it was breaking the PoS, as we tried to get rid of some widgets to bypass the console warnings "missing_widgets". We now make sure that the only warning we get are those "missing_widget" warnings while running the tour. **Problem:** When creating a new partner from PoS, the suggested pricelist is not the default pricelist we defined in the configuration. It worked before 18.0, but now the suggested pricelist is the first one that we defined in the configuration, not the one we set as default. **Steps to reproduce:** - In the configuration, enable flexible pricelists and fill some available pricelists. - Set a default pricelist that is not the first one you defined in the available section. - Open a session, click on the customer and click on create. - Go to the Sales and Purchase tab. - The pricelist is not the default one. **Why the fix:** If we are in PoS, we now put the default pricelist as a default for the new partner. We only do that if it is available, otherwise we fall back to the default flow. This is how it worked before 18.0. opw-4876573
This update fixes an issue where kit valuations were incorrectly calculating cost shares, leading to overvalued inventory. It also addresses a problem where BoM valuations didn't properly account for variant-specific lines, resulting in inaccurate component valuations. These changes ensure accurate inventory valuation, particularly for complex kits and different product variants.
Original PR description
Backport of https://github.com/odoo/odoo/pull/218326 This PR adds the feature of computing `cost_share` for nested kits and to loose the cost_share constraints to respect variant dependent lines. opw-4806023 opw-5085457 opw-5227496 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update removes the outdated 'Por Definir' payment method as the default for invoices, sale orders, and POS orders in the MX EDI module. This change corrects a fiscal inconsistency, particularly when using the 'PUE' payment policy, ensuring accurate reporting and compliance.
Original PR description
### Issue: The payment method `99 – Por Definir` was used as the default value for invoices, sale orders, and POS orders This leads to fiscal inconsistencies, especially when invoices use the `PUE`…
### Issue: The payment method `99 – Por Definir` was used as the default value for invoices, sale orders, and POS orders This leads to fiscal inconsistencies, especially when invoices use the `PUE` payment policy, where this payment method is invalid ### Cause: In the `_compute_l10n_mx_edi_payment_method_id` methods, the default value was always set to `Por Definir` ### Fix: After discussion with the PO (MIAL), the chosen solution is to archive the payment method `99 – Por Definir`and remove it as a default value All valid cases should already be handled explicitly, making it clear to the user that something is missing when the data is blank ### Steps to reproduce: - Install `l10n_mx_edi` and switch to the MX company - Create an invoice with today’s invoice date - The payment policy is set to PUE - Before the fix, the payment method is set to `Por Definir` For Sale Order and POS Order tests, it's the default value as soon as you create an order opw-5406038 Forward-Port-Of: odoo/enterprise#104164
This update optimizes how notifications are processed within Odoo, specifically when the system is under heavy load. By using a faster JSON serialization library, ‘orjson,’ the system responds more quickly and efficiently, preventing delays and bottlenecks. This results in a smoother user experience and improved system performance.
Original PR description
When the gevent server is under high load, the time required to acquire a cursor and fetch notifications increases. This causes notifications to accumulate, leading to larger payloads. Serializing these large payloads using the standard json library becomes a bottleneck. In a gevent environment, this monopolizes the event loop, delaying the processing of other greenlets. This commit introduces optional support for `orjson`. If installed, it is used to significantly speed up JSON encoding, freeing up the event loop. Using `orjson` increases the throughput by ~20% under high load. Forward-Port-Of: odoo/odoo#241601
This update fixes a technical issue where booking appointments with flexible resources resulted in a 404 error page for users. The change ensures appointments with these resources can be successfully booked, improving the user experience and preventing lost bookings.
Original PR description
**issue:** booking an appointment with a flexible resource returns a 404 error page. **steps to reproduce:** - create an appointment with a flexible resource - go to website - attempt to book an appointment - 404 page not found is returned opw-5039947
This update enhances the stability of the account winbooks import function by breaking down large move creation processes into smaller batches. This prevents potential memory issues that could cause the import to fail, ensuring smoother and more reliable data imports.
Original PR description
The part of the import function that created moves could easily attempt to create thousands of moves at once, potentially leading to a memory error. This PR splits the calls into batches to avoid using too much memory. opw-5003045 Forward-Port-Of: odoo/enterprise#97263 Forward-Port-Of: odoo/enterprise#91931
7 changes
Resolved issues and error corrections
This update corrects a rounding issue in the payment wizard when displaying amounts in MXN currency for invoices with USD pricing and taxes. The fix ensures accurate currency conversion and display of invoice totals, resolving a discrepancy between the invoice and payment wizard. This improves financial reporting accuracy.
Original PR description
With a company where the main currency is, for instance, MXN (easier to reproduce with l10n_mx): - Create a currency exchange rate for USD: 0.051908143350 unit per MXN and 19.264800000000 MXN per unit. - Create an invoice in USD with a product priced at 432, quantity of 2, and 16% taxes. In the journal items of the invoice, the balance is 19307.96 MXN. However, in the payment wizard, the amount shown when switching to MXN currency is 19307.95. In _get_total_amount_in_wizard_currency_to_full_reconcile, we convert the source amount currency (which includes line + tax not yet converted), then perform the conversion. Whereas in the invoice, we first convert the product line and tax line separately and then sum them up. enterprise: https://github.com/odoo/enterprise/pull/92522 opw-4846090 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves a bug in the tests for the Mexican Electronic Invoicing (CFDI) payment wizard. The fix ensures accurate rounding of payments during tax calculations, addressing a potential discrepancy in how taxes were applied. This improves the reliability of financial reporting within the Odoo Enterprise system.
Original PR description
This commit correct the test test_cfdi_rounding_9 after commit a7213d25965348aa3188ee7368f8db6d57463fc1 community: https://github.com/odoo/odoo/pull/222682 opw-4846090
This update addresses a minor issue preventing Odoo modules (l10n_eg_edi_eta, l10n_ro_edi_stock, and l10n_rs_edi) from correctly importing a JSON error handling function. The fix involves installing a specific version of the 'requests' library and importing the necessary exception class, resolving a conflict introduced in a recent 'requests' package update.
Original PR description
Installing `requests==2.25.1` and using the following line of code:
from requests.exceptions import JSONDecodeError
It raises the following error:
ImportError: cannot import name 'JSONDecodeError' from 'requests.exceptions' (python3.10/site-packages/requests/exceptions.py)
It was removed from the following commit in the `requests` package:
https://github.com/psf/requests/commit/db575eeedcfdb03bf31285afd3033e301df8b685
This change fixes this error importing the original exception from `json` packageThis update resolves a bug preventing Quality Administrators from creating Quality Worksheet Templates. The issue stemmed from incorrect permission handling during record creation, now corrected to ensure proper access rights are applied. Users can now successfully create and save templates.
Original PR description
A Quality Administrator user currently cannot create a Quality Worksheet Template. This is caused by the fact that the process creates additional records: 'ir.model' and 'ir.model.fields'. The `.sudo()` used with the first one is not propagated to the second one. The solution was to create 'ir.model.fields' separately, after the creation of 'ir.model'. Additionally, 'ir.rule' creation is also done with `.sudo()` now (it's a part of the same process). Steps to reproduce: * as admin, modify the demo user: * make sure the "Administration" access right is empty * set "Quality" access right to "Administrator" * as demo user: * go to Quality -> Configuration -> Quality Worksheet Templates * create a new template and save The template should be saved without any errors. Task: 5350296
This update fixes an issue where the shipping weight for deliveries wasn't accurately calculated when items were placed in packages. The fix ensures that the total package weight is correctly computed, addressing a potential discrepancy in delivery weight reporting. This improves the accuracy of shipping calculations.
Original PR description
Steps to reproduce: - Enable “Packaging” in Inventory settings. - Create a storable product “P1” with: - weight: 10 kg - Create a delivery picking: - Add one unit of P1 - Mark as “To Do” - Set…
Steps to reproduce:
- Enable “Packaging” in Inventory settings.
- Create a storable product “P1” with:
- weight: 10 kg
- Create a delivery picking:
- Add one unit of P1
- Mark as “To Do”
- Set quantity to 1 → the move becomes assigned and the picking weight is correctly computed to 10
- Click “Put in Pack” → a package is created with `shipping_weight = 0`, and the picking weight incorrectly computed to 0
Problem:
- `picking.shipping_weight` is computed as: `weight_bulk` + sum(`pack.shipping_weight or pack.weight`) https://github.com/odoo/odoo/blob/17.0/addons/stock_delivery/models/stock_picking.py#L72-L79
- Once the product is placed in a package:
- `weight_bulk` becomes 0 (because Total weight of products which are not in a package). https://github.com/odoo/odoo/blob/17.0/addons/stock_delivery/models/stock_picking.py#L96
- `pack.shipping_weight` is 0 on creation.
- The fallback `pack.weight` is 0 because its compute depends on the `picking_id` in context. Without this context, the compute uses only quants https://github.com/odoo/odoo/blob/f7c033eff7b7bc83d6d18fc5e4df320f43ae5021/addons/delivery/models/stock_quant_package.py#L11-L13
opw-5357843This update fixes a bug that prevented the dashboard from accurately displaying high-priority maintenance requests. The issue stemmed from a misinterpretation of the priority field's data type, leading to an incorrect count of zero. Now, high-priority requests are correctly identified and displayed, improving maintenance prioritization.
Original PR description
Issue before this commit: ========================= The high-priority maintenance request count (todo_request_count_high_priority) was not calculated correctly. Steps to Reproduce:…
Issue before this commit: ========================= The high-priority maintenance request count (todo_request_count_high_priority) was not calculated correctly. Steps to Reproduce: ========================= - Install the maintenance module. - Create a maintenance request and set the Priority to High (3-starred) in the form view. - Open the dashboard. - Observe that the high-priority request count is not displayed. - The count always remains 0, even when high-priority requests exist. Cause of the issue: ========================= In this [PR](https://github.com/odoo/odoo/pull/94866), the logic was mistakenly changed. The priority field is defined as a Selection field, but while computing the count, the comparison was done against an integer(3, not '3') instead of the actual string value. Since the stored value is '3' (string), the condition is always evaluated to False, resulting in a count of 0. With This Commit: ========================= Ensure that high-priority maintenance requests are correctly counted and displayed on the dashboard when they exist. This provides better visibility of critical requests and helps users prioritise maintenance work effectively.
This update enhances the stability of the account winbooks import process. Previously, the function could consume excessive memory when creating a large number of moves at once. This change splits the process into smaller batches, preventing memory issues and ensuring smoother imports.
Original PR description
The part of the import function that created moves could easily attempt to create thousands of moves at once, potentially leading to a memory error. This PR splits the calls into batches to avoid using too much memory. opw-5003045 Forward-Port-Of: odoo/enterprise#91931