Daily updates from Odoo
Monday, April 13, 2026
210 changes
35 changes
Enhancements to existing features
This update simplifies the printer LNA (Label Next Available) configuration by consolidating checkbox options. Previously, printers had separate IoT and ePOS checkboxes, which were confusing for clients. Now, a single ePOS checkbox controls the LNA functionality, streamlining the process and improving usability.
Original PR description
The printer model has two checkboxes: one for IoT and one for ePOS. LNA is already hard for clients to understand, we then simplify it by removing the IoT one from the printer model, to use the ePOS one for both. If we check `use_lna` for on a printer type "iot", it will check the checkbox on the IoT Box record. Also, if we check/uncheck `use_lna` on the IoT Box record, it will check/uncheck it on the corresponding printer model.
This update ensures Odoo correctly handles tax exemptions related to international transactions (UBL Cii) by incorporating all required tax exemption reasons defined by Peppol. This improves compliance with international tax regulations and avoids potential issues with cross-border invoicing.
Original PR description
Some tax exemption reasons were missing, This commit ensures having all the tax exemption reasons introduced by Peppol task-6048561 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258455 Forward-Port-Of: odoo/odoo#254841
Resolved issues and error corrections
This update resolves a memory issue that was impacting the performance of the payroll dashboard. The team optimized the data processing method, switching from a complex union operation to a simpler list appending approach. This change significantly reduces memory usage and improves dashboard responsiveness.
Original PR description
Instead of using union in _group_records_by_schedule and _group_by_warning_and_date we append in a list and browse to avoid memory errors
This update resolves a technical error that prevented label printing when validating receipts through the barcode app. The fix utilizes an optional operator to handle cases where receipt data is missing, ensuring labels can now be printed correctly.
Original PR description
Given a printer is configured to print a label for product receipts, when the receipt is validated from the barcode app, then a traceback appears. A filter on action.context.active_ids was introduced in https://github.com/odoo/enterprise/pull/106277. When validating the receipt from the purchase app, active_ids is set to the id of the purchase order and the behavior is as expected. When validating the receipt in the barcode app , it is not set (nor was it set in 17.0). The filter therefore crashes because it cannot work on undefined. An optional chaining operator is added to apply the filter only if active_ids is set. The barcode app does not raise a traceback anymore when validating a receipt and the label can be printed. Forward-Port-Of: odoo/enterprise#113146
This update fixes an issue where the mutual health warning incorrectly flagged employees with long sick leaves before 31 days. The change now accurately identifies employees who have been on sick leave for at least the past 31 days, ensuring more accurate reporting and compliance. This improves the reliability of payroll data.
Original PR description
-**Issue**: The warning shows employees who had a long sick leaves before 31 days, which is incorrect. -**Fix**: Adjust the logic to include employees who have been on a sick leave for the past 31 days (at least). Forward-Port-Of: odoo/enterprise#113249 Forward-Port-Of: odoo/enterprise#112985
A recent issue prevented users from accessing server actions within the Document module due to a problem with how the system prioritized its views. This update corrects this prioritization by setting a specific priority for the Document module's server action view, ensuring the correct view is displayed and the user interface functions properly.
Original PR description
When the document module is installed, sometimes the server action view that is shown when accessing the server actions from the normal menu can be broken: the model field for instance is no longer visible, which makes the user interface unusable. <img width="723" height="412" alt="image" src="https://github.com/user-attachments/assets/73f6d516-77be-4f66-80dc-033fd8c0cb7c" /> This is because the document module defines a new primary form view for server actions, but does not set a priority for that view. As a result we have 2 primary views, with the same default priority of 16 in the database, and in that case the sorting of view can lead to the document specific view to be selected, when the other one is expected. We fix this by explicitly setting a priority of 32 on the form view in the document module. Forward-Port-Of: odoo/enterprise#112847
This update fixes an issue where product names displayed in purchase order lines would change between different pages of the order. The fix ensures product names are consistently shown, improving order clarity and accuracy. This resolves a display inconsistency that could lead to confusion.
Original PR description
**Steps to reproduce:** * Install the *Purchase* module * Create a product and set an *Reference* and Under the *Purchase* tab, add a vendor and define a *Vendor Product Code*. * Create a Purchase…
**Steps to reproduce:** * Install the *Purchase* module * Create a product and set an *Reference* and Under the *Purchase* tab, add a vendor and define a *Vendor Product Code*. * Create a Purchase Order with the same vendor set as on the product. * Add the configured product to the *Purchase Order Lines*. * Add the same product again on a second line and save the order. * Activate debug mode * Go to the view:Form and add a limit to have only 1 POL per page * Return to your PO * Go to the second page **Observed behavior:** * The *product display name* in the purchase order lines is different on the second page compared to the first page. **Cause:** * On the first page, purchase order lines are fetched via a web_read on the purchase order. * On subsequent pages, lines are fetched via a web_read directly on the purchase order lines. * The client requests both name and product_id.display_name. product field context includes partner_id, causing product_id.display_name to be computed as the vendor name. * As both values resolve to the vendor name, the original product name is lost, leading to inconsistent display across pages. **Note:** A similar issue was addressed in this commit : https://github.com/odoo/odoo/commit/28d53e0e565e266ca3fa2b67e359b4383fa42c36 * but its consequence it breaks the search using the vendor code/name in POL. * That change was reverted in this commit duo to the there consequence : https://github.com/odoo/odoo/commit/c9e8a802315be27a076ae677b9191c075e4c239d **Fix:** * This ensures the product name is propagated correctly in the form view while preserving search by vendor code or name. --- opw-5170924 Forward-Port-Of: odoo/odoo#258467 Forward-Port-Of: odoo/odoo#240515
This fix resolves an issue where sales emails incorrectly displayed invoice amounts as $0.00. The update ensures that the correct invoice amount is sent to the salesperson by using the display name and tax totals amount, addressing a discrepancy in how the invoice data was being processed in draft state.
Original PR description
Steps to produce: --- - Install `Sales` module. - Create a sale order, set a product, and assign Marc Demo as salesperson in the Other Info tab. - Confirm the sale order and create an invoice. Issue:…
Steps to produce: --- - Install `Sales` module. - Create a sale order, set a product, and assign Marc Demo as salesperson in the Other Info tab. - Confirm the sale order and create an invoice. Issue: --- - In the email notification sent to the salesperson, the record reference displays as False and the amount shows as 0.00. Root cause: --- - Here at [1], the record name is False because the invoice is still in draft state. - In [18], _sync_invoice sets amount_currency = line.balance for new lines, but balance is precomputed as 0 before the INSERT because _compute_balance returns 0 for invoice lines. In [17] it read price_subtotal directly, which is always correct. - In 17.0 the same mail fires at the same moment, but _sync_invoice had already set balance = −295 and amount_currency = −295 from price_subtotal, so the email reads the correct 295.00. Solution: --- - Use record.display_name instead of record.name, as display_name is always present regardless of the record state. - Use the tax totals amount instead of amount_total, which is not yet computed on draft invoices. [1]https://github.com/odoo/odoo/blob/0bcc34ec2f92b9b95cde321423d810002bb317ce/addons/account/models/account_move.py#L6478 [18]https://github.com/odoo/odoo/blob/b0a50104a12b205958316d382b4c7b2176395877/addons/account/models/account_move_line.py#L1566-L1610 [17]https://github.com/odoo/odoo/blob/73c076893de79df5a86aa970fde46a7aacbeaf3d/addons/account/models/account_move_line.py#L1536-L1585 Before: --- <img width="400" height="175" alt="image" src="https://github.com/user-attachments/assets/48c2dc03-765a-49c3-bad3-fd0b14405786" /> After: --- <img width="400" height="175" alt="image" src="https://github.com/user-attachments/assets/53682171-155f-46b3-85dd-0c7c98482067" /> opw-6023827 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258375 Forward-Port-Of: odoo/odoo#254862
This update fixes a minor issue in the Odoo list editor where the cursor wasn't updating correctly when the list was being reformatted. This ensures a smoother and more intuitive user experience when editing list items, preventing potential confusion for users. It's a technical refinement to improve the overall usability of the Odoo interface.
Original PR description
Description of the issue this PR addresses: This PR is a fixup to [[1]](https://github.com/odoo/odoo/commit/77cbdc0120f7ae7d5c777eb946ad568f2caf05d7) where cursor was not updated properly before unwrapping the element. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258558
This update resolves an issue preventing credit notes from being correctly exported to Mojeracun when a recipient bank account isn't specified. The fix addresses two underlying problems: a faulty check for bank account data and an incorrect structure within the XML export format. This ensures credit notes are now successfully generated and sent.
Original PR description
**Steps to reproduce:** * Install `l10n_hr_edi` module. * Generate an invoice and validate it. * Generate a credit note from that invoice. * Without a recipient bank account, try to send the credit…
**Steps to reproduce:**
* Install `l10n_hr_edi` module.
* Generate an invoice and validate it.
* Generate a credit note from that invoice.
* Without a recipient bank account, try to send the credit note to Mojeracun.
**Observed behavior:**
* Two errors are raised before the XML is generated:
1. `AttributeError: 'NoneType' object has no attribute 'get'` in `_invoice_constraints_eracun_new` when checking for whitespace in the bank account number.
2. `ValueError: The following child node is not defined in the template: CreditNote/cac:BillingReference/cbc:IssueDate` during XML serialization.
**Cause:**
* issue 1 : https://github.com/odoo/odoo/commit/96cf6626d2b3e75637b908244cf2fa4da615c16b#diff-16f43166a8e5a637cb57b5695a1332845ba5440d989e25fcd59c828aa55cb036R81
* In the mentioned commit `_invoice_constraints_eracun_new`, `node.get('cac:PayeeFinancialAccount', {})` returns `None` instead of `{}` when the key exists but its value is explicitly set to `None` (which happens when no bank account is set). Chaining `.get()` on `None` raises `AttributeError`.
* issue 2 : https://github.com/odoo/odoo/commit/47ef0c2cb96be9fffdc4985255661807980839c6#diff-16f43166a8e5a637cb57b5695a1332845ba5440d989e25fcd59c828aa55cb036R146
* In the mentioned commit in `_ubl_add_billing_reference_nodes`, `cbc:IssueDate` was added as a direct child of `cac:BillingReference`. The UBL template only allows `cac:InvoiceDocumentReference` as a child of `BillingReference`, while `cbc:IssueDate` belongs inside `cac:InvoiceDocumentReference`.
**Fix:**
* Replace `.get('cac:PayeeFinancialAccount', {})` with `.get('cac:PayeeFinancialAccount')` to safely handle an explicitly `None` value before chaining further calls.
* Move `cbc:IssueDate` inside `cac:InvoiceDocumentReference` in the `BillingReference` node, matching the structure defined in `ubl_21_common.py`.
opw-6088424
Forward-Port-Of: odoo/odoo#258057This update fixes an issue where product names on invoices weren't always displayed in the correct language when using child contacts. The change ensures that invoice line labels are translated based on the language of the selected invoice contact, regardless of the parent contact's language. This improves the accuracy and consistency of invoices across different languages.
Original PR description
### Issue before this commit: When creating an invoice using the child contact of a parent contact that has a different language with respect to the father, the label of the invoice line was not…
### Issue before this commit: When creating an invoice using the child contact of a parent contact that has a different language with respect to the father, the label of the invoice line was not always displayed in the child contact language but in the father's contact language. ### Steps to reproduce the issue: 1. Activate at least 2 languages (X and Y) 2. Create a product and set the translation for that product in the activated languages 3. Create a Contact with the language X 4. Create a child contact (invoice adress type) for that contact with language Y 5. Create a new invoice setting the customer as the child contact 6. Add the product you created 7. See the label is displayed in the language of the parent contact ### Cause of the issue: The computation of the invoice line name relied on line.partner_id.lang. However, the partner_id of the move line is automatically set to the commercial partner that can be different (can be the father's contact) to the contact used on the invoice. As a result, the product description was translated using the wrong language. ### Reason to introduce the fix: To ensure that invoice line labels are correctly translated according to the language of the selected invoice contact, the computation now uses the language of move_id.partner_id instead of line.partner_id. This guarantees consistent and expected behavior in multilingual environments, especially when using different contacts under the same commercial partner. opw-5955875 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258458 Forward-Port-Of: odoo/odoo#254833
This update fixes a bug where payments weren't automatically updating to 'paid' status after bills with early payment discounts were fully reconciled. Now, when a payment is reconciled with a fully paid bill, the payment state will accurately reflect the transaction, improving financial reporting accuracy. This primarily impacts users utilizing early payment discounts.
Original PR description
Currently, payments may remain in the 'in_process' state even when the associated vendor bills are fully paid. This occurs primarily when using early payment discounts (EPD) and journals without…
Currently, payments may remain in the 'in_process' state even when the associated vendor bills are fully paid. This occurs primarily when using early payment discounts (EPD) and journals without outstanding accounts. Steps to reproduce: - Create an early payment term. - Create a Vendor Bill with EPD and post it. - Register a payment for this bill (no outstanding account set on journal => no move created). - Create a bank transaction fully paying the bill. - Reconcile the transaction with the bill. Issue: Access the payment of the bill. The payment state remains 'in_process' instead of 'paid'. Analysis: The issue occurs because the reconciliation process misses the trigger to set the payment state to 'paid'. Specifically: - The payment amount does not match the bill total due to the EPD. - The payment compute method does not monitor 'reconciled_bill_ids', causing it to ignore the status of linked vendor bills. This change adds 'reconciled_bill_ids' to the compute dependencies and ensures that if a payment is reconciled with any moves (invoices or bills), their payment_state is considered to determine the final state of the payment. Test in enterprise: https://github.com/odoo/enterprise/pull/112398 opw-5881976 Forward-Port-Of: odoo/odoo#256486
This update ensures payroll calculations and leave allocations are accurate by restricting work entry types to match the employee's country. A new automated process now adapts existing records to use the correct country-specific work entry types, preventing errors and improving data reliability.
Original PR description
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 ensures that Belgian province names are displayed in their native Dutch and French, improving the user experience for customers and partners in Belgium. The change addresses a previous limitation where these names were not translatable, now allowing for accurate and localized content.
Original PR description
The `name` field of `res.country.state` is not translatable. For that reason we want to have the province names in their native language. [opw-6107258](https://www.odoo.com/odoo/project.task/6107258) Forward-Port-Of: odoo/odoo#258445 Forward-Port-Of: odoo/odoo#258339
This update fixes an error in the Luxembourg company balance sheet reporting. Specifically, the 'Results brought forward' line was displaying incorrect values due to a technical issue with how account balances were calculated. The fix ensures accurate reporting of financial results for Luxembourg businesses, aligning with standard accounting practices.
Original PR description
Steps to reproduce: - Use a Luxembourg company - Post a P&L result for the year and do the year-end affectation (Dr 142 / Cr 1412) - Open the Luxembourg balance sheet (full or abbreviated) Issue:…
Steps to reproduce:
- Use a Luxembourg company
- Post a P&L result for the year and do the year-end affectation (Dr 142 / Cr 1412)
- Open the Luxembourg balance sheet (full or abbreviated)
Issue:
Line "V. Profit or loss brought forward" shows incorrect values.
Cause:
The `accounts` expression for that line used `account_codes` engine with formula `-14`,
which only sums accounts by code prefix. Account 1412 ("Results brought forward (assigned)")
was typed as `equity`, so its balance was carried forward as an initial balance instead of
being captured as retained earnings in the formula.
Solution:
- Set account 1412 to `equity_unaffected`, consistent with account 142.
- Change the `accounts` expression of Line V in both the full and abbreviated balance sheet
to use the `domain` engine:
`['|', ('account_id.code', '=like', '14%'), ('account_id.account_type', '=', 'equity_unaffected')]`
with subformula `-sum`.
This correctly captures the balance of all 14x accounts and any `equity_unaffected` accounts,
which covers the standard year-end affectation workflow.
opw-5883505
Forward-Port-Of: odoo/odoo#253559This update corrects a minor typo in the account_peppol module, resolving an issue that was previously flagged. This ensures the PEPPOL integration functions correctly, preventing potential disruptions in financial transactions. The change is a simple correction and does not impact any core functionality.
Original PR description
Correction in a typo from the last commit opw-6102471 Forward-Port-Of: odoo/odoo#258456
A recent update to our billing exports caused the 'Export XML' button to disappear for certain invoices. This fix ensures the button reappears only when an invoice is actually exportable, improving the user experience and preventing confusion. This change was made to align with recent UBL export refactoring.
Original PR description
Problem --------- Since the UBL export refactor, it was not possible to export the XML of non-imported bills and not self-bills. The Export XML option had been removed from the list view in odoo/odoo#255289. The Form view was omitted. Solution --------- Show the button "Export XML" only if the move can actually be exported. opw-6083344 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258512 Forward-Port-Of: odoo/odoo#257910
This update resolves an issue where KPI cards (Billable Hours, etc.) displayed on the Timesheets dashboard were not updating correctly when filters were applied. The problem stemmed from a hardcoded filter limiting data to a single user. Removing this restriction ensures accurate KPI data reflects all timesheet information based on applied filters.
Original PR description
Steps to reproduce: - 1. Go to the dashboard app > Timesheets. 2. Apply any global filter. Issue: - The main KPI cards (Billable Hours, Non-billable Hours, Billable Rate) do not update correctly when any global filter is applied. Filtering by 'Employee' causes the cards to show zero. Other filters like 'Project' or 'Department' show incomplete and incorrect data, reflecting only the timesheets of a single hardcoded user. Cause: - The pivot tables (`pivot 5` and `pivot 6`) that source the data for the KPI cards contained a hardcoded domain `['user_id', '=', 2]`. This condition changes any selection made in the global filter and shows incorrect data. Fix: - The hardcoded `['user_id', '=', 2]` condition has been removed. task-4782213 Forward-Port-Of: odoo/odoo#258412 Forward-Port-Of: odoo/odoo#224810
This update resolves an issue where unwanted message actions appeared when right-clicking on links within emails. The fix expands the original solution to handle more complex link structures, ensuring consistent behavior across all email messages. This improves the user experience by preventing unexpected actions.
Original PR description
Before this commit, when right-click on a link in a message, this sometimes show the message actions. A commit was dedicated on fixing this issue [1], however this was limited to exact click on `<a>`. Many links shared by email are `<a>` with some nested nodes, for example `<a><font>LINK</font></a>`. Such links were not covered by [1] and thus made the message actions show on right-click. This commit fixes the issue by not showing the message actions on right-click on links, including nested children. [1]: https://github.com/odoo/odoo/pull/244252 opw-6110949 Forward-Port-Of: odoo/odoo#258681
This update resolves a warning appearing on Odoo.sh production branches during module updates. Previously, logging about temporary field changes caused a yellow status, even though the updates were successful. The change lowers the log level to DEBUG, aligning with other processes and ensuring Odoo.sh branches consistently show a green, healthy status.
Original PR description
Description of the issue/feature this PR addresses: During a module update (-u ModuleName), the check introduced by #220983 patches temporarily a field with "company_dependent=True" because the…
Description of the issue/feature this PR addresses: During a module update (-u ModuleName), the check introduced by #220983 patches temporarily a field with "company_dependent=True" because the overriding module is not loaded yet. But currently it is logged as a warning and makes Odoo.sh production branch appears in yellow (warning state), while the update is actually fine. Current behavior before PR: Logs may contain warnings such as: - Patching res.partner.ref with company_dependent=True - Patching product.template.sale_ok with company_dependent=True - Patching product.product.default_code with company_dependent=True even though there is no actual issue (ok normal behavior) The main problem is that this makes Odoo.sh production branches appear not with green status, while the update module is actually fine. Desired behavior after PR is merged: Keep the same mechanism, but lower the log level from WARNING to DEBUG. This aligns the behavior with the "translate=True" patch logic, which is already logged at DEBUG. Having the production branches green. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258444 Forward-Port-Of: odoo/odoo#258326
This update resolves an issue where scrolling or swiping in the mobile inbox triggered incorrect 'longpress' actions, displaying message actions unexpectedly. The fix prevents event propagation, ensuring the system correctly identifies scrolling versus long presses, improving the user experience.
Original PR description
Before this commit, when in inbox mobile and scrolling & swiping on inbox notifications, the message actions was displayed at the same time. Steps to reproduce: - have Admin with "Handle in Odoo"…
Before this commit, when in inbox mobile and scrolling & swiping on inbox notifications, the message actions was displayed at the same time. Steps to reproduce: - have Admin with "Handle in Odoo" Notification preferences - have some messages in Inbox (e.g. receive @ mentions from chatter) - open Inbox in Discuss app in mobile, and scroll up / swipe horizontally on each message => this opens message actions in bottom sheet This happens because when scrolling up/down or swiping left/right on a message, this is triggering a longpress. The longpress has some dedicated code to detect that there's no scrolling or swipe at the same time, however since 1 the action swiper was changed and made this regression. This happens because 1 introduced some `ev.stopPropagation()` on touch event, which are crucial for the hook useLongPress() to determine whether a scroll or swipe is occuring. Because the events have been stopped, the useLongPress() wrongly assumes the user triggers a long press. One could think we could use capture in useLongPress(), which is generally the way to prevent this issue. However, ActionSwiper is stopping propagation at the capture mode, therefore giving no chance for useLongPress() to detect the touch events. Thankfully the capture event listener target is the `ActionSwiper` itself, so one solution is to register in capture mode in a broader scope like `window`. This commit fixes the issue by registering on `capture` of the touch event on `window` for `useLongPress()`. Task-6008171 Scroll up in inbox, Before / After:   Forward-Port-Of: odoo/odoo#258172
This update resolves an issue where the website's auto-hide tour occasionally failed due to a change in how the system handles layout updates. The fix ensures the tour correctly detects navbar changes after a layout refresh, improving the user experience. This ensures the tour consistently functions as intended.
Original PR description
Since the delay between tour steps was removed [1], this tour fails sometimes. After changing the layout, the iframe reloads, but the tour attempts to check if the navbar layout changed directly without any delay. [1]: https://github.com/odoo/odoo/commit/769b193 runbot-241849
A visual issue with the cart quantity input border was resolved. This update adjusts the styling to align with the recent upgrade of Bootstrap, ensuring consistent and correct border rendering for all users. This improves the overall user experience when adding items to the cart.
Original PR description
Steps to produce: --- - Install the `E-commerce` module. - Configure a product with a very large price. - Open the product on the website, add it to the cart, and navigate to the cart. Issue: --- -…
Steps to produce: --- - Install the `E-commerce` module. - Configure a product with a very large price. - Open the product on the website, add it to the cart, and navigate to the cart. Issue: --- - The quantity input group appears visually stretched, and the border rendering is inconsistent. Root Cause: --- - After upgrading from Bootstrap 5.1 to 5.3, border utility behavior changed. Classes like `border-end-0` no longer apply unless a base border class is also present. Solution: --- - Explicitly add the `border` class alongside `border-end-0` on the affected elements to restore the intended border styling. Before: --- <img width="822" height="185" alt="image" src="https://github.com/user-attachments/assets/6478083e-f5c1-4374-9c9a-979254eaee3d" /> After: --- <img width="828" height="188" alt="image" src="https://github.com/user-attachments/assets/5a1cb138-c9a5-4508-ad34-64d988904407" /> opw-6075996 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258777 Forward-Port-Of: odoo/odoo#256797
This update allows users to disable automatic PDF generation when importing XML invoices through the account_edi_ubl_cii module. Previously, all invoices triggered PDF creation, even without an embedded PDF, which was causing unnecessary file generation. Now, users have the flexibility to control this behavior.
Original PR description
Commit 7bc35c4 introduced automatic PDF generation for imported XML invoices that don't include an embedded PDF file. However, this behavior was mandatory and couldn't be disabled. This commit adds a new configuration parameter to allow users disable this behaviour. Task-6050566 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#257905 Forward-Port-Of: odoo/odoo#254847
This update fixes a visual issue where translation status highlights were hidden behind button backgrounds in the website builder. By adding a small span element, the translation state is now consistently displayed, ensuring accurate and clear translation status indicators for all website elements.
Original PR description
When buttons (`a.btn` elements) are translated inline, or badges (`span.s_badge`), the background color that shows the status of the translation appears under the background of the button/badge. The…
When buttons (`a.btn` elements) are translated inline, or badges (`span.s_badge`), the background color that shows the status of the translation appears under the background of the button/badge. The status is thus only visible on the surrounding text, and completely invisible when the button is alone (unless it has a transparent background). This commit adds a plugin in translate mode which adds a span with the color of the translation status in the problematic elements if they are inside a translation span and have a background color. Steps to reproduce: - Open website builder - Drop the `s_banner` snippet (or add a button by typing `/button`) - Add a second language - Open in translate mode - Bug: the text of the button does not have the green/yellow highlight that shows the translation state (technically, it is hidden under the background of the button, which you can see if you set a transparent background on the button) `o_translate_inline` on links: - 8fe88de0d5cc61395721cd8bda7b7ef2ea961760 - f65ac79631180e77aca5a53fc557b3e1acfcbd65 - 6aef5ee411656ec400e92fcc2bbd62e420645e0e task-6038029 Forward-Port-Of: odoo/odoo#258396 Forward-Port-Of: odoo/odoo#254000
This update resolves an issue where COGS wasn't being calculated correctly for sales with multi-step delivery processes. The fix ensures that COGS is accurately determined, even when the delivery involves multiple stages, leading to correct invoicing. This improves the accuracy of cost tracking for sales orders.
Original PR description
**Problem:** cogs is 0 if the delivery is multi steps with only first picking validated. **Steps to reproduce:** - set the warehouse as 2 steps delivery - create a tracked product avco perpetual -…
**Problem:** cogs is 0 if the delivery is multi steps with only first picking validated. **Steps to reproduce:** - set the warehouse as 2 steps delivery - create a tracked product avco perpetual - set a cost of 10$ and a positive quantity - create and confirm a SO for 1 quantity - validate only the first picking - create and confirm the invoice **Current behavior:** there is no cogs lines in the invoice **Expected behavior:** there should be cogs line for a cost of 10$ **Cause of the issue:** to compute the unit price of the cogs we use _get_cogs_value() https://github.com/odoo/odoo/blob/5fd80a1fb8ef33cfa9261967cf14f6f0c421d45a/addons/stock_account/models/account_move.py#L122 Inside _get_cogs_value(), because there is done moves, we use _get_cogs_price_unit() https://github.com/odoo/odoo/blob/5fd80a1fb8ef33cfa9261967cf14f6f0c421d45a/addons/stock_account/models/account_move_line.py#L67-L68 But because there is no valued quantity (because the done moves are internal), the return value will be 0. https://github.com/odoo/odoo/blob/5fd80a1fb8ef33cfa9261967cf14f6f0c421d45a/addons/stock_account/models/stock_move.py#L251-L253 So the cogs will have an amount of 0 and no line will be created https://github.com/odoo/odoo/blob/5fd80a1fb8ef33cfa9261967cf14f6f0c421d45a/addons/stock_account/models/account_move.py#L125-L126 **fix** The fix for consigned products introduced by this PR https://github.com/odoo/odoo/pull/255043 was working for the wrong reasons. _get_valued_consigned_qty() only works if the moves are partially consigned. If the move is fully consigned, _is_consigned_value_line() will return False for every move line. https://github.com/odoo/odoo/blob/5fd80a1fb8ef33cfa9261967cf14f6f0c421d45a/addons/stock_account/models/stock_move.py#L650-L651 That's because if the move is fully consigned, _is_in() and _is_out() will return False. https://github.com/odoo/odoo/blob/5fd80a1fb8ef33cfa9261967cf14f6f0c421d45a/addons/stock_account/models/stock_move_line.py#L72-L74 So it only works if the move is not fully consigned because _is_in() or _is_out() will be True thanks to the non consigned line. https://github.com/odoo/odoo/blob/5fd80a1fb8ef33cfa9261967cf14f6f0c421d45a/addons/stock_account/models/stock_move.py#L511-L519 However, _get_cogs_price_unit() still worked fine for fully consigned moves because if the move is fully consigned, total_qty will be 0 and the return value will be 0 https://github.com/odoo/odoo/blob/5fd80a1fb8ef33cfa9261967cf14f6f0c421d45a/addons/stock_account/models/stock_move.py#L251-L253 But this was hacky and prevented us to address the issue of this PR. The logic should be: If there is no quantity to value (consigned + not consigned) we fallback on the standard price (just as if there is no move). This solves the issue of this PR because no moves were valued moves in our use case. If there is a quantity to value (and we're in a case where we want the average move value), we use the average move value (which will be 0 if all the moves are consigned) opw-6001694 Forward-Port-Of: odoo/odoo#256383
This update resolves an issue where Google Ads cookies were not being blocked correctly within Odoo's website configuration. The fix involves a revised approach to patching script tags, ensuring that Google Ads tracking scripts are effectively prevented from loading. This improves user privacy and aligns with data protection regulations.
Original PR description
# How to reproduce - Go to Website app > Configuration > Websites > Select your website > Custom Code - In the "Custom <head> code" section add the script given at the last section of this PR (with a…
# How to reproduce
- Go to Website app > Configuration > Websites > Select your website > Custom Code
- In the "Custom <head> code" section add the script given at the last section of this PR (with a proper TAG_ID)
- Go to a new Incognito Tab and go to the Website front page
- Refuse the optionnal cookies
- Open the browser's console and go to Application > Storage > Cookies
# The problem
The Google Ads cookies are present (prefixed by _ga)
# Why
This commit introduced the blocking of 3rd party cookies :
https://github.com/odoo/odoo/commit/958b41c4acec7e1700ca4d6e0b25ee0ad2aac9f1
It works by doing 2 things, but none of them works in our case :
First, it edits the view rendering to replace the `src` value with "about:blank" for watched
tags, but this does not work for `website.custom_code_head` (our case) and `website.custom_code_footer` because it is t-out'ed which bypasses this code :
https://github.com/odoo/odoo/commit/958b41c4acec7e1700ca4d6e0b25ee0ad2aac9f1#diff-a27798e1ecfe96676dd48766e0aa9d12fbc0784e328ac1a3ec82b1ce199fc58bR121-R166
Second, it adds a script in the head of the page that patches the setter for the `src`
property of the script tags. If the value that we try to set is a URL to a site that we
block and the cookies are not yet accepted, we replace the `src` value with "about:blank".
https://github.com/odoo/odoo/blob/e906eb23d698061f146ba67aae420eb7bb5e8a68/addons/website/static/src/js/content/cookie_watcher.js#L8
This sadly does not work for parser-inserted scripts that are directly parsed from the HTML.
Indeed, they do not use the setter of `HTMLScriptElement.prototype`.
It is possible to verify this by adding a `MutationObserver` that checks for new script
insertions and adding breakpoints in this observer and in the patched setter. For the
first scripts of the page, the breakpoint in `MutationObserver`is triggerred while the
one in the setter is not.
# Proposed solution
We move this code into new helper functions :
https://github.com/odoo/odoo/blob/95dc247ecd773044ef9c9f1512c7d86d73df836c/addons/website/models/ir_qweb.py#L130-L135
And use these helper functions to create another helper function that allows us to check
an html field for trackers that would need to be removed
We then use this helper function on `website.custom_code_head` and `website.custom_code_footer`
# The script
```html
<!-- Google tag (gtag.js) -->
<script async src="[https://www.googletagmanager.com/gtag/js?id=TAG_ID"></script](https://www.googletagmanager.com/gtag/js?id=TAG_ID%22%3E%3C/script)>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'TAG_ID');
</script>
```
Source : https://developers.google.com/tag-platform/gtagjs
opw-6007810
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#258469
Forward-Port-Of: odoo/odoo#256808This update corrects a display issue in the Point of Sale session reports. Previously, reports showed excessive decimal places when selling products with decimal quantities. The fix ensures that report totals are presented with the standard two decimal places, improving clarity and accuracy for sales reporting.
Original PR description
When selling a lot of product with different quantities (quantities with decimals) the session report total by category might have a lot of decimals instead of 2. Steps to reproduce: ------------------- * Open PoS * Make an order with a lot of product and modify the quantities to have random values with decimals * Close the session * Generate the session report > Observation: The total qty by category has a lot of decimals instead of the 2 expected. The same error also happens for the total price Why the fix: ------------ We round each value with their respective precision to make sure we don't have 15 decimals. opw-6039016 Forward-Port-Of: odoo/odoo#257885 Forward-Port-Of: odoo/odoo#256038
This update resolves an issue where attendance records were incorrectly flagged as duplicates due to incorrect timezone calculations. The fix ensures accurate attendance tracking by correctly applying employee timezones when determining check-in times, preventing errors related to timezone offsets.
Original PR description
### Steps to reproduce: - Have a database in timezone America/Asuncion for example - Create an employee - Create an attendance for the day before yesterday from 13h to 19h - Run the absence detection cron - An error will be raised saying the user is already checked-in on that day ### Cause: When trying to create an absence attendance we localized yesterday's midnight into UTC and then apply the employee timezone. Which cause a one-day shift when having a timezone behind UTC as at that point we try to create an attendance on the day before yesterday not yesterday ### Fix: We use the timezone of the employee to localize midnight then get this time in UTC. opw-5930309 Forward-Port-Of: odoo/odoo#258492 Forward-Port-Of: odoo/odoo#257932
This update resolves a bug that prevented users from successfully replacing images with illustrations in the mass mailing editor. The fix ensures compatibility by converting illustrations to PNG format for broader email client support and updating the system to correctly handle image attachments with optional parameters.
Original PR description
Currently, in the mass mailing editor, an error occurs when a user replaces an image with an illustration. Steps to reproduce: 1. Open the mass mailing editor 3. Drag and drop a snippet containing an…
Currently, in the mass mailing editor, an error occurs when a user replaces an image with an illustration. Steps to reproduce: 1. Open the mass mailing editor 3. Drag and drop a snippet containing an image 4. Double-click on the image 5. In the image search bar, type "test" and press `Enter` 6. Select an illustration => A traceback is raised. When an illustration is selected, it is automatically stored as an attachment with the mimetype `image/svg+xml; charset=utf-8`. The editor then loads the image using the attachment URL (e.g. `/html_editor/shape/illustration/usability-testingsvg-258?...`). When the media dialog is closed (via `on_media_dialog_saved_handlers`), the editor attempts to process the image and calls the `/html_editor/get_image_info` route to retrieve the image info. This route retrieves the corresponding attachment from the database using the attachment url, but filters results based on a predefined set of allowed mimetypes. The issue arises because this set does not account for valid mimetypes that include optional parameters such as `charset=utf-8`. As a result, the attachment is not found, preventing the image from being processed and ultimately causing the crash. To fix the issue, we will update the domain used to retrieve image attachments so that it accepts valid mimetypes with optional parameters (e.g. `image/svg+xml; charset=utf-8`). During image processing, the transformed image is temporarily encoded in base64 and stored in the src attribute. When the record is saved, this base64 image is converted into a new attachment via the `/html_editor/modify_image/<id>` route. **This conversion step is necessary because many email clients have limited support for SVG images. Converting the illustration to PNG ensures better compatibility and visibility across mail clients.** After conversion, the image url is then set to `/html_editor/shape/illustration/335/usability-testingsvg-258?...` This URL is handled by the `html_editor/shape/<module>/<path:filename>` route. Its purpose is to process SVG files and dynamically adjust their colors based on query parameters (e.g. the `c1` parameter). However, once the image has been converted to PNG, this logic no longer applies. To address this, an additional conditional check will be introduced: if the file is not an SVG, the route will bypass the SVG-specific transformation logic and instead serve the image directly. Task-5977962 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#255134
This update corrects a bug where the system incorrectly calculated prices for downpayment lines on purchase orders. The change ensures that downpayment lines are treated like section and note lines, preventing unintended price recalculations and ensuring accurate order pricing.
Original PR description
## Issue: When viewing purchase order lines, the system attempts to compute the unit price for downpayment lines. This results in unintended behavior. ## Cause: PR…
## Issue: When viewing purchase order lines, the system attempts to compute the unit price for downpayment lines. This results in unintended behavior. ## Cause: PR https://github.com/odoo/odoo/pull/236669 introduced the `price_unit_product_uom` field along with its compute method `_compute_price_unit_product_uom` to manage PO comparison. Although the compute method correctly skips section and note lines, it does not exclude downpayment lines. Downpayment lines are identified by the `is_downpayment` field, which was introduced earlier in PR https://github.com/odoo/odoo/pull/176137. As a result, the computation is incorrectly applied to downpayment lines. ## With this commit: The UoM price computation is prevented for purchase order lines where is_downpayment is set to True. Downpayment lines are now treated similarly to section and note lines to prevent unintended price recalculations. Steps to reproduce : [Video](https://drive.google.com/file/d/1JrMN8x-i86QjRfMnaeYu-Jac03iFoJs3/view?usp=drive_link) OPW - 5930652 Forward-Port-Of: odoo/odoo#251259 Forward-Port-Of: odoo/odoo#249989
This pull request resolves an issue where email templates related to sales orders were not being correctly applied. The changes update data files in the 'sale' and 'website_sale' modules, ensuring that customers receive the appropriate email notifications for their orders. This improves the overall order process and customer communication.
Original PR description
Issue: Steps to reproduce: Cause: opw-6114223
This pull request resolves an issue where email templates related to website and sales functionalities were not being correctly applied. The update corrects a data file discrepancy, ensuring that relevant email notifications are sent to users during website browsing and sales processes. This improves the user experience and ensures consistent communication.
Original PR description
Issue: Steps to reproduce: Cause: opw-6114223
This update resolves an issue where email notifications weren't being sent when users with special characters (&, <, >) in their names were mentioned. The fix translates HTML entities back to their original form, ensuring mentions are correctly identified and emails are sent as expected. This improves notification delivery for all users.
Original PR description
**Description of the issue/feature this PR addresses:** The `Store.getMentionsFromText` method fails to identify mentions for users with special characters (&, <, >) in their names. Because the…
**Description of the issue/feature this PR addresses:** The `Store.getMentionsFromText` method fails to identify mentions for users with special characters (&, <, >) in their names. Because the function processes raw HTML, these characters are encoded as entities, causing them to be [filtered out](https://github.com/odoo/odoo/blob/a2b3a10255dba290ea462b9193ae11c54d8dd5e0/addons/mail/static/src/core/common/store_service.js#L599-L601) In order to resolve this, I translate the entities back into their normal representation, allowing our includes to find them. **Steps to reproduce bug:** 1) Create a user with a name containing &, <, > 2) Set it so they receive emails for notifications 3) Mention them in a long note 4) Observe that no email is sent **Current behavior before PR:** https://drive.google.com/file/d/1itBlz6havFmFi2G3mbOm3qh2_WH6uM76/view?usp=drive_link **Desired behavior after PR is merged:** https://drive.google.com/file/d/1PC2_hjBAhhC6ZSOEzs9SPYjSHrZbaplp/view?usp=drive_link opw-5895188 Forward-Port-Of: odoo/odoo#258499 Forward-Port-Of: odoo/odoo#249350
This update prevents a bug where changing a child company's ZATCA API mode would inadvertently reset and unboard the parent company's related sales journal. The fix ensures that journal resets are limited to the company being modified, improving data consistency and preventing unexpected disruptions.
Original PR description
**Steps to reproduce:** * Install `l10n_sa_edi` module. * Create a parent company and a child company, both with the same VAT number. * Onboard the parent company's Sales journal with ZATCA. *…
**Steps to reproduce:**
* Install `l10n_sa_edi` module.
* Create a parent company and a child company, both with the same VAT number.
* Onboard the parent company's Sales journal with ZATCA.
* Onboard the child company's Sales journal with ZATCA. Create a journal for the child if there is no journal.
* Change the child company's ZATCA API mode to any other mode.
**Observed behavior:**
* Changing the child company's API mode resets and unboards the parent company's Sales journal as well.
**Cause:**
* In `res.company.write`, when `l10n_sa_api_mode` changes, journals to reset are fetched using `_check_company_domain(company)`.
* `account.journal` uses `check_company_domain_parent_of`, which returns journals where `company_id` is a parent of the given company — so passing a child company also matches journals belonging to the parent.
**Fix:**
* Replace `_check_company_domain(company)` with a direct `('company_id', '=', company.id)` filter, so only journals strictly owned by the company being modified are reset.
opw-6099340
Forward-Port-Of: odoo/odoo#258750
Forward-Port-Of: odoo/odoo#25800622 changes
Enhancements to existing features
This update ensures Odoo correctly handles tax exemption reasons required by international standards (Peppol). It adds missing tax exemption reasons, improving compliance and accuracy for tax reporting related to UBL invoices.
Original PR description
Some tax exemption reasons were missing, This commit ensures having all the tax exemption reasons introduced by Peppol task-6048561 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258455 Forward-Port-Of: odoo/odoo#254841
Resolved issues and error corrections
This update resolves a bug that prevented users from printing labels when validating receipts through the barcode app. The fix involved adding a safeguard to handle situations where the barcode app didn't have the necessary data, ensuring label printing now works correctly.
Original PR description
Given a printer is configured to print a label for product receipts, when the receipt is validated from the barcode app, then a traceback appears. A filter on action.context.active_ids was introduced in https://github.com/odoo/enterprise/pull/106277. When validating the receipt from the purchase app, active_ids is set to the id of the purchase order and the behavior is as expected. When validating the receipt in the barcode app , it is not set (nor was it set in 17.0). The filter therefore crashes because it cannot work on undefined. An optional chaining operator is added to apply the filter only if active_ids is set. The barcode app does not raise a traceback anymore when validating a receipt and the label can be printed. Forward-Port-Of: odoo/enterprise#113146
A recent issue prevented users from accessing server actions correctly within the Documents module. This was caused by a conflict in how the system prioritized views, leading to an unusable interface. This update resolves the conflict by setting a priority for the Documents module's server action view, ensuring proper display.
Original PR description
When the document module is installed, sometimes the server action view that is shown when accessing the server actions from the normal menu can be broken: the model field for instance is no longer visible, which makes the user interface unusable. <img width="723" height="412" alt="image" src="https://github.com/user-attachments/assets/73f6d516-77be-4f66-80dc-033fd8c0cb7c" /> This is because the document module defines a new primary form view for server actions, but does not set a priority for that view. As a result we have 2 primary views, with the same default priority of 16 in the database, and in that case the sorting of view can lead to the document specific view to be selected, when the other one is expected. We fix this by explicitly setting a priority of 32 on the form view in the document module. Forward-Port-Of: odoo/enterprise#112847
This update resolves an issue where new users couldn't be properly linked to employees within the system, resulting in an error message. The fix clears a caching problem that was preventing the correct employee ID from being assigned, ensuring a smoother user onboarding process. This improves the reliability of user management.
Original PR description
In version 19.1, an error occurs when inviting a new user via General Settings and then clicking Manage Users: "The operation cannot be completed: A user cannot be linked to multiple employees in the…
In version 19.1, an error occurs when inviting a new user via General Settings and then clicking Manage Users:
"The operation cannot be completed: A user cannot be linked to multiple employees in the same company."
This happens even when logged in as an admin user with an existing linked employee. The issue stems from the `employee_id` field in the `res_users` model being a context-dependent computed field.
The `self.env.cache` lacks the employee data,
specifically `'res.users.employee_id': {(1, (2, True)): {2: None}}`.
To resolve this, i've used invalidate_recordset for proper clean the cache,
and again get the value of employee_id.
Clicking directly on "Manage Users" sometimes we cannot face an error, possibly a caching issue.
Inviting a user before accessing "Manage Users" results in an error,
<img width="1885" height="964" alt="2026-03-25_16-21" src="https://github.com/user-attachments/assets/8cd7d094-b0ce-42ca-a43f-1081de7ddc70" />
[opw-6041866](https://www.odoo.com/odoo/project/70/tasks/6041866)
[upg-4031096](https://upgrade.odoo.com/odoo/request/4031096)
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 fixes an issue where the product name displayed in purchase order lines would change when navigating to subsequent pages. The fix ensures the product's original name is consistently shown, improving clarity and accuracy for users managing purchase orders. This resolves a display inconsistency that could lead to confusion.
Original PR description
**Steps to reproduce:** * Install the *Purchase* module * Create a product and set an *Reference* and Under the *Purchase* tab, add a vendor and define a *Vendor Product Code*. * Create a Purchase…
**Steps to reproduce:** * Install the *Purchase* module * Create a product and set an *Reference* and Under the *Purchase* tab, add a vendor and define a *Vendor Product Code*. * Create a Purchase Order with the same vendor set as on the product. * Add the configured product to the *Purchase Order Lines*. * Add the same product again on a second line and save the order. * Activate debug mode * Go to the view:Form and add a limit to have only 1 POL per page * Return to your PO * Go to the second page **Observed behavior:** * The *product display name* in the purchase order lines is different on the second page compared to the first page. **Cause:** * On the first page, purchase order lines are fetched via a web_read on the purchase order. * On subsequent pages, lines are fetched via a web_read directly on the purchase order lines. * The client requests both name and product_id.display_name. product field context includes partner_id, causing product_id.display_name to be computed as the vendor name. * As both values resolve to the vendor name, the original product name is lost, leading to inconsistent display across pages. **Note:** A similar issue was addressed in this commit : https://github.com/odoo/odoo/commit/28d53e0e565e266ca3fa2b67e359b4383fa42c36 * but its consequence it breaks the search using the vendor code/name in POL. * That change was reverted in this commit duo to the there consequence : https://github.com/odoo/odoo/commit/c9e8a802315be27a076ae677b9191c075e4c239d **Fix:** * This ensures the product name is propagated correctly in the form view while preserving search by vendor code or name. --- opw-5170924 Forward-Port-Of: odoo/odoo#258467 Forward-Port-Of: odoo/odoo#240515
This update fixes an issue where sales emails were displaying incorrect invoice amounts (showing $0.00) due to a problem with how the system calculates invoice data in draft mode. The fix ensures that the correct invoice amount is sent to the salesperson, improving the accuracy of sales notifications.
Original PR description
Steps to produce: --- - Install `Sales` module. - Create a sale order, set a product, and assign Marc Demo as salesperson in the Other Info tab. - Confirm the sale order and create an invoice. Issue:…
Steps to produce: --- - Install `Sales` module. - Create a sale order, set a product, and assign Marc Demo as salesperson in the Other Info tab. - Confirm the sale order and create an invoice. Issue: --- - In the email notification sent to the salesperson, the record reference displays as False and the amount shows as 0.00. Root cause: --- - Here at [1], the record name is False because the invoice is still in draft state. - In [18], _sync_invoice sets amount_currency = line.balance for new lines, but balance is precomputed as 0 before the INSERT because _compute_balance returns 0 for invoice lines. In [17] it read price_subtotal directly, which is always correct. - In 17.0 the same mail fires at the same moment, but _sync_invoice had already set balance = −295 and amount_currency = −295 from price_subtotal, so the email reads the correct 295.00. Solution: --- - Use record.display_name instead of record.name, as display_name is always present regardless of the record state. - Use the tax totals amount instead of amount_total, which is not yet computed on draft invoices. [1]https://github.com/odoo/odoo/blob/0bcc34ec2f92b9b95cde321423d810002bb317ce/addons/account/models/account_move.py#L6478 [18]https://github.com/odoo/odoo/blob/b0a50104a12b205958316d382b4c7b2176395877/addons/account/models/account_move_line.py#L1566-L1610 [17]https://github.com/odoo/odoo/blob/73c076893de79df5a86aa970fde46a7aacbeaf3d/addons/account/models/account_move_line.py#L1536-L1585 Before: --- <img width="400" height="175" alt="image" src="https://github.com/user-attachments/assets/48c2dc03-765a-49c3-bad3-fd0b14405786" /> After: --- <img width="400" height="175" alt="image" src="https://github.com/user-attachments/assets/53682171-155f-46b3-85dd-0c7c98482067" /> opw-6023827 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258375 Forward-Port-Of: odoo/odoo#254862
This update fixes a minor issue in the Odoo list editor where the cursor wasn't updating correctly after normalizing list items. This ensures a smoother and more intuitive user experience when editing list data, preventing potential confusion for users. This change improves the overall usability of the Odoo interface.
Original PR description
Description of the issue this PR addresses: This PR is a fixup to [[1]](https://github.com/odoo/odoo/commit/77cbdc0120f7ae7d5c777eb946ad568f2caf05d7) where cursor was not updated properly before unwrapping the element. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258558
This update resolves a bug where KPI cards (Billable Hours, etc.) displayed incorrect data when filters were applied in the Timesheets dashboard. The issue stemmed from a hardcoded filter that prevented the cards from reflecting the correct timesheet data based on the selected filter criteria. The fix removes this hardcoded filter, ensuring accurate KPI calculations across all filters.
Original PR description
Steps to reproduce: - 1. Go to the dashboard app > Timesheets. 2. Apply any global filter. Issue: - The main KPI cards (Billable Hours, Non-billable Hours, Billable Rate) do not update correctly when any global filter is applied. Filtering by 'Employee' causes the cards to show zero. Other filters like 'Project' or 'Department' show incomplete and incorrect data, reflecting only the timesheets of a single hardcoded user. Cause: - The pivot tables (`pivot 5` and `pivot 6`) that source the data for the KPI cards contained a hardcoded domain `['user_id', '=', 2]`. This condition changes any selection made in the global filter and shows incorrect data. Fix: - The hardcoded `['user_id', '=', 2]` condition has been removed. task-4782213 Forward-Port-Of: odoo/odoo#258412 Forward-Port-Of: odoo/odoo#224810
This update fixes an issue where product names on invoices weren't always displayed in the correct language when using child contacts. The change ensures that invoice line labels are translated based on the language of the selected invoice contact, regardless of the parent contact's language. This improves the accuracy and consistency of invoices for international customers.
Original PR description
### Issue before this commit: When creating an invoice using the child contact of a parent contact that has a different language with respect to the father, the label of the invoice line was not…
### Issue before this commit: When creating an invoice using the child contact of a parent contact that has a different language with respect to the father, the label of the invoice line was not always displayed in the child contact language but in the father's contact language. ### Steps to reproduce the issue: 1. Activate at least 2 languages (X and Y) 2. Create a product and set the translation for that product in the activated languages 3. Create a Contact with the language X 4. Create a child contact (invoice adress type) for that contact with language Y 5. Create a new invoice setting the customer as the child contact 6. Add the product you created 7. See the label is displayed in the language of the parent contact ### Cause of the issue: The computation of the invoice line name relied on line.partner_id.lang. However, the partner_id of the move line is automatically set to the commercial partner that can be different (can be the father's contact) to the contact used on the invoice. As a result, the product description was translated using the wrong language. ### Reason to introduce the fix: To ensure that invoice line labels are correctly translated according to the language of the selected invoice contact, the computation now uses the language of move_id.partner_id instead of line.partner_id. This guarantees consistent and expected behavior in multilingual environments, especially when using different contacts under the same commercial partner. opw-5955875 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258458 Forward-Port-Of: odoo/odoo#254833
This update fixes an issue where the border around the cart quantity input appeared stretched and inconsistent after a recent Bootstrap upgrade. The fix ensures the border renders correctly, providing a consistent and professional user experience for customers adding items to their carts. This improves the overall visual quality of the website.
Original PR description
Steps to produce: --- - Install the `E-commerce` module. - Configure a product with a very large price. - Open the product on the website, add it to the cart, and navigate to the cart. Issue: --- -…
Steps to produce: --- - Install the `E-commerce` module. - Configure a product with a very large price. - Open the product on the website, add it to the cart, and navigate to the cart. Issue: --- - The quantity input group appears visually stretched, and the border rendering is inconsistent. Root Cause: --- - After upgrading from Bootstrap 5.1 to 5.3, border utility behavior changed. Classes like `border-end-0` no longer apply unless a base border class is also present. Solution: --- - Explicitly add the `border` class alongside `border-end-0` on the affected elements to restore the intended border styling. Before: --- <img width="822" height="185" alt="image" src="https://github.com/user-attachments/assets/6478083e-f5c1-4374-9c9a-979254eaee3d" /> After: --- <img width="828" height="188" alt="image" src="https://github.com/user-attachments/assets/5a1cb138-c9a5-4508-ad34-64d988904407" /> opw-6075996 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258572 Forward-Port-Of: odoo/odoo#256797
This update fixes an issue where the 'Results brought forward' line on the Luxembourg balance sheet was displaying incorrect values. The change ensures that year-end adjustments are accurately reflected, specifically by correctly categorizing account 1412 and using the appropriate formula to calculate the balance.
Original PR description
Steps to reproduce: - Use a Luxembourg company - Post a P&L result for the year and do the year-end affectation (Dr 142 / Cr 1412) - Open the Luxembourg balance sheet (full or abbreviated) Issue:…
Steps to reproduce:
- Use a Luxembourg company
- Post a P&L result for the year and do the year-end affectation (Dr 142 / Cr 1412)
- Open the Luxembourg balance sheet (full or abbreviated)
Issue:
Line "V. Profit or loss brought forward" shows incorrect values.
Cause:
The `accounts` expression for that line used `account_codes` engine with formula `-14`,
which only sums accounts by code prefix. Account 1412 ("Results brought forward (assigned)")
was typed as `equity`, so its balance was carried forward as an initial balance instead of
being captured as retained earnings in the formula.
Solution:
- Set account 1412 to `equity_unaffected`, consistent with account 142.
- Change the `accounts` expression of Line V in both the full and abbreviated balance sheet
to use the `domain` engine:
`['|', ('account_id.code', '=like', '14%'), ('account_id.account_type', '=', 'equity_unaffected')]`
with subformula `-sum`.
This correctly captures the balance of all 14x accounts and any `equity_unaffected` accounts,
which covers the standard year-end affectation workflow.
opw-5883505
Forward-Port-Of: odoo/odoo#253559This update resolves an issue where Google Ads cookies were not being blocked effectively within Odoo's website configuration. The fix addresses a technical limitation in how the system handles script insertion, ensuring that Google Ads tracking scripts are properly blocked as intended. This improves user privacy and aligns with data protection regulations.
Original PR description
# How to reproduce - Go to Website app > Configuration > Websites > Select your website > Custom Code - In the "Custom <head> code" section add the script given at the last section of this PR (with a…
# How to reproduce
- Go to Website app > Configuration > Websites > Select your website > Custom Code
- In the "Custom <head> code" section add the script given at the last section of this PR (with a proper TAG_ID)
- Go to a new Incognito Tab and go to the Website front page
- Refuse the optionnal cookies
- Open the browser's console and go to Application > Storage > Cookies
# The problem
The Google Ads cookies are present (prefixed by _ga)
# Why
This commit introduced the blocking of 3rd party cookies :
https://github.com/odoo/odoo/commit/958b41c4acec7e1700ca4d6e0b25ee0ad2aac9f1
It works by doing 2 things, but none of them works in our case :
First, it edits the view rendering to replace the `src` value with "about:blank" for watched
tags, but this does not work for `website.custom_code_head` (our case) and `website.custom_code_footer` because it is t-out'ed which bypasses this code :
https://github.com/odoo/odoo/commit/958b41c4acec7e1700ca4d6e0b25ee0ad2aac9f1#diff-a27798e1ecfe96676dd48766e0aa9d12fbc0784e328ac1a3ec82b1ce199fc58bR121-R166
Second, it adds a script in the head of the page that patches the setter for the `src`
property of the script tags. If the value that we try to set is a URL to a site that we
block and the cookies are not yet accepted, we replace the `src` value with "about:blank".
https://github.com/odoo/odoo/blob/e906eb23d698061f146ba67aae420eb7bb5e8a68/addons/website/static/src/js/content/cookie_watcher.js#L8
This sadly does not work for parser-inserted scripts that are directly parsed from the HTML.
Indeed, they do not use the setter of `HTMLScriptElement.prototype`.
It is possible to verify this by adding a `MutationObserver` that checks for new script
insertions and adding breakpoints in this observer and in the patched setter. For the
first scripts of the page, the breakpoint in `MutationObserver`is triggerred while the
one in the setter is not.
# Proposed solution
We move this code into new helper functions :
https://github.com/odoo/odoo/blob/95dc247ecd773044ef9c9f1512c7d86d73df836c/addons/website/models/ir_qweb.py#L130-L135
And use these helper functions to create another helper function that allows us to check
an html field for trackers that would need to be removed
We then use this helper function on `website.custom_code_head` and `website.custom_code_footer`
# The script
```html
<!-- Google tag (gtag.js) -->
<script async src="[https://www.googletagmanager.com/gtag/js?id=TAG_ID"></script](https://www.googletagmanager.com/gtag/js?id=TAG_ID%22%3E%3C/script)>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'TAG_ID');
</script>
```
Source : https://developers.google.com/tag-platform/gtagjs
opw-6007810
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#256808This update resolves a minor typo that was causing an error in the PEPPOL integration process. The fix ensures the system handles errors correctly, improving the reliability of data exchange related to PEPPOL compliance. This change is considered low impact.
Original PR description
Correction in a typo from the last commit opw-6102471 Forward-Port-Of: odoo/odoo#258456
This update resolves an issue where attendance records were incorrectly flagged as 'already checked-in' due to incorrect timezone calculations during absence detection. The fix ensures accurate timezone handling, preventing these errors and improving the reliability of attendance tracking, particularly for employees in different time zones.
Original PR description
### Steps to reproduce: - Have a database in timezone America/Asuncion for example - Create an employee - Create an attendance for the day before yesterday from 13h to 19h - Run the absence detection cron - An error will be raised saying the user is already checked-in on that day ### Cause: When trying to create an absence attendance we localized yesterday's midnight into UTC and then apply the employee timezone. Which cause a one-day shift when having a timezone behind UTC as at that point we try to create an attendance on the day before yesterday not yesterday ### Fix: We use the timezone of the employee to localize midnight then get this time in UTC. opw-5930309 Forward-Port-Of: odoo/odoo#258230 Forward-Port-Of: odoo/odoo#257932
A recent update to our UBL export process previously hid the 'Export XML' button for certain invoices. This fix ensures the button appears only when an invoice is actually exportable, improving the user experience and preventing confusion. This change was made to align with updated export functionality.
Original PR description
Problem --------- Since the UBL export refactor, it was not possible to export the XML of non-imported bills and not self-bills. The Export XML option had been removed from the list view in odoo/odoo#255289. The Form view was omitted. Solution --------- Show the button "Export XML" only if the move can actually be exported. opw-6083344 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258512 Forward-Port-Of: odoo/odoo#257910
This update resolves an issue where reopening a Point of Sale (PoS) after an archived combo product caused an error. The change ensures that archived combo products no longer trigger this error, improving PoS stability and preventing potential disruptions to sales operations. This fix maintains data integrity and a smoother user experience.
Original PR description
Before this commit, when a combo product was archived, and the PoS was reopened, an error was raised. opw-5952006 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes a warning message appearing on Odoo.sh production branches during module updates. Previously, the update process was flagged with a warning due to logging a temporary field change. This change lowers the log level to DEBUG, aligning with other processes and ensuring Odoo.sh branches consistently show a green, healthy status.
Original PR description
Description of the issue/feature this PR addresses: During a module update (-u ModuleName), the check introduced by #220983 patches temporarily a field with "company_dependent=True" because the…
Description of the issue/feature this PR addresses: During a module update (-u ModuleName), the check introduced by #220983 patches temporarily a field with "company_dependent=True" because the overriding module is not loaded yet. But currently it is logged as a warning and makes Odoo.sh production branch appears in yellow (warning state), while the update is actually fine. Current behavior before PR: Logs may contain warnings such as: - Patching res.partner.ref with company_dependent=True - Patching product.template.sale_ok with company_dependent=True - Patching product.product.default_code with company_dependent=True even though there is no actual issue (ok normal behavior) The main problem is that this makes Odoo.sh production branches appear not with green status, while the update module is actually fine. Desired behavior after PR is merged: Keep the same mechanism, but lower the log level from WARNING to DEBUG. This aligns the behavior with the "translate=True" patch logic, which is already logged at DEBUG. Having the production branches green. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258444 Forward-Port-Of: odoo/odoo#258326
This update prevents a bug where changing a child company's ZATCA API mode would inadvertently reset and unboard the parent company's related sales journal. The fix ensures that journal resets only apply to the company being modified, improving data stability and preventing unexpected disruptions.
Original PR description
**Steps to reproduce:** * Install `l10n_sa_edi` module. * Create a parent company and a child company, both with the same VAT number. * Onboard the parent company's Sales journal with ZATCA. *…
**Steps to reproduce:**
* Install `l10n_sa_edi` module.
* Create a parent company and a child company, both with the same VAT number.
* Onboard the parent company's Sales journal with ZATCA.
* Onboard the child company's Sales journal with ZATCA. Create a journal for the child if there is no journal.
* Change the child company's ZATCA API mode to any other mode.
**Observed behavior:**
* Changing the child company's API mode resets and unboards the parent company's Sales journal as well.
**Cause:**
* In `res.company.write`, when `l10n_sa_api_mode` changes, journals to reset are fetched using `_check_company_domain(company)`.
* `account.journal` uses `check_company_domain_parent_of`, which returns journals where `company_id` is a parent of the given company — so passing a child company also matches journals belonging to the parent.
**Fix:**
* Replace `_check_company_domain(company)` with a direct `('company_id', '=', company.id)` filter, so only journals strictly owned by the company being modified are reset.
opw-6099340
Forward-Port-Of: odoo/odoo#258750
Forward-Port-Of: odoo/odoo#258006This update fixes an issue where kit products were incorrectly calculating their total cost in POS orders. The fix ensures that component quantities are accurately converted between UoMs, resulting in correct pricing and inventory calculations for kits containing components with different unit measurements. This improves the accuracy of sales transactions.
Original PR description
When selling a kit that use component with different UoM than the base component UoM, no conversion was done to compute the correct qty of component used in the kit, which lead to a wrong total cost on the pos order. Steps to reproduce: ------------------- * Create a component A with a cost of 12000€ * Set the UoM for the component A to "dozen" * Create a kit product K with a BoM the use 1 "unit" of A * At this point the cost of the kit K should be 1000€ * Now make a PoS order for 1 K and validate it > Observation: The total cost of the kit is not correctly computed, it should be 1000€ Why the fix: ------------ When computing the qty_per_kit, we were not doing the conversion between the product UoM and the BoM line UoM. opw-6039809 Forward-Port-Of: odoo/odoo#257068
This update optimizes a key process that calculates cumulative balances, which significantly reduces memory consumption and prevents server crashes when handling large volumes of accounting data. By focusing the query on relevant records, the change dramatically improves performance and stability, especially with extensive transaction histories.
Original PR description
The _compute_cumulated_balance() method performs a query over every existing move lines to get a dict associating the record id with the cumulated sum at this point. When there is a lot of move…
The _compute_cumulated_balance() method performs a query over every existing move lines to get a dict associating the record id with the cumulated sum at this point. When there is a lot of move lines, the result returned by fetchall() hits the memory limit and the server crashes. We propose to encapsulate the original query to only return the result for the account move lines present in self. Benchmarks --------------- The following benchmarks were generated with a customization of the account.move.line list view to display the cumulated_balance field. Memory usage during the self.env.cr.execute and the dictionary population: | Operation | Before the fix | After the fix | |---------------|----------------|---------------| | populate dict | 1.5 GB | 17.1 MB | | execute query | 430 MB | 8.3 MB | 100 000 lines were displayed at the same time to get a significant size. So the number of records in self is more than 7 000 000 without the fix and 100 000 with the fix. Time spent in the _compute_cumulated_balance method: | No of AML | Before the fix | After the fix | |-----------|----------------|---------------| | 7 000 000 | 10.4 s | 6.8 s | opw-6053720 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#256658 Forward-Port-Of: odoo/odoo#255780
This update fixes a frustrating user experience where accessing restricted record notifications would result in an error. Now, users are automatically redirected to their inbox when attempting to view notifications for records they don't have access to, providing a smoother workflow.
Original PR description
Currently, when a user clicks on a notification in the messaging menu relating to a record they don't have access to, an access error occurs. This PR changes this behavior so that the user is redirected to the inbox instead. task-5374528 Forward-Port-Of: odoo/odoo#258126
This update fixes an issue where session reports for Point of Sale (PoS) orders with decimal quantities displayed excessive decimal places. The fix ensures that report totals are rounded to the standard two decimal places, providing more accurate financial reporting. This improves the reliability of sales data.
Original PR description
When selling a lot of product with different quantities (quantities with decimals) the session report total by category might have a lot of decimals instead of 2. Steps to reproduce: ------------------- * Open PoS * Make an order with a lot of product and modify the quantities to have random values with decimals * Close the session * Generate the session report > Observation: The total qty by category has a lot of decimals instead of the 2 expected. The same error also happens for the total price Why the fix: ------------ We round each value with their respective precision to make sure we don't have 15 decimals. opw-6039016 Forward-Port-Of: odoo/odoo#257885 Forward-Port-Of: odoo/odoo#256038
4 changes
Resolved issues and error corrections
This update adjusts the FFE (Fonds voor Financiële Inlichtingen) rates used in the Belgian payroll calculations to reflect the latest figures for 2026. This ensures accurate payroll processing and compliance with Belgian tax regulations. The change is a technical fix to maintain current reporting.
Original PR description
Forward-Port-Of: odoo/enterprise#113426
This update resolves an issue where the LU reports were incorrectly showing only the first product with a missing internal reference. The change ensures all products with missing internal references are now displayed, improving data accuracy for Luxembourgian reporting. This aligns with requirements for complete and accurate financial reporting.
Original PR description
This is one of several commits fixing the FAIA xml export. The internal reference must be set for all products reported in the FAIA report. When there are multiple products missing this field, our previous code only reported the first ID to the customer. This commit shows the customer all incorrectly configured products. opw-5427296 Forward-Port-Of: odoo/enterprise#113452
This update resolves an issue where invoice reports were generating incorrect debit and credit totals due to negative values in invoice line amounts. The fix ensures that debit and credit calculations are accurate by using absolute values, preventing validation errors and improving report reliability. This impacts financial reporting accuracy.
Original PR description
This is one of several commits fixing the FAIA xml export: - #113452 - #113455 - #113846 When an invoice line has a negative `price_unit`, the `Invoice/Line/InvoiceLineAmount/Amount` element has a negative value. This causes validation errors when comparing the total debit or credit values (such as `SalesInvoices/TotalDebit`) to the individual amounts, as the sum of individual "debit" lines will include some credit amounts and vice versa. Solution: record if the line is actually a debit or a credit, then use the absolute value of the balance in the Amount element. opw-5427296 [Link](https://www.odoo.com/odoo/unassigned-tasks/5427296) Forward-Port-Of: odoo/enterprise#113316
This update resolves a warning message that appeared when generating payslips for employees with contracts that partially overlapped with the payslip period. The fix ensures that a warning only appears when there's a true overlap, aligning with the behavior in version 19. This improves the user experience and prevents unnecessary alerts.
Original PR description
Bug reproduction: 1 - Select Hong Kong (actually there is nothing about Hong Kong, you can select other companies as well) 2 - Create an employee and make its contract from 01-01-2025 to 05-03-2026…
Bug reproduction:
1 - Select Hong Kong (actually there is nothing about Hong Kong, you can select other companies as well)
2 - Create an employee and make its contract from 01-01-2025 to 05-03-2026 (DD/MM/YYYY) format.
3 - Generate payslip for March, the warning of "The period selected does not match the contract validity period" popups.
4 - But we do not want that, even though there is 1 overlapping day in contract with payslip we can continue.
Bug cause:
1 - In >= v.17 (not in v.19), there was a warning, when the contract dates do not fully contains the payslip dates, the warning was appearing.
2 - In v.19 it is not the case, when there is a contract that overlaps at least one dat of the payslip then we are fine, if no overlap then no contract on payslip warning should appear
Bug solution:
1 - I replaced old warning "The period selected does not match the contract validity period" with the one in v.19 "No running contract over payslip period"
Tests:
1 - There was a unit test about old warning (test_payslip_warnings), I changed that parts.
2 - I added further steps to the existing test about the new warning that should appear (No running contract over payslip period)
Last Test Update:
1 - I noticed that contract date changes was not affecting the warning appearance directly
2 - Unit test is expanded with contract date change and observing the warning appearance
Note: Implemented feature: need to check what happens after v.17, should be removed in v.19 latest, maybe before as well.
task - 6006693
Forward-Port-Of: odoo/enterprise#113566
Forward-Port-Of: odoo/enterprise#11275814 changes
Resolved issues and error corrections
This update resolves an issue where POS users needed administrator access to close sessions after a sale, specifically within the German + Fiskaly POS setup. The fix removes unnecessary security checks, allowing users with standard POS rights to close sessions without requiring elevated permissions. This improves the user experience for German customers using the POS.
Original PR description
In German location with Fiskaly setup. POS users hit an AccessError on read when closing the session from the frontend, then had to finish closing in the backend with admin (base.group_erp_manager)…
In German location with Fiskaly setup. POS users hit an AccessError on read when closing the session from the frontend, then had to finish closing in the backend with admin (base.group_erp_manager) rights. Steps to reproduce: ------------------- * Enable Germany + Fiskaly POS (l10n_de_pos_cert), with a company registered for Fiskaly * Use a user with POS rights only (no Access Rights) * Open POS, sell, then close the session from the POS UI > Observation: A warning redirects to the back end; manual close shows: insufficient rights to read l10n_de_fiskaly_api_secret on res.company (operation read). Why the fix: ------------ The guard only needs to know whether the company is in the Germany + Fiskaly flow; that is already expressed by l10n_de_is_germany_and_fiskaly(), without reading API credentials. Fiskaly RPC helpers on res.company continue to use sudo() where secrets are required; this change fixes unnecessary reads of protected fields in the tax helper, not the security model of the credentials themselves. opw-6074960
This update fixes an issue where the event ticket download button wasn't appearing for online payments. The fix ensures that necessary data is always set, regardless of the order's status, allowing the button to display correctly and the confirmation email to be sent as expected. This improves the user experience for customers using online payment methods.
Original PR description
**Steps to reproduce:** - Set up an event, go put it's state to Annonced - Set up any online payment method (Demo also triggers the bug) - Go to a PoS that sells the event tickets - Purchase one and…
**Steps to reproduce:** - Set up an event, go put it's state to Annonced - Set up any online payment method (Demo also triggers the bug) - Go to a PoS that sells the event tickets - Purchase one and pay with the online payment method - Once on the ticket screen, the button to download the event tickets is not displayed **Why the fix:** The normal flow only works for offline payment methods, because we check if the ordered is either paid or invoiced before setting all the values needed by the frontend regarding the ticket registration. The problem is that with an online payment method, once we enter the **read_pos_data** method that sets the values for the frontend, the order is still in draft, so we just return without doing anything. We now set the values regardless of the order's status and send the confirmation mail in the same way as if it was an online payment. In the case of an online payment, the mail will be sent by the **action_pos_order_paid** function that is called once the payment is processed. A test might be a bit weird to make as we don't have a bridge for pos_online_payment and pos_event, and that we would need to mock the server's answer to be able to pay for the online payment and check that we have the needed values. So the setup for pos_event would have to be copied into pos_online_payment to test it and it would only be ran if both modules are installed. opw-5438432 Forward-Port-Of: odoo/odoo#249306
This update adjusts the FFE (Fonds voor Financiële Insolventie) rates used in the Belgian HR payroll calculations to reflect the latest figures for 2026. This ensures accurate payroll processing and compliance with Belgian tax regulations for our business users in Belgium. The change is a technical fix to maintain accurate reporting.
Original PR description
Forward-Port-Of: odoo/enterprise#113426
This update ensures that overridden group names within the accounting module are correctly translated into the Odoo POT file. Previously, translations were inconsistent, leading to mismatched strings. This fix resolves a technical issue that guarantees accurate translations across the enterprise version.
Original PR description
The `account_accountant` module overrides the English name of several `res.groups` records owned by `account`. Without `account_accountant`-scoped XMLIDs for those records, the overridden names are never exported into this module's POT file. At runtime, `account`'s translations are loaded instead, which no longer match the overridden English source strings. We fix this by registering additional XMLIDs under `account_accountant` so the overridden names get translated independently. Forward-Port-Of: odoo/enterprise#113413 Forward-Port-Of: odoo/enterprise#112898
This update fixes an issue where Arabic text on invoices was incorrectly formatted in English PDFs. The change ensures parentheses properly wrap Arabic characters, improving readability and accuracy for invoices with Arabic product names. This resolves a display problem impacting international users.
Original PR description
**Problem:** When printing an invoice in English (LTR report) with a product whose name contains Arabic text and parentheses (e.g., لوحة توزيع كهربائية 100 أمبير (شنايدر )), the brackets appear in…
**Problem:** When printing an invoice in English (LTR report) with a product whose name contains Arabic text and parentheses (e.g., لوحة توزيع كهربائية 100 أمبير (شنايدر )), the brackets appear in the wrong position in the generated PDF. **Steps to reproduce:** 1. Create a product named: لوحة توزيع كهربائية 100 أمبير (شنايدر ) 2. Create an invoice with that product 3. Print the invoice PDF in English 4. Observe the brackets are misplaced in the description column **Current behavior:** Parentheses appear detached from the Arabic word they enclose, floating at the wrong end of the text. **Expected behavior:** Parentheses correctly wrap the enclosed Arabic text. **Cause of the issue:** Odoo's report CSS sets `direction: ltr` on elements that are ancestors of the line description span. When CSS `direction: ltr` targets the same element as `dir="auto"`, wkhtmltopdf's WebKit engine lets the CSS rule win, keeping the paragraph base direction as LTR. The Unicode BiDi algorithm then resolves parentheses (neutral characters) using LTR as the base direction, misplacing them. **Fix:** Placing `dir="auto"` directly on the `<span>` that renders the line description — rather than the parent `<td>` — avoids the CSS override. wkhtmltopdf then detects the first strong character (Arabic) and uses RTL as the base direction for that span, allowing the BiDi algorithm to correctly position the brackets. opw-5884712 Forward-Port-Of: odoo/odoo#257881 Forward-Port-Of: odoo/odoo#251190
This update ensures that negative discount values are displayed correctly in both the Sale Order preview (portal view) and the generated PDF reports. Previously, the PDF displayed negative discounts while the portal preview did not, due to a discrepancy in how discounts were checked in the templates. This change aligns the report output with the portal preview for a consistent user experience.
Original PR description
Steps to produce: --- - Install the `Sales` module. - Enable discounts from settings. - Create a Sale Order with a negative discount on an order line. - Preview the Sale Order and click on the view…
Steps to produce: --- - Install the `Sales` module. - Enable discounts from settings. - Create a Sale Order with a negative discount on an order line. - Preview the Sale Order and click on the view details button. Issue: --- - Negative discount values are not shown in the preview (portal view), but they are displayed in the generated PDF. Root cause: --- - At [1], the portal template includes a condition to display discounts only when they are greater than 0, while the report templates lack this check, leading to inconsistent behavior. Solution: --- - Applied the same condition in the report templates to align the PDF output with the portal preview behavior. Before: --- <img width="787" height="136" alt="image" src="https://github.com/user-attachments/assets/d32311be-4aec-4d6f-b905-d5e52f712ba4" /> After: --- <img width="775" height="139" alt="image" src="https://github.com/user-attachments/assets/2614a8ad-dca6-49ca-b720-5c234aa91cf6" /> [1]https://github.com/odoo/odoo/blob/0f463fd247d2f5da79d6ec2b6bec18774f6f600b/addons/sale/views/sale_portal_templates.xml#L539 Enterprise PR: https://github.com/odoo/enterprise/pull/111916 opw-6061568 Forward-Port-Of: odoo/odoo#258614 Forward-Port-Of: odoo/odoo#255735
This update corrects a warning message that appeared when generating payslips for employees with contracts that partially overlapped with the payslip period. The change ensures that a warning doesn't appear when there's a small overlap, aligning with the behavior in version 19. This improves the user experience and prevents unnecessary alerts.
Original PR description
Bug reproduction: 1 - Select Hong Kong (actually there is nothing about Hong Kong, you can select other companies as well) 2 - Create an employee and make its contract from 01-01-2025 to 05-03-2026…
Bug reproduction:
1 - Select Hong Kong (actually there is nothing about Hong Kong, you can select other companies as well)
2 - Create an employee and make its contract from 01-01-2025 to 05-03-2026 (DD/MM/YYYY) format.
3 - Generate payslip for March, the warning of "The period selected does not match the contract validity period" popups.
4 - But we do not want that, even though there is 1 overlapping day in contract with payslip we can continue.
Bug cause:
1 - In >= v.17 (not in v.19), there was a warning, when the contract dates do not fully contains the payslip dates, the warning was appearing.
2 - In v.19 it is not the case, when there is a contract that overlaps at least one dat of the payslip then we are fine, if no overlap then no contract on payslip warning should appear
Bug solution:
1 - I replaced old warning "The period selected does not match the contract validity period" with the one in v.19 "No running contract over payslip period"
Tests:
1 - There was a unit test about old warning (test_payslip_warnings), I changed that parts.
2 - I added further steps to the existing test about the new warning that should appear (No running contract over payslip period)
Last Test Update:
1 - I noticed that contract date changes was not affecting the warning appearance directly
2 - Unit test is expanded with contract date change and observing the warning appearance
Note: Implemented feature: need to check what happens after v.17, should be removed in v.19 latest, maybe before as well.
task - 6006693
Forward-Port-Of: odoo/enterprise#113566
Forward-Port-Of: odoo/enterprise#112758This update resolves an issue where the FAIA report incorrectly displayed only the first product with a missing internal reference. The change ensures all products with missing internal references are now shown to the customer, improving data accuracy and compliance. This is part of a larger effort to fix the FAIA XML export.
Original PR description
This is one of several commits fixing the FAIA xml export. The internal reference must be set for all products reported in the FAIA report. When there are multiple products missing this field, our previous code only reported the first ID to the customer. This commit shows the customer all incorrectly configured products. opw-5427296 Forward-Port-Of: odoo/enterprise#113452
This update resolves an issue where invoice reports were generating incorrect debit and credit totals due to negative amounts. The fix ensures that invoice line amounts are accurately represented, preventing validation errors and improving the reliability of financial reports. This change is part of a larger effort to improve the FAIA XML export.
Original PR description
This is one of several commits fixing the FAIA xml export: - #113452 - #113455 - #113846 When an invoice line has a negative `price_unit`, the `Invoice/Line/InvoiceLineAmount/Amount` element has a negative value. This causes validation errors when comparing the total debit or credit values (such as `SalesInvoices/TotalDebit`) to the individual amounts, as the sum of individual "debit" lines will include some credit amounts and vice versa. Solution: record if the line is actually a debit or a credit, then use the absolute value of the balance in the Amount element. opw-5427296 [Link](https://www.odoo.com/odoo/unassigned-tasks/5427296) Forward-Port-Of: odoo/enterprise#113316
This update corrects a technical issue where Odoo would generate an error when attempting to export XML for financial moves that didn't have a linked commercial partner. The fix prevents a traceback by ensuring that the export process doesn't attempt to access data that isn't present, improving the reliability of the XML generation feature.
Original PR description
Issue: Confirmed move without partner get a traceback while opening the cog wheel Steps to reproduce: - Create a misc move without Partner/commercial partner. - Confirm it - Click on the cog wheel button Current behavior: - Traceback Before commit 48983eb6efdd6690f92f2839eedd39d9a288ab42, looping on `move.commercial_partner_id` prevented calling `_get_ubl_cii_edi_format` on empty records. no-task
This update resolves a validation error that occurred when the partner autocomplete feature attempted to use incorrectly formatted VAT data. The fix silently ignores invalid VAT values returned without IAP credits, ensuring a smoother partner creation process. This improves data accuracy and prevents user frustration.
Original PR description
### Issue: When autocompleting some partners, the returned VAT could be in an invalid format, leading to a validation error You need `base_vat` installed to get the issue ### Cause: The partner autocomplete feature relies on IAP credits for full data retrieval When no credits are available, only the VAT is returned if it was already fetched before In some cases, this VAT value is incorrectly formatted, which triggers a validation error when applied to the partner ### Fix: Invalid VAT values returned by the autocomplete are now ignored to prevent errors Since the correct VAT cannot be retrieved without IAP credits, the value is simply removed ### Steps to reproduce: - Install `l10n_cy` (we need a localization to enable base_vat) - Create a new partner from an invoice - Enter TONYO 360 and select the autocomplete suggestion Before the fix: The VAT field is filled with an invalid value, causing a validation error opw-6030164
This update allows users to bypass the billing address requirement when selling event tickets or services, improving the checkout experience for customers like Eventbrite. A new system parameter enables this functionality for event-related sales, aligning with the understanding that tax information should be based on the event location, not the customer's address.
Original PR description
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 fixes a previous restriction that prevented users from using the quick checkout option when booking events and appointments. We've determined that collecting full billing addresses isn't necessary for these types of bookings, improving the user experience and reducing friction. A system parameter allows businesses to retain full address details if required.
This update fixes an issue where appointment booking descriptions were displayed in the user's language instead of the website's language (French). The fix ensures that appointment details are shown in the correct website language, regardless of the user's language settings, improving the user experience and consistency across the Odoo website.
Original PR description
When booking an appointment, the cart shows the date/time in the partner's language instead of the website's language. `_prepare_order_line_values` uses `self.partner_id.lang`, ignoring the website language and using the user's language instead. Steps to reproduce: 1. Have a website language different than the user's language 2. Go to the website appointment page 3. Book an appointment 4. Check the booking For this case: - Website language: French - User language: English => You will find, "xxx at xx:xx to yyy at yy:yy" instead of "xxx à xx:xx au yyy à yy:yy" Ticket [link](https://www.odoo.com/odoo/action-4043/5931610) opw-5931610 Forward-Port-Of: odoo/enterprise#107698
2 changes
Resolved issues and error corrections
This update enhances the accuracy of invoice imports by adding a key field ('partner') to the query builder for move lines. This resolves issues with unsynchronized values during import, particularly related to invoices, and improves the overall reliability of the system. It's part of a larger community-driven effort to refine import processes.
Original PR description
This commit is part of a bigger commit on the community side- to refactor the import code of BIS3 Invoice to fix various unsynchronized values issues. task-id: 5058687 Forward-Port-Of: odoo/enterprise#108356
This update significantly speeds up the process of searching for attachments within the accounting module. Previously, the search was slow, particularly when dealing with a large number of records. This change optimizes the search method, resulting in a much faster and more efficient system.
Original PR description
The search method is called once per record in self to get the attachments. This is a backport of odoo/enterprise/pull/85346 Benchmark: | No AML in self | Before PR | After PR | |----------------|-----------|----------| | 80 | 100 ms | 4 ms | | 5000 | 3.3 s | 200 ms | Community PR: odoo/odoo/pull/256399 opw-5881026 Forward-Port-Of: odoo/enterprise#112975 Forward-Port-Of: odoo/enterprise#112345
3 changes
Enhancements to existing features
This update creates a direct link between Documents and Project Tasks, resolving a previous issue where attachments and saved documents weren't automatically connected. Now, documents created from Project Tasks will have a clear link back to the task, improving workflow and document management.
Original PR description
Previously, there was no connection between the Documents app and Project Tasks (`project.task`). Attachments added to a task via the chatter were not synced to the Documents app, and documents manually saved from the chatter lacked a link back to the corresponding task. This commit introduces a link between them by posting a message in the created document's chatter, linking it back to the task. This solution is specifically for stable versions. On `master`, we introduce a proper bridge. task-5941719
Resolved issues and error corrections
This update corrects a technical issue in the web_studio report editor where unwanted placeholders were automatically inserted between layout sections. This prevented reports from printing correctly, and the fix ensures that report sections are properly formatted for printing. The change addresses a bug related to how Odoo prepares reports for output.
Original PR description
… sections Before this commit, the html_editor automatically put placeholders between hearder, article and footer nodes (identified with classes) This is caused by odoo/odoo@edf7f7bb0c62978640c181eccb4934855d5d872d. This caused issues because at print time those cracks are not printed because of base/ir_actions_report.py:def _prepare_html (which separates header, footer, and articles to pass them to wkhtmltopdf) After this commit, those placeholders are not present in those cracks. opw-6048955
This update removes an outdated requirement for country information on payment tokens used for subscription invoices. Previously, this restriction caused processing errors, particularly with certain payment providers. This change ensures invoices can be processed correctly, improving subscription billing reliability.
Original PR description
Before this commit, a country was mantadory on the payment token when it was used to pay invoices of subscriptions. This behavior was fetched back from internal code in 15.3. This issue was not visible until recently. Some token are fine without country, the provider allows it but the cron fails to process the sale order when the contract is processed. THis commit remove that old constraint. opw-5268156 task-5349998
14 changes
Resolved issues and error corrections
Currently, customers report errors when connecting or refreshing a Shopee account through the `sale_shopee` module. **Steps to reproduce:** - Install and configure the `sale_shopee` module - Attempt to connect a Shopee account via the onboarding flow - Complete the authorization process **Observed behavior:** An error is raised during the authorization callback, preventing the Shopee account from being connected or refreshed. **Root cause:** In `onboarding.py`, the `shopee_return
Original PR description
Currently, customers report errors when connecting or refreshing a Shopee account through the `sale_shopee` module. **Steps to reproduce:** - Install and configure the `sale_shopee` module - Attempt…
Currently, customers report errors when connecting or refreshing a Shopee account through the `sale_shopee` module. **Steps to reproduce:** - Install and configure the `sale_shopee` module - Attempt to connect a Shopee account via the onboarding flow - Complete the authorization process **Observed behavior:** An error is raised during the authorization callback, preventing the Shopee account from being connected or refreshed. **Root cause:** In `onboarding.py`, the `shopee_return_from_authorization` controller incorrectly uses `utils.with_context(authorization_code=code)`. Since `utils` is an imported Python module, calling `with_context` on it attempts to set the context on the module itself rather than on a model instance, which raises an error. **Solution:** Move the `with_context` call from the `utils` module to the `temp_shop` record, which is the appropriate model instance that needs the context. Additionally, this commit adds regression tests for the controller to prevent future regressions, as this functionality was previously untested. opw-6092524
This update significantly speeds up the process of searching for attachments within the accounting module. Previously, the search was slow, particularly when dealing with a large number of records. This change batches the search, resulting in a dramatic performance improvement, especially for users with many transactions.
Original PR description
The search method is called once per record in self to get the attachments. This is a backport of odoo/enterprise/pull/85346 Benchmark: | No AML in self | Before PR | After PR | |----------------|-----------|----------| | 80 | 100 ms | 4 ms | | 5000 | 3.3 s | 200 ms | Community PR: odoo/odoo/pull/256399 opw-5881026 Forward-Port-Of: odoo/enterprise#112345
This update fixes an issue where vendor bill payments wouldn't automatically update to 'Paid' status, even after the bill was fully paid. The fix ensures that both linked invoices and vendor bills are checked, correctly transitioning payment statuses to 'Paid' for accurate financial reporting. This improves the reliability of our accounting processes.
Original PR description
**Steps to reproduce:** 1. Install `invoice` module. 2. Create a Vendor Bill, confirm it, and register payment. 3. Observe that Bill is marked `Paid`, but Payment status remains `In Process`.…
**Steps to reproduce:** 1. Install `invoice` module. 2. Create a Vendor Bill, confirm it, and register payment. 3. Observe that Bill is marked `Paid`, but Payment status remains `In Process`. **Issue:** When paying a Vendor Bill, the payment remains in the `In Process` state even after the Bill is fully paid, unlike Customer Invoices where the payment correctly transitions to `Paid`. **Cause:** The discrepancy occurs because the system checks linked invoices to update the payment status but fails to check linked bills. In `account.payment`, the `_compute_state` method only checks [reconciled_invoice_ids] to determine if the payment should transition from `In Process` to `Paid`. It ignores `reconciled_bill_ids` (Vendor Bills). **Fix:** Update code to check both `reconciled_invoice_ids` and `reconciled_bill_ids`. If all linked invoices or bills are paid, the payment status is updated to `Paid`. Related PR : [#231243](https://github.com/odoo/odoo/pull/231243/changes#diff-143d17de807d23650088a8c12f0a5b5cc2246b1b51e0bb7634e85247b6e535eaR392) opw-5865798
This update fixes an issue where MyInvois was receiving incorrect invoice amounts for individual POS e-invoices. The change ensures the Total Amount Payable accurately reflects the e-document's total value, aligning with MyInvois requirements and preventing payment discrepancies. This improves data accuracy for tax reporting.
Original PR description
For individual POS e-invoices, the PrePayment Amount was mapped to the payment linked to the invoice. This incorrectly decreased the Total Amount Payable to 0, since POS orders are already paid at the counter. MyInvois tax officer and helpdesk requires that the Total Amount Payable (cbc:PayableAmount) to reflect the total amount of the issued e-document, regardless of prior payments. This commit forces the PaidAmount to 0 for individual POS e-invoices, ensuring the PayableAmount correctly matches the TaxInclusiveAmount as expected by the MyInvois API. task-6057187
This pull request fixes an issue where the Point of Sale system wasn't correctly evaluating complex filtering criteria. The update allows for more precise filtering of products and data within the POS, leading to improved accuracy and efficiency in order processing. This enhancement ensures that sales staff can quickly and reliably find the right products for customers.
Original PR description
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 resolves a validation error in Odoo's accounting module that occurred when users attempted to reconcile payments from different companies. The fix ensures the 'Outstanding Credits/Debits' widget only displays invoices and payments within the same company, improving user experience and preventing incorrect reconciliation attempts.
Original PR description
The invoice outstanding credits/debits widget currently displays all reconcilable items for a partner across the same account, regardless of the company they belong to. In multi-company environments,…
The invoice outstanding credits/debits widget currently displays all reconcilable items for a partner across the same account, regardless of the company they belong to. In multi-company environments, specifically when accounts have been merged, this allows users to see and try to reconcile payments from Company A into an invoice from Company B. This action eventually triggers a validation error stating that entries must belong to the same company. This commit adds a company filter to the widget's logic to ensure only relevant outstanding payments are suggested, preventing cross-company reconciliation errors and improving UX. **Description of the issue/feature this PR addresses:** This PR fixes a validation error in multi-company environments where the invoice_outstanding_credits_debits_widget suggests payments or credit notes belonging to a different company than the current invoice. The issue typically arises when a partner has outstanding transactions in multiple companies and the accounts (e.g., Account Receivable) have been merged, allowing the widget to query lines that are not valid for the current record's company context. **Current behavior before PR:** When viewing an invoice for Company A, the "Outstanding Credits/Debits" widget displays all reconcilable account.move.line records for that partner that match the account type, regardless of their company_id. If a user clicks "Add" on a payment that belongs to Company B, Odoo attempts to reconcile them, resulting in a traceback or a validation error: "Invalid Operation: All tracebacks/entries must belong to the same company." This creates confusion for the end-user, as they are presented with "ghost" credits that cannot actually be applied. **Desired behavior after PR is merged:** The invoice_outstanding_credits_debits_widget (and the underlying logic in account.move) will strictly filter the suggested outstanding items by self.company_id. Users will only see and be able to reconcile payments, credit notes, or debits that belong to the same company as the invoice they are currently processing. This ensures data integrity and a seamless UX in multi-company setups. **Steps to reproduce:** 1) Enable Multi-Company: Ensure you have at least two companies (e.g., Company A and Company B) active in your database. 2) Chart of Accounts Setup: In both companies, use the same account for Receivables (or merge them so they share the same ID/Code if testing a migrated environment). 3) Ensure the account is marked as Allow Reconciliation. 4) Create a Payment in Company B: 5) Post the payment so it remains as an "Outstanding Receipt". 6) Create an Invoice in Company A 7) Confirm/Post the invoice. 8) Check the Widget: Scroll down to the bottom of the Invoice form in Company A. 9) Observe the "Outstanding Credits" widget. The Error: The payment from Company B will appear as an available credit for the invoice in Company A. 10) Click on "Add". A validation error (UserError) will pop up: "All entries must belong to the same company." **video** https://drive.google.com/file/d/1PfBxupP8t-t21wsP2FIgNXFnTP0Zq140/view --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves a problem where electronic invoices (FatturaPA) generated with units of measure containing special characters failed validation. The fix normalizes these characters to ensure the XML complies with the required format, allowing invoices to be correctly submitted. This prevents errors and ensures compliance with Italian tax regulations.
Original PR description
### Issue before this commit: When generating the electronic invoice XML (FatturaPA) with units of measure containing non-standard Unicode characters (e.g. m², m³), the resulting XML fails…
### Issue before this commit: When generating the electronic invoice XML (FatturaPA) with units of measure containing non-standard Unicode characters (e.g. m², m³), the resulting XML fails validation, as these characters are not accepted by the SdI format. ### Steps to reproduce the issue: 1. Download Italian loc + electronic invoicing 2. Activate UoM option in settings 3. Set a product UoM in any unit that has an apex/power of (ex. m2, m3) 4. Invoice this product 5. Create the XML for SdI 6. Check format with Fex > apex is not recognised as a valid character ### Cause of the issue: The UoM name is exported as-is into the XML. Non-standard Unicode characters are preserved during formatting and are not compatible with the allowed character set defined by the FatturaPA specifications. ### Reason to introduce the fix: Ensure that units of measure are normalized into a compatible representation before being included in the XML, so that the generated file complies with SdI validation rules. opw-6075119 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#257012
This update fixes an issue where sale orders were incorrectly using the analytic account from one company instead of the correct company's project. The change ensures that sales orders accurately reflect the project and company associated with the product, improving financial reporting across multiple companies. This resolves a discrepancy in how analytic distributions are calculated.
Original PR description
Pre-requisites: ------------------------------------------ 1. Install `sale_project` and `project_account_budget` modules 2. Have two companies configured in the system 3. Enable Timesheets from the…
Pre-requisites:
------------------------------------------
1. Install `sale_project` and `project_account_budget` modules
2. Have two companies configured in the system
3. Enable Timesheets from the Settings app
4. Create two projects (one for each company)
5. Ensure the following settings are enabled on both projects:
* Timesheets
* Billable
Steps to Reproduce:
------------------------------------------
1. Switched to Company A
2. Create a product with:
* Type: Service
* Create on Order: Task
* No company restriction
3. Set the product's `project_id` to Company A's project
4. Switch to the newly created company (Company B)
5. Set the product's `project_id` to Company B's project
6. Enable Analytic Distribution from SOL Optional
7. Create a sale order with the configured product, and delete the auto-fetched
Analytic Distribution account for the sale order (Company B's project)
8. Now confirm the sale order
Observation:
----------------------------------------
The SOL's analytic distribution uses the analytic account from Company A's project instead of Company B
Issue:
----------------------------------------
The `project_id` field on `product.template` is `company_dependent=True`, meaning it stores different values per company. However, in `_compute_analytic_distribution()`, the code accesses `line.product_id.project_id` without calling `with_company`, so it resolves the field using the wrong company context
Solution:
----------------------------------------
using `with_company()`, the correct company context is applied when accessing
`project_id`, preventing inconsistencies in multi-company environments and
ensuring the appropriate project is used for the corresponding company.
opw-5864452This update corrects a bug in the leave balance report that was miscalculating employee leave balances, particularly with overlapping allocations. The fix ensures accurate reporting by properly accounting for leave periods and handling timezone differences, leading to more reliable leave tracking data. This improves the accuracy of HR reporting.
Original PR description
__ISSUE__: - FIFO balance miscalculation for non-overlapping allocations. cumulative_allocated_days was partitioned globally by (employee, leave_type), but taken_per_allocation scoped leaves to each…
__ISSUE__:
- FIFO balance miscalculation for non-overlapping allocations. cumulative_allocated_days was partitioned globally by (employee, leave_type), but taken_per_allocation scoped leaves to each allocation's date range. This caused the FIFO formula to silently absorb leaves from one period into another's allocation capacity.
ex:
Alloc A (20 days) 2025, taken leaves 15 days
Alloc B (20 days) 2026, taken leaves 5 days
report: 2025: (15 taken), (5 left)
2026: (7 taken), (20 left)
- Left" rows shifted by one year in non-UTC timezones. Allocation date_from/date_to (Date fields) were cast to timestamp as midnight UTC. In negative-UTC /positive-UTC timezones midnight UTC of Dec 31 renders as the prev/next day.
__FIX__:
- detect overlap groups using a running MAX(date_to) and partition the cumulative sums within each overlap group. This way non-overlapping allocations are treated as independent, while overlapping or open-ended allocations still share FIFO within their group.
- offset allocation dates by 12 hours so no timezone can shift them across a day boundary.
- opw-5169606
- opw-5352114This update corrects a technical issue where the PEPPOL endpoint information was being unintentionally overwritten during VAT creation. Now, the PEPPOL endpoint details from the imported file are correctly retained, ensuring accurate integration with PEPPOL services for VAT processing. This prevents data loss and improves the reliability of VAT handling.
Original PR description
Previously, even if the peppol eas and endpoint were found in the imported file, they would be overwritten when writing the vat on the created partner (due to computed fields).
This update resolves a bug on mobile devices where the chat composer would become unresponsive when the navigation menu was open. The fix prevents the navigation menu from stealing focus from the composer, ensuring users can consistently use the chat feature. This improves the mobile chat experience.
Original PR description
**Description of the issue this PR addresses:** On mobile devices, the chat composer becomes unresponsive when the navigation menu `navbar-toggler` is open.…
**Description of the issue this PR addresses:** On mobile devices, the chat composer becomes unresponsive when the navigation menu `navbar-toggler` is open. https://github.com/user-attachments/assets/8ef01ec6-4a44-41d3-8b86-74f68caf47ef Steps to reproduce: 1. Open the website in a mobile view. 2. Tap the navbar toggler to open the mobile menu. 3. Without closing the menu, open the chat window. 4. Tap on the message composer text area. → The composer is not accessible. This happens because the bootstrap `Offcanvas` (used by the `navbar-toggler`) traps focus by listening for `focusin` events bubbling up to the document. When the composer is tapped, the Offcanvas intercepts the event and immediately steals focus back to itself, dismissing the virtual keyboard. This commit stops the event propagation at the composer level, ensuring the composer can reliably retain focus in responsive views without interference from active menus. Task-[5954657](https://www.odoo.com/odoo/project/1519/tasks/5954657) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#250294
This update fixes an issue where delivery slips incorrectly displayed product prices in the company currency instead of the customer's order currency. This change ensures accurate pricing on delivery slips when orders are placed in foreign currencies, improving financial reporting and customer invoicing. The fix was triggered by a previous code change.
Original PR description
The product value reported on delivery slips may incorrectly use the company currency instead of the order currency. Steps to reproduce: - Enable multi-currency and create a foreign currency - Create a pricelist in the foreign currency - Create and confirm a Sale Order using that pricelist - Add a delivery via carrier (eg. Fedex) - Confirm the delivery and generate the commercial invoice. Issue: The 'sale_price' on the stock move lines is taken in company currency rather than order currency. opw-6104130
This update resolves an issue where hidden fields within masonry blocks in the website editor were still visible. The fix involves applying a higher priority CSS rule to ensure the 'display: none' style is consistently applied, preventing it from being overridden. This ensures hidden fields truly disappear as intended.
Original PR description
# How to reproduce - Go to the website editor - Add a Masonry block - Add a Form inner block in the Masonry block - Select any fields of the form - Set it's visibility to Hidden - Save # The problem…
# How to reproduce - Go to the website editor - Add a Masonry block - Add a Form inner block in the Masonry block - Select any fields of the form - Set it's visibility to Hidden - Save # The problem The field is still visible. # Cause When a field has its visibility set to hidden, it is applied the `.s_website_form_field_hidden` CSS class which applies `display: none`. https://github.com/odoo/odoo/blob/995629db3231de944710751c3184bf1b8b1355c7/addons/website/static/src/snippets/s_website_form/001.scss#L26-L28 But that CSS rule is overriden by the masonry's `.s_masonry_block[data-vcss='001'] .row > div` CSS class. https://github.com/odoo/odoo/blob/995629db3231de944710751c3184bf1b8b1355c7/addons/website/static/src/snippets/s_masonry_block/001.scss#L1-L3 https://github.com/odoo/odoo/blob/995629db3231de944710751c3184bf1b8b1355c7/addons/website/static/src/scss/website.scss#L3246 # Proposed solution We set `display: none` with `!important` to prevent it from being overidden. We also need to add `!important` to its edit mode counter-part so that the field is still visible in that mode. opw-6038955 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update significantly speeds up the process of finding attachments within Odoo, particularly when dealing with a large number of records. Previously, the search was slow, but this change batches the search, resulting in a dramatic performance improvement. This will lead to faster response times and a smoother user experience.
Original PR description
The search method is called once per record in self to get the attachments. This is a backpot of odoo/odoo/pull/209562. Benchmark: | No AML in self | Before PR | After PR | |----------------|-----------|----------| | 80 | 100 ms | 4 ms | | 5000 | 3.3 s | 200 ms | enterprise PR: odoo/enterprise/pull/112345 opw-5881026 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#256399
6 changes
Resolved issues and error corrections
This update resolves an issue where the checkout process became unresponsive when using Avatax with CPF identification. The previous code unnecessarily called external tax APIs, leading to errors that disrupted the checkout flow. This fix removes the unnecessary API call, ensuring a smoother checkout experience.
Original PR description
Issue: --- The extra external_tax call introduced in odoo/enterprise#101579 is causing multiple issues: 1- It doesn't catch errors while `_get_and_set_external_taxes_on_eligible_records` easily raises errors, causing uncatch errors in `website_sale`. 2- Extra unnecessary external api call in non-express checkout methods which is not desirable. Steps to reproduce: --- 1- Install l10n_br_avatax_sale, website_sale 2- Using a public user, add a product to cart and got to checkout. 3- In the address form, use CPF identification type. Outcome: The confirm button is unresponsive. Cause: --- This is due to uncatch error raised by external tax call, while it was not necessary at this step of this flow to call external tax api. opw-6005767
This update fixes a problem where multiple email aliases could lead to duplicate records being created when emails are processed concurrently. The change uses a locking mechanism to ensure only one record is created for each email, regardless of how many aliases receive it. This improves data accuracy and reliability.
Original PR description
Concurrent processing of emails with the same `Message-Id` can create duplicate records. ### Steps to reproduce 1. Configure multiple mail aliases (e.g., two helpdesk teams). 2. Send one email with…
Concurrent processing of emails with the same `Message-Id` can create duplicate records. ### Steps to reproduce 1. Configure multiple mail aliases (e.g., two helpdesk teams). 2. Send one email with both aliases as recipient. The Mail Transfer Agent may invoke `odoo-mailgate.py` once per recipient, resulting in concurrent processing of the same email in separate transactions. We expect one record per alias/team, but duplicates may be created. ### Cause This is a race condition in the `Message-Id` deduplication logic, caused by concurrent transactions and PostgreSQL snapshot isolation. Odoo uses the `REPEATABLE READ` isolation level. This means that each transaction takes a snapshot of the database at its first query and cannot see changes committed by other concurrent transactions. When two concurrent transactions process the same email: 1. Both enter `message_process` and take their snapshot. 2. Both search for the `Message-Id`. Because their snapshots don't include each other's work, both find nothing. 3. Both create records. Even if one transaction commits before the other performs the check, the second transaction still uses its original stale snapshot and create duplicates. ### Fix After the initial duplicate check, attempt to acquire a transactional advisory lock on a hash of the `Message-Id` using `pg_try_advisory_xact_lock`. If another transaction is already processing the same email and holds the lock, the call returns false and the email is treated as a duplicate. If the lock is acquired, processing continues as normal. opw-5116492
This update fixes a technical issue preventing the correct calculation of REAGYP deductions for Spanish tax reporting (SII). The system now includes the REAGYP compensation amount in the required tax quota, ensuring accurate reporting to the AEAT. This ensures compliance with Spanish tax regulations.
Original PR description
Currently, the deducible amount for REAGYP is not passing through to the AEAT. This happens because the REAGYP compensation amount (ImporteCompensacionREAGYP) was missing from the total deductible quota calculation in the SII JSON payload. To fix this, we add 'sujeto_agricultura' to the list that cheks if the tax value for l10n_es is in the list task-6072773 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves an issue where generating timesheets after archiving an employee would trigger an error. The fix prevents timesheets from considering time off requests for previously archived staff, ensuring accurate timesheet generation. This improves data integrity and avoids disruptions to payroll processes.
Original PR description
[FIX] project_timesheet_holidays: Exclude archived employees from time-off # Description of the issue/feature this PR addresses: ## Steps to Reproduce: 1. Create a time off for Employee A (it should…
[FIX] project_timesheet_holidays: Exclude archived employees from time-off # Description of the issue/feature this PR addresses: ## Steps to Reproduce: 1. Create a time off for Employee A (it should affect the timesheets). 2. Create a new public holiday (global time off) that overlaps with Employee A’s time off. 3. Archive Employee A. 4. Delete the public holiday created in step 2. 5. An error related to timesheet generation appears. ## Expected Behavior: - The public holiday / global time off should be deleted without any error. # Desired behavior after PR is merged: ## Fix (Implemented): When regenerating timesheets due to changes in holidays or time off, leaves related to archived employees should not be taken into account. A check was added inside the `_generate_timesheets` function in `project_timesheet_holidays/models/hr_holidays.py` to exclude leaves belonging to archived employees. ## Alternative Fix (Not Implemented): Instead of filtering out leaves linked to archived employees, we could delete those leaves when an employee is archived. However, this approach is not ideal, as archived employees may be reactivated later and would still need their previously requested time off to be preserved. ## Version: This bug appears in both version 17.0 and 19.0. I assumed that it also appears in 18.0 but didn't directly test ## Task: [5474038](https://www.odoo.com/odoo/project/4105/tasks/5474038) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves an AccessError that appeared in Odoo 17.0 when navigating to user records after selecting a single company in the navigation bar. The fix automatically selects the other company and reloads the page, ensuring seamless access to user data. This improves the user experience and prevents disruptions.
Original PR description
### Description of the issue/feature this PR addresses: This error only exists in the 17.0 version - In the 16.0 version, it doesn’t select other companies in the navigation bar and doesn’t give an…
### Description of the issue/feature this PR addresses: This error only exists in the 17.0 version - In the 16.0 version, it doesn’t select other companies in the navigation bar and doesn’t give an access error as well - In the 17.4 and 18.0 versions, it selects other companies in the navigation bar and doesn’t give an access error as well I backported the fix from the below-attached PRs: - https://github.com/odoo/odoo/pull/157399/files#diff-706c5300f0b758ed43a362c85fa84a655c8bae12339bd882e98dc419623facc2R207 - https://github.com/odoo/odoo/pull/160730/files#diff-c28b3e2d6bbe6f94bf95e9cbbe228f61664ca6e1d9a4048f951d8769e2d22752L124 ### Steps to reproduce the bug: 1) Create 2 companies: Company A and Company B 2) Assign Company A to the company_id field on the contact form for Company A. 3) Assign Company B to the company_id field on the contact form for Company B. 4) Create a user and add both companies to the allowed companies in the user record. 5) In the navigation bar, select only one company (e.g., Company A). 6) Attempt to open the user record from the user form, it will give an access error. ### Current Behavior before PR: An AccessError is raised when attempting to open the user record after selecting only one company in the navigation bar. ### Desired behavior after PR is merged: When navigating to a user record after selecting only one company in the navigation bar, the system should: 1) Automatically select the other company [similar to the behavior in version 18] 2) Reload the page before redirecting to the specific user record 3) Open the user record page without giving any access error. opw-4449964 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves an issue where the checkout process became unresponsive when using the l10n_br_avatax_sale module with the Express Checkout feature. The previous implementation caused unnecessary external API calls and error handling problems, leading to a broken confirmation button. This fix removes the problematic call and ensures a smoother checkout experience.
Original PR description
Issue: --- The extra external_tax call introduced in odoo/enterprise#101579 is causing multiple issues: 1- It doesn't catch errors while `_get_and_set_external_taxes_on_eligible_records` easily raises errors, causing uncatch errors in `website_sale`. 2- Extra unnecessary external api call in non-express checkout methods which is not desirable. Steps to reproduce: --- 1- Install l10n_br_avatax_sale, website_sale 2- Using a public user, add a product to cart and got to checkout. 3- In the address form, use CPF identification type. Outcome: The confirm button is unresponsive. Cause: --- This is due to uncatch error raised by external tax call, while it was not necessary at this step of this flow to call external tax api. opw-6005767