Daily updates from Odoo
Wednesday, May 6, 2026
309 changes
25 changes
Resolved issues and error corrections
This update addresses a technical issue that caused kiosk-related tests to fail. The problem stemmed from a missing configuration setting within the Odoo system, specifically the `self_ordering_default_user_id` field. Fixing this ensures that the system can correctly load product information, resolving the access error and allowing the tests to pass.
Original PR description
pos_self_order_* = pos_self_order_bancontact_pay, pos_self_order_qfpay Some kiosk-related tests failed due to an incomplete `pos.config` setup. The `self_ordering_default_user_id` field was not configured, leading to an access error on the `account.tax` model when loading `product.product` fields and relations. --- Task: https://www.odoo.com/odoo/1737/tasks/6183108 Runbot Error: https://runbot.odoo.com/odoo/error/243051
This update resolves a bug that caused bank reconciliation balances to reset to zero after editing a bank statement move line when using multiple currencies. The fix ensures accurate balance calculations during bank reconciliation processes, improving financial reporting reliability.
Original PR description
Fixed an issue where when editing a move line for the bank reconciliation and setting the currency to a currency other than the company's currency if we edit the move line again we will find that the balance is equal to 0. task-6037835 Forward-Port-Of: odoo/enterprise#114898
This update corrects a minor issue where the 'unfold all' option was incorrectly applied during the export of aged receivable reports (like PDFs). This prevented users from seeing all relevant data in the exported reports. The fix ensures the 'unfold all' option functions as intended, providing complete report data.
Original PR description
This commit introduced a small issue: https://github.com/odoo/enterprise/commit/40484f985f511edd7ba2ae759ce63ef564bcf1f7 When exporting a report (the aged receivable in pdf for example), the option key "unfold_all" was set but shouldn't be. Forward-Port-Of: odoo/enterprise#115985
This update resolves an issue causing incorrect rounding when importing purchase orders processed through OCR. The fix restores the original rounding precision, which was designed for EDI processing, rather than the OCR method. This ensures accurate financial data import.
Original PR description
Since commit odoo/odoo@86463ce, there could be rounding issues when importing a purchase order matched through the OCR. A first attempt at fixing this was done in commit odoo/odoo@5dbb814, but it was eventually reverted as deemed too risky for a stable branch. More information about how the rounding error occurred is available in that commit description. This second fix should be much safer, we simply don't disable the rounding precision when the OCR is used, as this was intended for EDI in mind in the first place, not the OCR. opw-[6113387](https://www.odoo.com/odoo/my-support-tasks/6113387) Forward-Port-Of: odoo/enterprise#116141 Forward-Port-Of: odoo/enterprise#116021
This update resolves an issue where Amazon's stock synchronization was failing due to incorrect fulfillment channel data. The system now uses a more reliable field from the Listings API to determine channel availability, defaulting to FBM when necessary to ensure stock updates continue. The change also improves the process for customizing stock updates.
Original PR description
During the upgrade from XML-based feeds to the new JSON Listings API for stock management, we chose to use Amazon's API to fetch a listing's fulfillment channel information. However, Amazon does not…
During the upgrade from XML-based feeds to the new JSON Listings API for stock management, we chose to use Amazon's API to fetch a listing's fulfillment channel information. However, Amazon does not provide a clear answer for a given listing. After some research, we assumed an offer was FBM when the listing contained a `merchant_shipping_group`, because this setting is specific to FBM listings. See also e6d620e4b200cadabb00ce37ab03289cfeb4ae58. This assumption was flawed: Amazon can keep the shipping group even after a listing switches to FBA, which can block stock synchronization. This commit uses the `fulfillmentAvailability` field from the Listings API instead. This field stores the available quantity for each fulfillment channel in which the listing is sold. When multiple fulfillment channels are present, the offer defaults to FBM so stock synchronization can continue. The `sale_amazon_channel_management` module can then be installed to manually select and disambiguate the channel. This commit also upgrades the patching method used to update the FBM stock to ensure user specific configuration aren't overriden during the synchronization. opw-6064896 opw-5152359 Forward-Port-Of: odoo/enterprise#115899 Forward-Port-Of: odoo/enterprise#114473
This update resolves an issue where enabling 'Secure Posted Entries with Hash' on LATAM purchase journals caused posting failures due to document number sequencing. The fix hides this option for LATAM purchase journals, aligning with how vendor-assigned document numbers are handled, and prevents users from creating an incorrect setup.
Original PR description
Steps to reproduce 1. Install l10n_ar (or any LATAM localization). 2. Go to Accounting > Configuration > Journals and open a Purchase journal that has "Use Documents?" enabled. 3. Enable "Secure…
Steps to reproduce 1. Install l10n_ar (or any LATAM localization). 2. Go to Accounting > Configuration > Journals and open a Purchase journal that has "Use Documents?" enabled. 3. Enable "Secure Posted Entries with Hash". 4. Create and post a vendor bill with a high document number (e.g. 00001-00009999). 5. Create another vendor bill with a lower document number (e.g. 00001-00000100) and try to post it. Issue Posting the second vendor bill fails with: "This move could not be locked either because some move with the same sequence prefix has a higher number. You may need to resequence it." The hashing logic in account_journal.py enforces a strict continuous sequential chain per journal: https://github.com/odoo/odoo/blob/89993885823f7309b921145eacc7bbe2c3c1e427/addons/account/models/account_journal.py#L671-L678 In LATAM countries, vendor bill document numbers are assigned by the vendor, not by Odoo. A bill with a lower number can legitimately be entered after one with a higher number, which breaks the sequential assumption the hash chain relies on. Allowing it would produce a hash that no longer represents a proper chain, giving users a false sense of security. Sales journals are unaffected because Odoo controls their sequence. Solution Hide the "Secure Posted Entries with Hash" field on purchase journals that have "Use Documents?" enabled, preventing users from enabling an option that cannot work correctly for vendor-assigned document numbers. Sales journals keep the option available since Odoo controls their sequence. opw-6076673 Forward-Port-Of: odoo/odoo#262614 Forward-Port-Of: odoo/odoo#259206
This update corrects a technical error that prevented proper sorting of partners within the Discuss feature. The fix ensures that partners with email addresses matching search terms are prioritized correctly, enhancing the functionality of this important communication tool. This resolves a previously undetected issue.
Original PR description
In Discuss, the function used to sort partners prioritizes those whose email addresses start with the search terms. However, due to an error in the programming of the corresponding condition, this check could never be true. This commit adjusts the condition so that it behaves as expected. Forward-Port-Of: odoo/odoo#262583
The Gantt view now accurately displays operation durations in hours instead of minutes. This change was triggered by a correction to a formatting issue that had been introduced previously. Users will see more precise and reliable time estimates for work orders within the Gantt view.
Original PR description
Issue ----- In the gantt view, operation duration is displayed as minutes but is actually in hours. Steps to reproduce ----- - Enable work orders - Create a product with a BoM - Add an operation with some duration on the BoM - Creation a MO for the product, confirm & plan - Open the gantt view > Duration is displayed in minutes Cause ----- Overlooked by the rework of formatter done in b764335. Value is in hours but unit is set to "minutes". https://github.com/odoo/enterprise/blob/8281fe6c830dce94ca851bf4bd5c768443721f17/mrp_workorder/static/src/mrp_workorder_gantt_renderer.js#L46-L49 ----- Ticket: opw-6109524 Forward-Port-Of: odoo/enterprise#113829
This update fixes an issue where the CustomGroupByItem dropdown in the search bar wasn't properly styled on hover. The fix ensures the dropdown items appear correctly, enhancing the user experience and visual consistency. It also restores keyboard navigation functionality for this item.
Original PR description
The CustomGroupByItem select was missing the `o-navigable` class, so the navigation system never registered it. On hover, it would not receive the `focus` class, which ensures proper styling of dropdown items. The fix also restores the ability to reach the CustomGroupByItem select with keynav. task-6108677 Forward-Port-Of: odoo/odoo#262608 Forward-Port-Of: odoo/odoo#260675
This update optimizes how Odoo searches for products based on names, significantly speeding up the process. The change utilizes a more efficient query structure to avoid performance bottlenecks when searching across multiple product tables, leading to faster search times. This improves the user experience and overall system responsiveness.
Original PR description
When doing a name_search with positive operators (=, ilike, in) the resulting query combines domains with the OR operator. This works fine when the leaves are all on the same table (product_product…
When doing a name_search with positive operators (=, ilike, in) the resulting query combines domains with the OR operator. This works fine when the leaves are all on the same table (product_product or product_template) as postgresql uses a Bitmap OR when everything is properly indexed.
When leaves are on multiple tables however postgresql has to plan a Seq Scan. For instance, let's take a simple domain on product.product of the form `['|', ('name', 'ilike', 'test'), ('default_code', 'ilike', 'test')]`. Because `name` is an inherited field via `product_tmpl_id`, the resulting query has the where clause `join_table.name ilike %s OR product_product.default_code ilike %s` with `join_table` the table you get after joining product_product and product_template. Since it's an `OR` condition, postgresql does not know in advance whether a given row will pass this condition. There's no way to filter the tables before the join. The condition moves therefore to a `Join Filter` node and postgresql has to scan the whole join table to fetch the correct tuples.
Same thing when there's a subquery. In case of a where clause `cond OR cond OR subquery`, postgresql does not know in advance whether or not a given row is gonna pass the subquery condition. So it has to scan the whole table.
In both cases this becomes a bottlneck when the number of products increaases. This commit introduces the use of `UNION ALL` instead of `OR`. There's one SubPlan for each individual table in the domain. The results are then appended to get the final products matching the conditions. Thanks to each table having its own SubPlan postgresql can now properly hit indexes for each table, greatly improving the performances.
#### speedup
In a database with 2.5M product_product, the name_search on product with a partner_id in the context and the ilike operator goes from 8s -> 5ms.
In another database with 500k product_template, the name_search on template with a partner_id in the context and the ilike operator goes from 1.8s -> 5ms.
opw-4921944
opw-5103287
opw-5049054
opw-5256691
opw-5221753
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#240860
Forward-Port-Of: odoo/odoo#229275This update resolves a previously unpredictable crash in the website caused by a faulty test. The issue stemmed from how a popover component handled closing when the sidebar was closed, specifically when the component was destroyed. This ensures the website remains stable and reliable for users.
Original PR description
The goal of this commit is to fix the `test_10_website_conditional_visibility` test in the website, which has been crashing unpredictably since the dropdown patch in knowledge. This patch does not handle the case where `dropdownActiveEl` and `this.activeEl` are `undefined` because the component has already been destroyed. In our case, we have a popover that closes when the sidebar closes, triggered by clicking the “save” button. error-243073 Forward-Port-Of: odoo/enterprise#115316
This update resolves an issue where manufacturing orders incorrectly flagged missing components, leading to unnecessary consumption alerts. The fix ensures that component compatibility with the specific product variant is now checked before triggering consumption issues, streamlining the production process and preventing false alerts. This improves order accuracy and reduces manual intervention.
Original PR description
Steps to reproduce the bug:
- Create a storable product “P1”:
- Variant: Color -> Red & Blue
- BoM: -Components: - C1: apply on variant Blue - C2: apply on all variant
- Create a manufacturing order to produce one P1 red
- only the move raw C2 is created -> expected behavior
- Confirm the MO
- Try to validate the production
Problem:
A consumption issues is triggered to indicate that C1 is missing
Explication:
When confirming a manufacturing order, we checks if some BoM components are missing and may trigger a consumption issue.
However, the check was done on all BoM lines of the exploded BoM, without verifying whether the component was compatible with the variant being produced.
As a result, a consumption issue could be raised even when the missing component was not supposed to be consumed for the selected variant.
opw-6062762
Forward-Port-Of: odoo/odoo#256655This update fixes an issue where self-order combo prices were inaccurate when multiple quantities of the same combo were ordered. The fix ensures that prices are correctly calculated across all orders, particularly when multiple units of a combo are purchased, resolving a discrepancy between the mobile and restaurant views. This ensures accurate pricing and a better customer experience.
Original PR description
**Steps to reproduce:** - Order a combo in the self order Mobile with multiple products - Order the same combo more than once - Checkout and go to the linked restaurant - Go to the orders, the price…
**Steps to reproduce:** - Order a combo in the self order Mobile with multiple products - Order the same combo more than once - Checkout and go to the linked restaurant - Go to the orders, the price is not the same as in the self - If you check the unit prices in the backend, they are not consistent **Why the fix:** This is mostly a backport of bd117e8 with an addition because the extras still did not work as intended. In the backend, during the price recomputation, we did not account for the fact that we could have a parent line with multiple quantity during the split between the free and the extra lines. This means that we counted too many lines, and had to put some in the extra lines. We then override the price_unit with the total_price in this code https://github.com/odoo/odoo/blob/f73c32960721b046076b91e4bc017ddb924e0837/addons/pos_self_order/models/pos_order.py#L341-L342 But the total price has been computed to zero, so the previously computed price_unit is overridden and set to zero. We now divide the line's qty by the parent line's qty to get the qty per parent line, allowing us to have a qty of more than 1 for the parent line. The same is done for the computation of the remaining amount to pay, as **child.qty** is the number of time the item is selected in the combo * the number of combo ordered, meaning it was messing up the computation. There was an oversight in the original fix, which meant that the unit prices were not distributed as they should have been, even though the total was correct. When we only order one combo that costs 25 and has 2 items, both items will have a price_unit of 12.5, but if we have more than 1 qty of said combo, the price_unit will be all over the place and the second item will have to compensate for the first one thanks to https://github.com/odoo/odoo/blob/b108bb847b1c4d3a91f223d77a4888b8139b0a8d/addons/pos_self_order/models/pos_order.py#L322-L323 We now update the original total to take the fact that multiple combo can be ordered. opw-6076911 Forward-Port-Of: odoo/odoo#261810 Forward-Port-Of: odoo/odoo#257922
This update resolves an issue preventing non-admin internal users from accessing website imports. The fix grants read-only access to the relevant data model, ensuring the website generator systray functions correctly without causing errors. This improves the usability of the website import process for all users.
Original PR description
Steps to reproduce: =================== 1. On a 19.1, launch a website import as admin 2. Log in as a non-admin internal user => AccessError on website_generator.request Cause: ====== The website generator systray polls `website_generator.request` on every page load: https://github.com/odoo/enterprise/blob/0226ad15abc8db70f8e379fddec3d83d15749c85/website_generator/static/src/systray_items/generator_request.js#L48 Only `base.group_system` had access on the model, so any non-admin user hit an AccessError as soon as an import request existed (session_info sets show_scraper_systray=True for everyone based on the last request's notified flag). Solution: ========= Grant read-only access to `base.group_user`; writes/creates stay restricted to system so the import flow itself is unchanged. => Systray loads silently, shows status indicator opw-6092411 Forward-Port-Of: odoo/enterprise#114879
This update prevents users without posting permissions from dragging and dropping files into the chatter window. Previously, this allowed users to upload attachments even if they couldn't contribute to the conversation. This change improves security and usability by restricting file uploads to authorized users.
Original PR description
This commit disables the drag&drop of files into the chatter if the user cannot post on the thread. Part of task-6071789 PR enterprise: https://github.com/odoo/enterprise/pull/115658 Forward-Port-Of: odoo/odoo#262018
This update fixes a minor issue where the 'attach file' button wasn't appearing correctly in the email preview for enterprise users. The change ensures the button is enabled only after the email thread has fully loaded, resulting in a smoother and more reliable user experience. This improves the functionality of the email module.
Original PR description
Wait for the attach file button to be enabled, meaning that the thread is loaded. PR community: https://github.com/odoo/odoo/pull/262018 Forward-Port-Of: odoo/enterprise#115658
This update resolves an issue where Nilvera was not sending recently created invoices to Odoo. The change extends the date range used to fetch invoices by 3 hours (Istanbul time) to account for the time zone difference, ensuring all invoices are synchronized correctly. This prevents data loss and improves the accuracy of invoice processing.
Original PR description
# Description of the issue/feature this PR addresses: Nilvera does not return recently created documents (within ~3 hours), which can lead to missing invoices during synchronization. # Current behavior before PR: The end_date was set to the current time, causing recently created documents to be excluded from the fetch results. # Desired behavior after PR is merged: The end_date is extended by 3 hours (TR GMT+3), ensuring recently created documents are included and not missed during synchronization. task-id: [6123171](https://www.odoo.com/odoo/my-tasks/6123171) I confirm I have signed the CLA and read the PR guidelines at [www.odoo.com/submit-pr](http://www.odoo.com/submit-pr) Forward-Port-Of: odoo/odoo#261626 Forward-Port-Of: odoo/odoo#259306
This update resolves a test failure related to tour completion, specifically when users interact with form views. The fix ensures all popup closures are processed before the tour ends, preventing inconsistencies and improving test reliability. This ultimately contributes to more stable software.
Original PR description
**Issue** Currently, there is an async issue with the test `test_shop_floor_disable_serial_create`that may fail with the following error: "Tour finished with a dirty form view being open. Dirty form views are automatically saved when the page is closed, which leads to stray network requests and inconsistencies." **Cause** Although the tour explicitly closes all popups, the last click on the discard button may not be processed before the tour ends: https://github.com/odoo/enterprise/blob/859e65e8c267701bb19dbff9d24a8c80774dbaa6/mrp_workorder/static/tests/tours/tour_shopfloor.js#L332-L333 runbot-242504 Forward-Port-Of: odoo/enterprise#114367
This update fixes a problem where the softphone tour wouldn't function correctly after opening for the first time. The change ensures the correct tab is displayed and prevents errors during user interactions like searching. This improves the overall user experience for new softphone users.
Original PR description
Commit [1] made the softphone to show recent tab when there are missed calls. Commit [2] changed the demo data to contain 1 missed call. As a result, now when you open the softphone for the first time, you will see recent tab instead of the keypad tab before. This causes issues when a tour starts with switching to, for example, contacts tab, and then do a search for something immediatly. This is because that `input[id='o-voip-Tab-searchInput']` can be found on both recent and contacts tab. It can happen that we do the search before the dom change finished. To avoid that, we add extra check to make sure we have changed to the tab we want. [1]: c995b7df3fc6ff541dc65d8b28661ab03f4a8c08 [2]: f16faa029220ca7152289180c4de78783bab03be
This update fixes an issue where list header labels in odoo spreadsheets weren't properly translated, causing instability with multi-language pivots. The change allows for flexible header labels, ensuring consistent translations across different languages and spreadsheet pivots.
Original PR description
**Description** With odoo/odoo#247578, we were storing static column names in the list definition during migration and list insertion. As a result, list header labels stopped being translatable. This…
**Description** With odoo/odoo#247578, we were storing static column names in the list definition during migration and list insertion. As a result, list header labels stopped being translatable. This was originally done because spreadsheet pivots created from list ranges can break when translated headers change from one language to another. In this commit: - make `string` optional in list column definitions so headers fall back to the translated field display name when no explicit label is stored - keep explicit/custom labels by storing `string` only when a stable header is really needed - update list migration, insertion, and reinsertion flows so they no longer force static labels by default - simplify the list side panel so users can choose between the automatic translated label and a custom stored label - when creating a spreadsheet pivot from a list range in multi-language mode, automatically store the current displayed labels only for the list columns used by that pivot so the pivot stays stable across languages Task: 247578 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes an issue where list header labels weren't properly translated, preventing spreadsheet pivots from working correctly in multiple languages. The change allows for both automatic translation and custom labels, ensuring consistent and accurate translations across all supported languages.
Original PR description
**Description** With odoo/odoo#247578, we were storing static column names in the list definition during migration and list insertion. As a result, list header labels stopped being translatable. This…
**Description** With odoo/odoo#247578, we were storing static column names in the list definition during migration and list insertion. As a result, list header labels stopped being translatable. This was originally done because spreadsheet pivots created from list ranges can break when translated headers change from one language to another. In this commit: - make `string` optional in list column definitions so headers fall back to the translated field display name when no explicit label is stored - keep explicit/custom labels by storing `string` only when a stable header is really needed - update list migration, insertion, and reinsertion flows so they no longer force static labels by default - simplify the list side panel so users can choose between the automatic translated label and a custom stored label - when creating a spreadsheet pivot from a list range in multi-language mode, automatically store the current displayed labels only for the list columns used by that pivot so the pivot stays stable across languages Task: 247578
This update resolves an issue where a delay in website navigation elements (specifically dropdown menus) caused unexpected behavior and test failures. By ensuring the menu fully renders before other actions are taken, the system now provides a more reliable and consistent user experience. This improves overall website stability.
Original PR description
[FIX] website: wait for extra menu to fully render before continuing When clicking on the extra menu item, a Bootstrap dropdown is displayed with a transition. Because this transition takes time, it can lead to undeterministic behavior especially in tests. For example, if a tour clicks on the extra menu item and then clicks on the "Site" button in the navbar, the dropdown transition may still be in progress. This can cause the "Site" dropdown to close prematurely. runbot-240955 Forward-Port-Of: odoo/odoo#262660 Forward-Port-Of: odoo/odoo#261179
This update resolves an issue preventing tours for the purchase and stock modules in the community version of Odoo. The fix leverages an existing utility function to ensure tours correctly launch, regardless of whether the enterprise version is installed. This improves the user experience for all Odoo users.
Original PR description
The tours: - `test_basic_purchase_flow_with_minimal_access_rights` - `test_basic_stock_flow_with_minimal_access_rights` fail to perform the first step if enterprise is not in the addons path since the app icons are not in the the main view. Fortunately, a general util is already present to perform the task of opening the app in both community and enterprise builds: https://github.com/odoo/odoo/blob/e258de4235b4872e0427017e22b46495080c25dc/addons/web_tour/static/src/tour_utils.js#L81-L101 https://github.com/odoo/odoo/blob/e258de4235b4872e0427017e22b46495080c25dc/addons/web_tour/static/src/tour_utils.js#L36-L43 runbot-240934 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#262559
This update corrects a previous issue where HR version searches weren't accurately filtering by start and end dates. The fix ensures searches using date ranges now correctly target the intended date fields, leading to more precise and reliable version searches. This improves the accuracy of HR data retrieval.
Original PR description
Previously, the searches defaulted to delegating the search to the contract_date_start/end fields instead of mapping to the actual computes of date_start and date_end, which caused incorrect results when searching for versions with a specified date_start or date_end. This PR fixes this by implementing the search method on date_start and date_end to correctly map the search to the expected values for date_start and date_end. Task-6067139 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#256581
This update corrects a previous issue where payslips were incorrectly referencing contract dates instead of the correct version dates. The fix ensures payslips accurately reflect the version of the contract being processed, resolving potential discrepancies in payroll reporting. This improvement was enabled by a related update to Odoo's search functionality.
Original PR description
Prior to this commit, the version domain on payslips only looked at the contract dates rather than the version's dates. The domain was fixed in this commit to limit the domain based on the version's dates instead, and this was allowed after the searches on the version date_start and date_end fields were fixed in the odoo/odoo#256581. task-6067139 Forward-Port-Of: odoo/enterprise#113818
24 changes
New functionality added to Odoo
This update prepares Odoo for a change in Belgian accounting regulations. Starting May 1st, a new 'Tax Provision Account' (411800) is being added to handle VAT returns, replacing the previous account. This ensures compliance with updated Belgian tax laws.
Original PR description
Starting May 1st, in Belgium the VAT provision account will replace the current account for periodic returns - Adding the new bank account - Adding a new account 'Tax Provision Account' 411800 Enterprise PR: odoo/enterprise#111599 Task [link](https://www.odoo.com/odoo/project.task/6044017) task-6044017 Forward-Port-Of: odoo/odoo#262715 Forward-Port-Of: odoo/odoo#255272
This update prepares Odoo for a new Belgian VAT regulation, effective May 1st. It introduces a new 'Tax Provision Account' (411800) to align with the required reporting format for periodic VAT returns. This ensures accurate and compliant financial reporting for Belgian businesses using Odoo.
Original PR description
Starting May 1st, in Belgium the VAT provision account will replace the current account for periodic returns - Adding the new bank account - Adding a new account 'Tax Provision Account' 411800 Community PR: odoo/odoo#255272 Task [link](https://www.odoo.com/odoo/project.task/6044017) task-6044017 Forward-Port-Of: odoo/enterprise#116182 Forward-Port-Of: odoo/enterprise#111599
Resolved issues and error corrections
This update resolves an issue where enabling 'Secure Posted Entries with Hash' on LATAM purchase journals caused posting errors due to vendor-assigned document number discrepancies. The fix hides this option for LATAM purchase journals, ensuring data integrity and preventing misleading security indicators. This change only affects LATAM localization modules.
Original PR description
Steps to reproduce 1. Install l10n_ar (or any LATAM localization). 2. Go to Accounting > Configuration > Journals and open a Purchase journal that has "Use Documents?" enabled. 3. Enable "Secure…
Steps to reproduce 1. Install l10n_ar (or any LATAM localization). 2. Go to Accounting > Configuration > Journals and open a Purchase journal that has "Use Documents?" enabled. 3. Enable "Secure Posted Entries with Hash". 4. Create and post a vendor bill with a high document number (e.g. 00001-00009999). 5. Create another vendor bill with a lower document number (e.g. 00001-00000100) and try to post it. Issue Posting the second vendor bill fails with: "This move could not be locked either because some move with the same sequence prefix has a higher number. You may need to resequence it." The hashing logic in account_journal.py enforces a strict continuous sequential chain per journal: https://github.com/odoo/odoo/blob/89993885823f7309b921145eacc7bbe2c3c1e427/addons/account/models/account_journal.py#L671-L678 In LATAM countries, vendor bill document numbers are assigned by the vendor, not by Odoo. A bill with a lower number can legitimately be entered after one with a higher number, which breaks the sequential assumption the hash chain relies on. Allowing it would produce a hash that no longer represents a proper chain, giving users a false sense of security. Sales journals are unaffected because Odoo controls their sequence. Solution Hide the "Secure Posted Entries with Hash" field on purchase journals that have "Use Documents?" enabled, preventing users from enabling an option that cannot work correctly for vendor-assigned document numbers. Sales journals keep the option available since Odoo controls their sequence. opw-6076673 Forward-Port-Of: odoo/odoo#262614 Forward-Port-Of: odoo/odoo#259206
This update resolves an issue where attaching images to invoices could cause system crashes. The fix prevents the system from incorrectly syncing orphaned attachment files, ensuring invoices and PDF generation work reliably. This improves overall invoice processing stability.
Original PR description
Steps to reproduce: - Install documents_account and account_accountant. - Create and post a customer invoice. - Add an image attachment via a log note. - Click Send & Print. -> KeyError:…
Steps to reproduce: - Install documents_account and account_accountant. - Create and post a customer invoice. - Add an image attachment via a log note. - Click Send & Print. -> KeyError: `proforma_pdf_attachment` Cause: When attaching an image via a log note, the file becomes the main attachment but is intentionally unlinked (res_model=False) by the system to avoid UI clutter. Downstream modules unknowingly sync this orphaned file. Later, when "Send & Print" generates the real PDF, the system attempts to update the orphaned downstream record, causing model linkage conflicts and eventually a crash. Solution: Add `no_document=True` to the context during `_message_post_after_hook` for invoices. Previously, for incoming emails or log notes, the mail framework would trigger document creation immediately before the core accounting module could evaluate and orphan invalid files (like images). This change suppresses that premature sync, allowing downstream modules to explicitly handle the sync after the attachment's final state is resolved. opw-5930888 Forward-Port-Of: odoo/odoo#262637 Forward-Port-Of: odoo/odoo#258307
This update resolves a bug where sending invoices with attached images caused a system crash. The fix prevents the incorrect syncing of orphaned image attachments, ensuring stable invoice processing and preventing data inconsistencies. This improves the reliability of the documents account feature.
Original PR description
Steps to reproduce: - Set a journal with documents folder sync. - Create and post a customer invoice. - Add an image attachment via a log note. - Click Send & Print. -> KeyError:…
Steps to reproduce: - Set a journal with documents folder sync. - Create and post a customer invoice. - Add an image attachment via a log note. - Click Send & Print. -> KeyError: `proforma_pdf_attachment` Cause: Adding an image via log note sets it as the main attachment, but it is intentionally orphaned (res_model=False) to prevent UI clutter. `documents_account` incorrectly syncs this unlinked file, creating a workspace document with a missing model. During "Send & Print", the official invoice PDF replaces the image as the main attachment. The document versioning logic intercepts this swap and attempts to re-parent the new PDF to match the orphaned document. This destroys the PDF's linkage to the invoice, causing a crash when the system later attempts to fetch the PDF. Solution: Since the base module now suppresses premature document creation during the message post, we explicitly handle the sync ourselves. We override `_fix_attachments_on_record_from_files_data` to iterate over the validated attachments and trigger document creation only for files that retained their `res_model`. We also add a check inside `_update_or_create_document` to strictly block orphaned attachments. opw-5930888 Forward-Port-Of: odoo/enterprise#116124 Forward-Port-Of: odoo/enterprise#115065
This update resolves an issue preventing non-admin internal users from accessing website import functionality. The fix grants read-only access to a broader group of users, allowing the website generator systray to function correctly without errors. This ensures a smoother experience for all users during website imports.
Original PR description
Steps to reproduce: =================== 1. On a 19.1, launch a website import as admin 2. Log in as a non-admin internal user => AccessError on website_generator.request Cause: ====== The website generator systray polls `website_generator.request` on every page load: https://github.com/odoo/enterprise/blob/0226ad15abc8db70f8e379fddec3d83d15749c85/website_generator/static/src/systray_items/generator_request.js#L48 Only `base.group_system` had access on the model, so any non-admin user hit an AccessError as soon as an import request existed (session_info sets show_scraper_systray=True for everyone based on the last request's notified flag). Solution: ========= Grant read-only access to `base.group_user`; writes/creates stay restricted to system so the import flow itself is unchanged. => Systray loads silently, shows status indicator opw-6092411 Forward-Port-Of: odoo/enterprise#114879
This update fixes a problem where tax amounts weren't accurately adjusted when users grouped lines within a financial transaction. The change ensures that tax calculations are correct after grouping, improving financial reporting accuracy. Additionally, the test suite has been updated to reflect Belgian tax regulations and a related context key has been removed to align with a recent Odoo update.
Original PR description
[FIX] account_edi_ubl_cii: correct tax amount when grouping lines When the user group lines of a move, the tax amount is now corrected if there's a difference in the tax amount before and after grouping This commit also removes the `ungroup_lines` context key, as the flow was changed in odoo/odoo#252458 Reword the `test_import_and_group_lines_by_tax` test: use belgian company and belgian taxes task-5993555 Forward-Port-Of: odoo/odoo#259256 Forward-Port-Of: odoo/odoo#252719
This update fixes an issue where the CustomGroupByItem dropdown in the search bar wasn't correctly styled on hover. The fix ensures the dropdown items are properly highlighted, improving the user experience and accessibility. It also restores keyboard navigation functionality for this item.
Original PR description
The CustomGroupByItem select was missing the `o-navigable` class, so the navigation system never registered it. On hover, it would not receive the `focus` class, which ensures proper styling of dropdown items. The fix also restores the ability to reach the CustomGroupByItem select with keynav. task-6108677 Forward-Port-Of: odoo/odoo#262608 Forward-Port-Of: odoo/odoo#260675
This update resolves an issue where attachments weren't always uploading correctly when navigating between records in the chatter. The fix ensures attachments are properly associated with the intended record, preventing data inconsistencies and improving the user experience. This improves reliability of attachments in conversations.
Original PR description
Currently, when uploading a bunch of attachments or a big one to the chatter, if you click on the pager (e.g. next) before the upload is complete, the attachments that have not yet been uploaded are uploaded to the next record. Due to the persistence of the Chatter component during record navigation and the fact that the `FileUploader` logic is tied to `state.thread`, an async callback that finishes after a record switch will attempt to update the currently active thread rather than the one that initiated the upload. With this change we tie uploader lifecycle to a specific record and ensure the completion callback only affects that record. task-5119290 Forward-Port-Of: odoo/odoo#262714 Forward-Port-Of: odoo/odoo#261552
This update optimizes how Odoo searches for products, particularly when using complex search criteria. By switching from 'OR' to 'UNION ALL' in database queries, the system now efficiently utilizes indexes, resulting in significantly faster search times. This improves the overall responsiveness of product searches, especially with large product catalogs.
Original PR description
When doing a name_search with positive operators (=, ilike, in) the resulting query combines domains with the OR operator. This works fine when the leaves are all on the same table (product_product…
When doing a name_search with positive operators (=, ilike, in) the resulting query combines domains with the OR operator. This works fine when the leaves are all on the same table (product_product or product_template) as postgresql uses a Bitmap OR when everything is properly indexed.
When leaves are on multiple tables however postgresql has to plan a Seq Scan. For instance, let's take a simple domain on product.product of the form `['|', ('name', 'ilike', 'test'), ('default_code', 'ilike', 'test')]`. Because `name` is an inherited field via `product_tmpl_id`, the resulting query has the where clause `join_table.name ilike %s OR product_product.default_code ilike %s` with `join_table` the table you get after joining product_product and product_template. Since it's an `OR` condition, postgresql does not know in advance whether a given row will pass this condition. There's no way to filter the tables before the join. The condition moves therefore to a `Join Filter` node and postgresql has to scan the whole join table to fetch the correct tuples.
Same thing when there's a subquery. In case of a where clause `cond OR cond OR subquery`, postgresql does not know in advance whether or not a given row is gonna pass the subquery condition. So it has to scan the whole table.
In both cases this becomes a bottlneck when the number of products increaases. This commit introduces the use of `UNION ALL` instead of `OR`. There's one SubPlan for each individual table in the domain. The results are then appended to get the final products matching the conditions. Thanks to each table having its own SubPlan postgresql can now properly hit indexes for each table, greatly improving the performances.
#### speedup
In a database with 2.5M product_product, the name_search on product with a partner_id in the context and the ilike operator goes from 8s -> 5ms.
In another database with 500k product_template, the name_search on template with a partner_id in the context and the ilike operator goes from 1.8s -> 5ms.
opw-4921944
opw-5103287
opw-5049054
opw-5256691
opw-5221753
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#240860
Forward-Port-Of: odoo/odoo#229275This update fixes an issue where self-order combo prices were inaccurate when multiple quantities of the same combo were ordered. The fix accurately calculates prices for combos, ensuring consistent pricing across the mobile app and the linked restaurant's order view. This improves the accuracy of transactions and enhances the customer experience.
Original PR description
**Steps to reproduce:** - Order a combo in the self order Mobile with multiple products - Order the same combo more than once - Checkout and go to the linked restaurant - Go to the orders, the price…
**Steps to reproduce:** - Order a combo in the self order Mobile with multiple products - Order the same combo more than once - Checkout and go to the linked restaurant - Go to the orders, the price is not the same as in the self - If you check the unit prices in the backend, they are not consistent **Why the fix:** This is mostly a backport of bd117e8 with an addition because the extras still did not work as intended. In the backend, during the price recomputation, we did not account for the fact that we could have a parent line with multiple quantity during the split between the free and the extra lines. This means that we counted too many lines, and had to put some in the extra lines. We then override the price_unit with the total_price in this code https://github.com/odoo/odoo/blob/f73c32960721b046076b91e4bc017ddb924e0837/addons/pos_self_order/models/pos_order.py#L341-L342 But the total price has been computed to zero, so the previously computed price_unit is overridden and set to zero. We now divide the line's qty by the parent line's qty to get the qty per parent line, allowing us to have a qty of more than 1 for the parent line. The same is done for the computation of the remaining amount to pay, as **child.qty** is the number of time the item is selected in the combo * the number of combo ordered, meaning it was messing up the computation. There was an oversight in the original fix, which meant that the unit prices were not distributed as they should have been, even though the total was correct. When we only order one combo that costs 25 and has 2 items, both items will have a price_unit of 12.5, but if we have more than 1 qty of said combo, the price_unit will be all over the place and the second item will have to compensate for the first one thanks to https://github.com/odoo/odoo/blob/b108bb847b1c4d3a91f223d77a4888b8139b0a8d/addons/pos_self_order/models/pos_order.py#L322-L323 We now update the original total to take the fact that multiple combo can be ordered. opw-6076911 Forward-Port-Of: odoo/odoo#261810 Forward-Port-Of: odoo/odoo#257922
This update corrects a technical issue that caused a traceback when users removed the Unit of Measure (UOM) from a sales order line. The fix prevents unnecessary calculations related to discounts, ensuring smoother operation when a UOM isn't specified. This improves the reliability of the sales order process.
Original PR description
Issue: --- Due to this issue, there is a TB when you try to remove uom. Steps to reproduce: 1- Create a SO and add a line. 2- On SOL, remove uom. You get a traceback. This is because of `ensure_one` here: https://github.com/odoo/odoo/blob/saas-18.4/addons/product/models/product_pricelist_item.py#L588 We can prevent the discount compute on the line which is causing the `compute_price`, when uom is not set. opw-6144426 Forward-Port-Of: odoo/odoo#262266
This update prevents users without write access from dragging and dropping files into the Odoo chatter interface. This enhancement ensures data security and prevents unauthorized file uploads within conversations, aligning with best practices for user permissions. It's part of a broader effort to improve the stability and security of the Odoo platform.
Original PR description
This commit disables the drag&drop of files into the chatter if the user cannot post on the thread. Part of task-6071789 PR enterprise: https://github.com/odoo/enterprise/pull/115658 Forward-Port-Of: odoo/odoo#262018
This update resolves an issue where the 'attach file' button within the enterprise email system wasn't appearing until the email thread was fully loaded. This change ensures users can seamlessly attach files to emails, improving the overall email functionality. It's a small but important fix for a common user experience problem.
Original PR description
Wait for the attach file button to be enabled, meaning that the thread is loaded. PR community: https://github.com/odoo/odoo/pull/262018 Forward-Port-Of: odoo/enterprise#115658
This update resolves an issue where quantities were incorrectly doubled when settling sales orders in POS using the 'Pick then Deliver' warehouse method. The fix ensures accurate lot quantity tracking by filtering move lines correctly, preventing double-counting of inventory. This improves the reliability of sales order fulfillment.
Original PR description
When settling a sale order in POS after validating the delivery, quantities and lots were wrong for lot-tracked products with warehouse "Pick then Deliver (2 steps)": quantity doubled when loading…
When settling a sale order in POS after validating the delivery, quantities and lots were wrong for lot-tracked products with warehouse "Pick then Deliver (2 steps)": quantity doubled when loading SN/Lots. Steps to reproduce: ------------------- * Create a product with Tracking by lots * In Inventory, set warehouse Outgoing Shipments to "Pick then Deliver (2 steps)" * Create a quotation with the product and confirm it * Validate the delivery * In POS, settle the sale order from Quotation/Order * When asked "Do you want to load the SN/Lots linked to the Sales Order?", click Yes > Observation: Quantity doubled. Why the fix: ------------ read_converted() used move_line_ids from all moves linked to the sale line. With 2-step, both pick and delivery moves have move_line_ids with the same lots, so quantities were counted twice. We now use move lines from exactly one picking and filter by sale_line_id. opw-6001585 Forward-Port-Of: odoo/odoo#262237 Forward-Port-Of: odoo/odoo#253539
This update resolves an unexpected crash in the website's testing environment. The issue stemmed from a recent update to the knowledge component, specifically when the sidebar is closed by clicking the 'save' button. This fix ensures the system handles component destruction gracefully, preventing the crash.
Original PR description
The goal of this commit is to fix the `test_10_website_conditional_visibility` test in the website, which has been crashing unpredictably since the dropdown patch in knowledge. This patch does not handle the case where `dropdownActiveEl` and `this.activeEl` are `undefined` because the component has already been destroyed. In our case, we have a popover that closes when the sidebar closes, triggered by clicking the “save” button. error-243073 Forward-Port-Of: odoo/enterprise#115316
This update resolves an issue where a delay in website navigation elements (specifically dropdown menus) could cause unexpected behavior and errors. By ensuring the menu fully renders before other actions are processed, this fix improves the overall stability and reliability of the website experience. This prevents issues like dropdowns closing prematurely.
Original PR description
[FIX] website: wait for extra menu to fully render before continuing When clicking on the extra menu item, a Bootstrap dropdown is displayed with a transition. Because this transition takes time, it can lead to undeterministic behavior especially in tests. For example, if a tour clicks on the extra menu item and then clicks on the "Site" button in the navbar, the dropdown transition may still be in progress. This can cause the "Site" dropdown to close prematurely. runbot-240955 Forward-Port-Of: odoo/odoo#262660 Forward-Port-Of: odoo/odoo#261179
This update resolves an issue causing instability in the Point of Sale (POS) tour experience. By making the tour predictable and correctly selecting the order, the problem is fixed. A minor typo in a test was also corrected to ensure consistent results.
Original PR description
Remove the `undeterministicTour_doNotCopy` key from `OrderFlowTour` and make the tour deterministic by properly selecting the order. Also, fix a typo in the assertion in `test_01_order_flow`. Task-6065459
This update corrects a bug in how HR version searches were performed. Previously, searches were incorrectly using outdated date fields, leading to inaccurate results. This fix ensures searches now correctly utilize the intended date ranges, improving the reliability of HR version searches.
Original PR description
Previously, the searches defaulted to delegating the search to the contract_date_start/end fields instead of mapping to the actual computes of date_start and date_end, which caused incorrect results when searching for versions with a specified date_start or date_end. This PR fixes this by implementing the search method on date_start and date_end to correctly map the search to the expected values for date_start and date_end. Task-6067139 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#256581
This update corrects an issue where payslips were incorrectly referencing contract dates instead of the correct version dates. This change ensures payslips accurately reflect the version of the contract being processed, improving payroll accuracy. This fix was enabled by a related update to Odoo's search functionality.
Original PR description
Prior to this commit, the version domain on payslips only looked at the contract dates rather than the version's dates. The domain was fixed in this commit to limit the domain based on the version's dates instead, and this was allowed after the searches on the version date_start and date_end fields were fixed in the odoo/odoo#256581. task-6067139 Forward-Port-Of: odoo/enterprise#113818
This update resolves an issue where users could unintentionally create links within inline code or code blocks when using the Ctrl+K shortcut. The change ensures that the editor correctly handles selections within code formatting, preventing unwanted link creation and improving the overall user experience. This improves the reliability of the HTML editor.
Original PR description
Description of the issue this PR addresses: This commit ensures that links are not created when the selection is inside inline code or a code block, even when using the Ctrl+K shortcut. task-5489870 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#262778 Forward-Port-Of: odoo/odoo#262397
This update resolves an issue where referenced refunds in Viva.com payments were incorrectly reversing the original payment due to a missing session ID. A previous update inadvertently removed this key information. This fix restores the session ID, ensuring refunds process correctly and accurately reversing the intended payment.
Original PR description
Referenced refunds in Viva.com require the session ID of the original payment to be sent, resulting in that payment being reversed. Unfortunately this functionality was broken when a forward-port PR (odoo/odoo#236004) mistakenly removed the `parentSessionId` field from the request. This commit restores the `parentSessionId` field, fixing the issue. It also adds a tour to test the full payment and referenced refund flow. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#262911 Forward-Port-Of: odoo/odoo#262475
This update resolves an issue where invoices sent via Peppol were failing for customers in Iceland and Albania. The change ensures that VAT numbers for these countries retain their country code prefix, allowing successful invoice transmission. This improves compliance and usability for our international customers.
Original PR description
Current behavior before PR: To send an invoice via Peppol, the customer's VAT must have the country code as a prefix. But while creating customers from countries like Iceland and Albania, It removes the country code prefix. Which later raises an error while sending the invoice that "The VAT of the customer should be prefixed with its country code." Desired behavior after PR is merged: VAT numbers for customers in Iceland and Albania now keep their country code prefix, letting users to send invoices via Peppol. task-6050791 Forward-Port-Of: odoo/odoo#259105
This update fixes an error where the cost of kits was being incorrectly calculated in sales orders. Previously, when ordering a kit with multiple components, the system was multiplying the cost by the batch size, leading to inflated prices. This change ensures accurate kit costing by dividing the total component cost by the kit's quantity.
Original PR description
### Issue: When a kit BoM has `product_qty` > 1 (e.g. 12 Kit X = 12 Comp A + 12 Comp B), the SO line cost after confirmation is multiplied by the batch size. Selling 1 Kit X shows a cost of 360…
### Issue: When a kit BoM has `product_qty` > 1 (e.g. 12 Kit X = 12 Comp A + 12 Comp B), the SO line cost after confirmation is multiplied by the batch size. Selling 1 Kit X shows a cost of 360 instead of 30. ### Cause: The method `_compute_average_price` uses `bom.explode(self, 1)`, which returns raw BoM line quantities for one full batch. It accumulates the total batch cost but returns it without dividing by `bom.product_qty`. ### Steps to Reproduce: - Costing Method = AVCO, Inventory Valuation = Automated - Comp A (cost 10), Comp B (cost 20), Kit X (cost 0) - Kit BoM: 12 Kit X = 12 x Comp A + 12 x Comp B - Create and confirm a SO for 1 x Kit X - Expected SO line cost: 30 - Actual SO line cost: 360 Solution: This fix mirrors the normalization already done in `_compute_bom_price`, which correctly divides by `bom.product_qty` and converts UoMs. opw-5969310 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#259005 Forward-Port-Of: odoo/odoo#253406
11 changes
Resolved issues and error corrections
This update resolves an issue where Spanish invoices with amounts below a certain threshold were incorrectly appearing in the Mod347 BOE export. The fix removes a redundant search process that was adding partners unnecessarily, ensuring only relevant partners are included based on the primary export requirements. This improves the accuracy of the BOE reports for Spanish businesses.
Original PR description
Fix a bug in mod347 BOE export. Steps to reproduce: 1- Create an invoice with a spain Company, with an amount lower than 3 005,06€ 2- Add a Type for mod347 3- Create a cash payment 4- Export the mod347 BOE The partner will appear in the BOE with all line at 0. But this partner shouldn't be in the export. This is due because of a search on account.partial.reconcile, which add partners to the export if a cash payment is found in the period. But this search is not usefully as there is no legal indication that these partners should be in the export in this case, as the partners should only be returned by the main queries. Backport of PR #84317 opw-5960226 Forward-Port-Of: odoo/enterprise#115744 Forward-Port-Of: odoo/enterprise#110947
This update resolves an issue preventing employees from directly modifying their work location within the system's preferences. The change utilizes a specific function to correctly handle access to employee data, addressing a restriction introduced in a previous update. This allows employees to accurately reflect their work arrangements.
Original PR description
**Steps to reproduce** - Have a user without HR rights and linked to an employee - With this user, open Preferences and in the calendar tab and try to change the work location for one of the days - Error: You do not have enough rights to access the field "version_id" on Employee (hr.employee). **Cause** Issue after 72ac4b03657d617644ae75f2957aaec7acf6c1a8 which removed SELF_READABLE_FIELDS and SELF_WRITEABLE_FIELDS. **Change** Use the `field_employee` function introduced in 9605045313953b4c8c734c0d52e8032e3c36bf3a (commit message contains the explanation as to why it is necessary for fields coming from the employee model). opw-6127522
This update resolves an issue where quantities were incorrectly doubled when settling sales orders in POS with the 'Pick then Deliver' warehouse method. The fix ensures accurate lot tracking by filtering move lines correctly, preventing double-counting of inventory. This improves the reliability of sales order settlements.
Original PR description
When settling a sale order in POS after validating the delivery, quantities and lots were wrong for lot-tracked products with warehouse "Pick then Deliver (2 steps)": quantity doubled when loading…
When settling a sale order in POS after validating the delivery, quantities and lots were wrong for lot-tracked products with warehouse "Pick then Deliver (2 steps)": quantity doubled when loading SN/Lots. Steps to reproduce: ------------------- * Create a product with Tracking by lots * In Inventory, set warehouse Outgoing Shipments to "Pick then Deliver (2 steps)" * Create a quotation with the product and confirm it * Validate the delivery * In POS, settle the sale order from Quotation/Order * When asked "Do you want to load the SN/Lots linked to the Sales Order?", click Yes > Observation: Quantity doubled. Why the fix: ------------ read_converted() used move_line_ids from all moves linked to the sale line. With 2-step, both pick and delivery moves have move_line_ids with the same lots, so quantities were counted twice. We now use move lines from exactly one picking and filter by sale_line_id. opw-6001585 Forward-Port-Of: odoo/odoo#262237 Forward-Port-Of: odoo/odoo#253539
This update fixes an issue where the CustomGroupByItem select within the search bar menu wasn't properly styled on hover. The fix ensures the dropdown items appear correctly, enhancing the user experience and visual consistency. It also restores keyboard navigation functionality for this item.
Original PR description
The CustomGroupByItem select was missing the `o-navigable` class, so the navigation system never registered it. On hover, it would not receive the `focus` class, which ensures proper styling of dropdown items. The fix also restores the ability to reach the CustomGroupByItem select with keynav. task-6108677 Forward-Port-Of: odoo/odoo#262608 Forward-Port-Of: odoo/odoo#260675
This update optimizes how Odoo searches for products, specifically when using 'like' operators in domain filters. The change utilizes 'UNION ALL' instead of 'OR', allowing the database to efficiently use indexes and significantly reducing search times. This results in a faster and more responsive product search experience, especially with large product catalogs.
Original PR description
When doing a name_search with positive operators (=, ilike, in) the resulting query combines domains with the OR operator. This works fine when the leaves are all on the same table (product_product…
When doing a name_search with positive operators (=, ilike, in) the resulting query combines domains with the OR operator. This works fine when the leaves are all on the same table (product_product or product_template) as postgresql uses a Bitmap OR when everything is properly indexed.
When leaves are on multiple tables however postgresql has to plan a Seq Scan. For instance, let's take a simple domain on product.product of the form `['|', ('name', 'ilike', 'test'), ('default_code', 'ilike', 'test')]`. Because `name` is an inherited field via `product_tmpl_id`, the resulting query has the where clause `join_table.name ilike %s OR product_product.default_code ilike %s` with `join_table` the table you get after joining product_product and product_template. Since it's an `OR` condition, postgresql does not know in advance whether a given row will pass this condition. There's no way to filter the tables before the join. The condition moves therefore to a `Join Filter` node and postgresql has to scan the whole join table to fetch the correct tuples.
Same thing when there's a subquery. In case of a where clause `cond OR cond OR subquery`, postgresql does not know in advance whether or not a given row is gonna pass the subquery condition. So it has to scan the whole table.
In both cases this becomes a bottlneck when the number of products increaases. This commit introduces the use of `UNION ALL` instead of `OR`. There's one SubPlan for each individual table in the domain. The results are then appended to get the final products matching the conditions. Thanks to each table having its own SubPlan postgresql can now properly hit indexes for each table, greatly improving the performances.
#### speedup
In a database with 2.5M product_product, the name_search on product with a partner_id in the context and the ilike operator goes from 8s -> 5ms.
In another database with 500k product_template, the name_search on template with a partner_id in the context and the ilike operator goes from 1.8s -> 5ms.
opw-4921944
opw-5103287
opw-5049054
opw-5256691
opw-5221753
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#239369
Forward-Port-Of: odoo/odoo#229275This update resolves an issue where custom snippets weren't correctly applying translated content when using the delayed translation feature. The change ensures that translated values are properly reflected in the second language version of a website page, improving the consistency of multilingual content. This fix addresses a bug impacting the website builder's functionality.
Original PR description
The feature "delayed translation" and "copy translation in custom snippet" have been worked on in parallel, but had buggy interactions. This commit changes the way translations terms are copied in custom snippets to read and write the translated values as expected with delayed translations. Steps to reproduce: - With a page with some content on a website in 2 languages - Open the website builder in the main language - Drop a custom snippet - Save - Bug: The change is immediate on the version in the second language (instead of being only available after user translated it) Delayed translations: 2d08f97c0778469b409fca23f2be5f5a98ce3df8 Copy translation in custom snippet: d3426b7714012e833caae10281cfb8433223299a Re-enabling delayed translations: 03a85b13b2c46ef7174123d902e95d5103031c6c task-5474184 Forward-Port-Of: odoo/odoo#245850
This update fixes an issue where the table menu options weren't updating when users switched to different cells. The change ensures that the menu accurately reflects the current target cell by updating values in real-time. This improves the user experience and prevents incorrect menu options being displayed.
Original PR description
After this commit [1], setup is executed only on the initial mount of the table menu and not on subsequent target cell changes. As a result, colItems, rowItems, and other values found in setup become stale, causing the menu to display options that do not reflect the current target cell. This commit moves the necessary values from setup into useEffect so they update correctly when the target cell changes. task-6111986 [1]: https://github.com/odoo/odoo/commit/7d523d6402c9bff3c2e4bcd0329f486a2d0f45ec Backport of Commit https://github.com/odoo/odoo/commit/729c45ddf3d1e377507d93997c5ca45984d64d75 Forward-Port-Of: odoo/odoo#260435 Forward-Port-Of: odoo/odoo#258590
This update prevents users without write permissions from dragging and dropping files into the Chatter interface. This improves security and prevents accidental file uploads to restricted conversations. The change ensures that only authorized users can contribute files to chatter threads.
Original PR description
This commit disables the drag&drop of files into the chatter if the user cannot post on the thread. Part of task-6071789 PR enterprise: https://github.com/odoo/enterprise/pull/115658 Forward-Port-Of: odoo/odoo#262018
This update resolves an issue where the 'attach file' button wasn't appearing correctly in the email testing environment. The fix ensures the button is enabled only after the email thread has fully loaded, improving the user experience and preventing errors when attempting to attach files.
Original PR description
Wait for the attach file button to be enabled, meaning that the thread is loaded. PR community: https://github.com/odoo/odoo/pull/262018 Forward-Port-Of: odoo/enterprise#115658
This update fixes an issue where the product carousel displayed fewer than 16 products when a product had over 256 variants. The fix removes a previous workaround that artificially increased search limits, allowing the carousel to accurately display products with a large number of variations. This ensures a better user experience when browsing products with many options.
Original PR description
# How to reproduce - Create a Product with more than 256 variants - Publish it to the website - Go to the website and add a Product Carousel - Set it to display newest products & hide variants # The…
# How to reproduce - Create a Product with more than 256 variants - Publish it to the website - Go to the website and add a Product Carousel - Set it to display newest products & hide variants # The problem Fewer than 16 products are displayed # Cause This issue was already adressed by this commit : https://github.com/odoo/odoo/pull/195857 But because of limitations for specifically the "Newest Products" filter (cf. original commit message), the fix was only a workaround. Indeed, it increased the search limit to 256 before filtering out the variants, which caused problems when there was more than 256 variants. But since then, big changes made in 19.0 has allowed us to implement a better fix : https://github.com/odoo/odoo/commit/e3b062e5d3820 # Proposed Solution Since we can now pass the model in the options : https://github.com/odoo/odoo/blob/b5069328734e623c12b0de50a177d501f7f0c995/addons/website/models/website_snippet_filter.py#L90 We give "product.template" when the `hide_variants` option is enabled and we filter on products. This allows use to remove the whole workaround that needed increase the limit on product searchs then getting their templates. A recent commit blocks passing "product.template" since it does not have a dedicated snippet filter : https://github.com/odoo/odoo/pull/257208/changes/8e264ae4ea6ae16bbd410ac384733ff8759938a6 But in the commit message, they mention that this targets snippet in single-record mode, which is not our case. So, we move the logic to only be applied for single-record filters opw-6054059 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#260340
This update resolves a problem where Nilvera was not sending recently created invoices to Odoo. The change extends the date range used to fetch invoices by 3 hours to align with Nilvera's timezone (Istanbul), ensuring that all invoices are synchronized correctly. This prevents data loss and improves the reliability of the integration.
Original PR description
# Description of the issue/feature this PR addresses: Nilvera does not return recently created documents (within ~3 hours), which can lead to missing invoices during synchronization. # Current behavior before PR: The end_date was set to the current time, causing recently created documents to be excluded from the fetch results. # Desired behavior after PR is merged: The end_date is extended by 3 hours (TR GMT+3), ensuring recently created documents are included and not missed during synchronization. task-id: [6123171](https://www.odoo.com/odoo/my-tasks/6123171) I confirm I have signed the CLA and read the PR guidelines at [www.odoo.com/submit-pr](http://www.odoo.com/submit-pr) Forward-Port-Of: odoo/odoo#259306
3 changes
Resolved issues and error corrections
This update resolves an issue where international shipments (World Express Pro) through the BPost module were not automatically completing the required custom declaration paperwork. Now, the system correctly fills out this section, ensuring compliance and smoother shipping processes for international orders. This change addresses a previous gap in functionality.
Original PR description
Before this commit, the bpost module was not filling the custom declaration in case of international shipping (World Express Pro) After this commit, the section is filled opw-4932970 Forward-Port-Of: odoo/enterprise#114218 Forward-Port-Of: odoo/enterprise#101476
This update corrects an issue where payslips were incorrectly linked to contract dates instead of the correct version date. The fix ensures payslips accurately reflect the version they belong to, improving payroll accuracy and reporting. This change was enabled by a related update to Odoo's search functionality.
Original PR description
Prior to this commit, the version domain on payslips only looked at the contract dates rather than the version's dates. The domain was fixed in this commit to limit the domain based on the version's dates instead, and this was allowed after the searches on the version date_start and date_end fields were fixed in the odoo/odoo#256581. task-6067139
This update fixes an issue where subscription delivery dates were incorrectly displayed as the previous day due to timezone differences. The change ensures delivery dates are accurately calculated based on the company's timezone, resolving a potential scheduling problem for subscription orders. This improves the reliability of delivery planning.
Original PR description
Steps to reproduce 1. Set the company's partner timezone to a negative UTC offset (e.g. America/Argentina/Buenos_Aires, UTC-3). 2. Create a sale order for a storable subscription product and confirm…
Steps to reproduce 1. Set the company's partner timezone to a negative UTC offset (e.g. America/Argentina/Buenos_Aires, UTC-3). 2. Create a sale order for a storable subscription product and confirm it. 3. Open the generated delivery order and check its Scheduled Date. Issue The scheduled date on the first delivery renders as the previous day. `_prepare_procurement_values` writes `date_planned` as `current_period_start`, which is a plain `fields.Date` value (https://github.com/odoo/enterprise/blob/ba41d7de3c0474286e3e9319710fdacfb95d3e2c/sale_subscription_stock/models/sale_order_line.py#L156). When a `date` is stored in the `Datetime` column `stock.move.date`, Odoo anchors it at midnight UTC; in any negative-offset timezone this renders as the previous day (e.g. `2022-03-02 00:00 UTC` shows as `2022-03-01 21:00` in UTC-3). The non-subscription path does not hit this because it resolves `date_planned` through `_expected_date()`, which returns `order_id.date_order` — a full `Datetime` set to `fields.Datetime.now()` at confirmation (https://github.com/odoo/odoo/blob/996702b0d5c518db2ac6f0b144e7835b27c29736/addons/sale/models/sale_order_line.py#L1398). The same midnight-UTC drift also affects later recurrences, where `current_period_start` falls back to `last_invoice_date` — another `Date`. Solution Split the two cases explicitly: - First delivery (`last_invoice_date` unset): set `date_planned` to `order_id.date_order`, matching the non-subscription flow. - Subsequent deliveries: localize `last_invoice_date` at `00:00` in the company timezone before converting back to UTC, reusing the pattern already applied to reordering rules (https://github.com/odoo/odoo/blob/20a0eee2d03293564320c268252a0353781d99ea/addons/stock/models/stock_orderpoint.py#L722). opw-6133831 Forward-Port-Of: odoo/enterprise#115100
5 changes
Resolved issues and error corrections
This update resolves an issue where internal transfers using multi-step routes in the RO edi stock batch module were incorrectly flagging a missing delivery carrier. The fix ensures that carrier validation is skipped for internal movements, streamlining the process and preventing unnecessary errors. This improves the efficiency of internal stock transfers.
Original PR description
### Issue: With `l10n_ro_edi_stock_batch`, internal transfers using multi-step routes were requiring a delivery carrier This makes no sense for internal moves ### Cause: The method…
### Issue: With `l10n_ro_edi_stock_batch`, internal transfers using multi-step routes were requiring a delivery carrier This makes no sense for internal moves ### Cause: The method `_compute_l10n_ro_edi_stock_enable` was overridden to check for `not picking.batch_id` However, for multi-step delivery routes, internal pickings still triggered the carrier validation, as no check on the `picking_type` was performed ### Steps to reproduce: - Install `l10n_ro_edi_stock_batch` with demo data and switch to RO Company - In Settings, enable `Multi-Step Routes` - Set the RO Warehouse's Outgoing Shipments to `Pick then Deliver (2 steps)` - Create a Product (e.g. RO product) - Create a Delivery Method (e.g. RO Delivery, Partner: Any, Delivery Product: RO Product) - Create and Confirm a Sale Order for the RO Product - From the Sale Order, click Delivery and validate the picking ### Before the fix, internal transfers raised: `The picking RO Co/PICK/00001 is missing a delivery carrier.` enterprise-PR: https://github.com/odoo/enterprise/pull/114166 opw-5925087 Forward-Port-Of: odoo/odoo#257293
This update resolves an issue that prevented users from modifying warehouse routes in the Romanian (RO) accounting module. The problem stemmed from incorrect data handling when updating routes, causing a system error. This fix ensures that warehouse route changes can now be made without interruption.
Original PR description
### Issue: When changing the routes of a Romanian warehouse, an error is raised, blocking any modification of multi-step routes ### Cause: The code attempts to access `in_type_id` from `warehouse_data` However, when updating routes, `warehouse_data` is empty in the method `_create_or_update_sequences_and_picking_types` This leads to a crash because the code assumes that `warehouse_data` always contains `in_type_id` and `out_type_id` Additionally, even if the data were present, it would result in creating duplicate `stock.picking.type` records ### Steps to reproduce: - Install `l10n_ro_saft_stock` with demo data and switch to `RO Company` - Enable `Multi-steps Routes` in Settings - Try to modify Incoming or Outgoing Shipments on a warehouse - When saving, the following error is raised: "Oh snap! in_type_id" odoo-pr: https://github.com/odoo/odoo/pull/257293 opw-5925087 Forward-Port-Of: odoo/enterprise#114166
This update fixes an issue where manually adjusting lot quantities during manufacturing order production didn't always reflect the intended changes. The fix ensures that the specified lot quantities are correctly used when producing, preventing discrepancies in stock levels. This improves the accuracy of manufacturing processes.
Original PR description
**Issue** Lots manually indicated on stock move lines can be overridden when producing a Manufacturing Order. **Steps to reproduce** - Create a storable product P tracked by lot - Create two lots for…
**Issue** Lots manually indicated on stock move lines can be overridden when producing a Manufacturing Order. **Steps to reproduce** - Create a storable product P tracked by lot - Create two lots for product P with 2 units each - Create a MO for a product consuming two units P and confirm it - On the raw move, manually set 1 unit for each lot - Click on "Produce All" - Check the move line associated to the product P -> 2 units associated to the first lot consumed instead of 1 unit each **Cause** While producing: https://github.com/odoo/odoo/blob/0fe2023dc57b6cc02bd399d3c8fc5d6c8ed6e833/addons/mrp/models/mrp_production.py#L2109-L2110 It sets the quantities: https://github.com/odoo/odoo/blob/0fe2023dc57b6cc02bd399d3c8fc5d6c8ed6e833/addons/mrp/models/mrp_production.py#L2246 This calls `_set_quantity_done_prepare_vals` with a qty of 2: https://github.com/odoo/odoo/blob/0fe2023dc57b6cc02bd399d3c8fc5d6c8ed6e833/addons/stock/models/stock_move.py#L2264 which will, for each move line: - Take the quantity indicated by move line: https://github.com/odoo/odoo/blob/0fe2023dc57b6cc02bd399d3c8fc5d6c8ed6e833/addons/stock/models/stock_move.py#L2274 https://github.com/odoo/odoo/blob/0fe2023dc57b6cc02bd399d3c8fc5d6c8ed6e833/addons/stock/models/stock_move.py#L2296-L2297 - Then take all the available quantity left for the lot associated to the move line: https://github.com/odoo/odoo/blob/0fe2023dc57b6cc02bd399d3c8fc5d6c8ed6e833/addons/stock/models/stock_move.py#L2302-L2309 https://github.com/odoo/odoo/blob/0fe2023dc57b6cc02bd399d3c8fc5d6c8ed6e833/addons/stock/models/stock_move.py#L2326-L2327 Instead of first taking all the quantity indicated by the move line, before checking available quantity **Solution** Assume that raw move lines being created in mrp without changing the producing quantity are manually created opw-5946439 Forward-Port-Of: odoo/odoo#259678 Forward-Port-Of: odoo/odoo#257258
This update resolves a technical error preventing the correct submission of Dutch VAT returns (SBR) for businesses with multiple branches under a single VAT unit. The fix ensures that only the relevant closing entry is used, avoiding a system error that previously blocked the SBR process. This improves the reliability of the VAT return submission.
Original PR description
In a multi-company/multi-branch setup where multiple entities form a single VAT unit, Odoo generates a closing entry for each branch/company during the tax closing process. When attempting to submit the Dutch VAT return via Digipoort (SBR), the wizard gathers these entries via `closing_move_ids`. However, the code subsequently tries to set the resulting recordset as `closing_entry_id` on `l10n_nl_reports.sbr.status.service`, which results in a traceback: `ValueError: Expected singleton: account.move(id1, id2, ...)` This occurs because `closing_entry_id` is a `Many2one` which requires a single record (singleton), but the system provides all closing moves from the tax group. This commit fixes the issue by filtering the closing moves to only target the one associated with the return company, ensuring a singleton is passed to the message posting logic. Issue introduced by: 647699eeb4b8a1cc37ca074fa57844871c5086c1 opw-6106081
This update fixes an issue where payment reminders weren't being sent to newly duplicated subscriptions. The root cause was a shared 'last_reminder_date' field, preventing new reminders from being triggered. The fix sets this field to 'false' for copied subscriptions, ensuring reminders are sent as expected.
Original PR description
Payment reminders are not sent to the duplicate of a subscription when a reminder has already been sent for the original subscription Steps to reproduce: 1. Install Subscriptions 2. Create a new…
Payment reminders are not sent to the duplicate of a subscription when a reminder has already been sent for the original subscription Steps to reproduce: 1. Install Subscriptions 2. Create a new subscription for customer Acme Corporation with product Office Cleaning Service (SUB), a Monthly recurring plan and in the Other Info tab, set the subscription Start Date to one week ago 3. Confirm the subscription 4. Go to Scheduled Actions and run the action "Sale Subscription: send reminder for subscriptions with no token" 5. Go back to the previously created subscription (see that a reminder email has been added in the chatter) 6. Duplicate the subscription and confirm the duplicate 7. Run the action "Sale Subscription: send reminder for subscriptions with no token" again 8. There are no reminder for the duplicate subscription Issue: The copy of a subscription uses the same `last_reminder_date`, preventing payment reminders to be sent here https://github.com/odoo/enterprise/blob/5a2ab62254cd5f684a3b1a0d7c0001b888c70d08/sale_subscription/models/sale_order.py#L2114-L2120 Solution: Set `copy=False` on the field `last_reminder_date` opw-6167356 Forward-Port-Of: odoo/enterprise#115509
8 changes
Resolved issues and error corrections
This update resolves a duplication issue in the French Profit and Loss report by removing a redundant account (6492) from the calculation. The fix ensures accurate financial reporting for French businesses using Odoo Enterprise, aligning with proper accounting practices. This was built upon previous work to avoid duplicate accounts.
Original PR description
This commit is an addon to this commit[[1]] where we tried to avoid duplicate accounts in the Profit And Loss report. The problem is that we don't exclude the separated account 6492 from the original one (649). This commit adds the removal of this account in the report formula. task-6053784 Here is the coverage: [Profit and loss account (FR) - Accounts Coverage Report (2).xlsx](https://github.com/user-attachments/files/27011824/Profit.and.loss.account.FR.-.Accounts.Coverage.Report.2.xlsx) The correct separation: <img width="837" height="485" alt="image" src="https://github.com/user-attachments/assets/ebe98976-f689-4389-866a-c9a0c8b50534" /> [1]: https://github.com/odoo/enterprise/commit/4587c49c4b220305652150d2f21a95fb7cfa188d Forward-Port-Of: odoo/enterprise#115060 Forward-Port-Of: odoo/enterprise#114858
This update automatically refreshes the payment screen when the PIS (Payment Initiation System) status changes. Previously, users had to manually refresh the page to see the updated status, which was inconvenient. This change ensures a smoother and more reliable payment process for users.
Original PR description
There were some buttons like sign payment that were visible even when the PIS status was signed which needed a manual page refresh for the update to reflect, now it's reflected automatically on the PIS status change. task-5417365 Forward-Port-Of: odoo/enterprise#114299
This update corrects a minor error in the automated testing of Odoo's Point of Sale (POS) system. A typo was identified in an assertion within a test case, which prevented the test from running correctly. This fix ensures the accuracy of the testing process and improves the reliability of the POS module.
Original PR description
Correct a typo in `test_01_order_flow` assertions. `pdis_order1` was reassigned multiple times; the second assertion should use `pdis_order2`. Task-6065459
This update prevents subscriptions from being automatically reopened after a manual closure by a salesperson. Previously, approvals or payments could trigger reopening, leading to inconsistencies. This change ensures subscription status remains accurate and reliable, streamlining sales processes.
Original PR description
Before this commit, when a subscription was closed manually by the salesperson, it could be reopened when a transaction was approved or an invoice paid. It could cause issue. In this case, we should not reopen automatically. task-5900481 Forward-Port-Of: odoo/enterprise#106487
This update fixes an issue where payment reminders weren't being sent to newly duplicated subscriptions. The root cause was a shared 'last_reminder_date' field preventing new reminders from being triggered. The fix sets this field to 'false' for copied subscriptions, ensuring reminders are sent as expected.
Original PR description
Payment reminders are not sent to the duplicate of a subscription when a reminder has already been sent for the original subscription Steps to reproduce: 1. Install Subscriptions 2. Create a new…
Payment reminders are not sent to the duplicate of a subscription when a reminder has already been sent for the original subscription Steps to reproduce: 1. Install Subscriptions 2. Create a new subscription for customer Acme Corporation with product Office Cleaning Service (SUB), a Monthly recurring plan and in the Other Info tab, set the subscription Start Date to one week ago 3. Confirm the subscription 4. Go to Scheduled Actions and run the action "Sale Subscription: send reminder for subscriptions with no token" 5. Go back to the previously created subscription (see that a reminder email has been added in the chatter) 6. Duplicate the subscription and confirm the duplicate 7. Run the action "Sale Subscription: send reminder for subscriptions with no token" again 8. There are no reminder for the duplicate subscription Issue: The copy of a subscription uses the same `last_reminder_date`, preventing payment reminders to be sent here https://github.com/odoo/enterprise/blob/5a2ab62254cd5f684a3b1a0d7c0001b888c70d08/sale_subscription/models/sale_order.py#L2114-L2120 Solution: Set `copy=False` on the field `last_reminder_date` opw-6167356 Forward-Port-Of: odoo/enterprise#115509
This update fixes an issue where subscription delivery dates were incorrectly displayed as the previous day due to timezone differences. The change ensures delivery dates are accurately calculated based on the company's timezone, resolving a potential scheduling problem for subscription orders. This improves the reliability of delivery planning.
Original PR description
Steps to reproduce 1. Set the company's partner timezone to a negative UTC offset (e.g. America/Argentina/Buenos_Aires, UTC-3). 2. Create a sale order for a storable subscription product and confirm…
Steps to reproduce 1. Set the company's partner timezone to a negative UTC offset (e.g. America/Argentina/Buenos_Aires, UTC-3). 2. Create a sale order for a storable subscription product and confirm it. 3. Open the generated delivery order and check its Scheduled Date. Issue The scheduled date on the first delivery renders as the previous day. `_prepare_procurement_values` writes `date_planned` as `current_period_start`, which is a plain `fields.Date` value (https://github.com/odoo/enterprise/blob/ba41d7de3c0474286e3e9319710fdacfb95d3e2c/sale_subscription_stock/models/sale_order_line.py#L156). When a `date` is stored in the `Datetime` column `stock.move.date`, Odoo anchors it at midnight UTC; in any negative-offset timezone this renders as the previous day (e.g. `2022-03-02 00:00 UTC` shows as `2022-03-01 21:00` in UTC-3). The non-subscription path does not hit this because it resolves `date_planned` through `_expected_date()`, which returns `order_id.date_order` — a full `Datetime` set to `fields.Datetime.now()` at confirmation (https://github.com/odoo/odoo/blob/996702b0d5c518db2ac6f0b144e7835b27c29736/addons/sale/models/sale_order_line.py#L1398). The same midnight-UTC drift also affects later recurrences, where `current_period_start` falls back to `last_invoice_date` — another `Date`. Solution Split the two cases explicitly: - First delivery (`last_invoice_date` unset): set `date_planned` to `order_id.date_order`, matching the non-subscription flow. - Subsequent deliveries: localize `last_invoice_date` at `00:00` in the company timezone before converting back to UTC, reusing the pattern already applied to reordering rules (https://github.com/odoo/odoo/blob/20a0eee2d03293564320c268252a0353781d99ea/addons/stock/models/stock_orderpoint.py#L722). opw-6133831 Forward-Port-Of: odoo/enterprise#115100
This update corrects an issue where free FSM services with prepaid invoicing were not appearing on invoices. The change adjusts a calculation to ensure these services are correctly reflected when creating invoices, allowing for accurate billing of prepaid FSM tasks. This resolves a previous bug impacting service invoicing.
Original PR description
Changed _compute_qty_to_invoice in industry_fsm_sale, SaleOrderLine to no longer set qty_to_invoice to 0 for free services with prepaid invoicing. Previous changes seem intended for goods. Steps to reproduce: - Create service product with 0 price, prepaid invoice policy, creates FSM task - Create/Confirm sales order with created product - Attempt to create invoice, get 0 quantity to invoice error Current Behavior: Free services linked to FSM tasks do not appear on invoices due to compute 0 qty_to_invoice Expected Behavior: Prepaid Invoice Services linked to FSM tasks appear on invoices. Other invoice policies can be invoiced through the generated sales order lines (timesheets, delivered quantity, etc.) opw-6047992 Forward-Port-Of: odoo/enterprise#113718
This update fixes an issue where users were redirected to a standard form view when opening documents linked through a Many2One field. Now, users can directly access the Kanban or List view for documents, allowing them to preview and navigate documents more effectively, especially when dealing with folders.
Original PR description
Problem: When opening a linked `documents.document` record from a Many2One field added via Studio, the user is redirected to the standard form view. This is problematic because the form view does not allow the user to preview the actual document or navigate into it if the record is a folder. Solution: override `get_formview_action` to open the Kanban/List/Activity views. task-6068437 Forward-Port-Of: odoo/enterprise#113149
5 changes
Enhancements to existing features
This update simplifies the process for users to upload multiple documents directly to requests within Odoo. Previously, this was a complex process, and now it's streamlined by introducing a new document type specifically for requests, improving usability and efficiency. This change also addresses an issue with spreadsheet versioning to prevent unnecessary document creation.
Original PR description
Purpose ======= Allow the users to upload many files on a request. Simplify the code, and prepare the "multi-requests", by adding a new document type for the request, instead of relying on complex conditions: For documents, `type = binary, attachment_id = False, shortcut_document_id = False` Or for shortcuts, `type = binary, shortcut_document_id != False, shortcut_document_id.attachment_id = False` Task-5417444
Resolved issues and error corrections
This update corrects formatting issues in the documentation for a key function within our Point of Sale (POS) platform. This change ensures the documentation adheres to new standards, improving consistency and maintainability. It's a routine update to maintain code quality and align with internal development practices.
Original PR description
This commit fixes the docstring formatting of the `_prepare_order_values_from_data` function. This is to ensure compliance with the docstring linter, which is now enabled for all PoS/IoT modules (see odoo/odoo#262741).
This update resolves an issue where record lines persisted during manual cleaning mode would be skipped when switching to automated mode. By removing these old lines, the system now correctly processes all records through the scheduled cron job, ensuring accurate data cleaning and deduplication. This improves the reliability of automated data processes.
Original PR description
When a model mode (deduplication or cleaning) is changed from manual to automated, previously generated record lines remain. These lines are skipped by automated actions, leading to confusion as they should be processed by the cron. This commit removes existing record lines when switching to automated mode, ensuring they are properly handled during the next cron run. task-5979884
A test related to rental stock management was failing due to demo data. The fix prevents the creation of duplicate 'out of stock' ribbons, which were being triggered by the test's attempt to create a second ribbon with the same configuration. This ensures the test runs successfully.
Original PR description
Currently, running test `test_out_of_stock_ribbon_is_not_applicable_for_rentals` with demo data enabled leads to a validation error: `Only one ribbon with the "assign when out of stock" option is allowed.` This happens because, with demo data loaded, an "out of stock" ribbon is already created via XML data. The test then attempts to create another ribbon with the same configuration, triggering the constraint and causing the failure. Related PR: https://github.com/odoo/enterprise/pull/112660 runbot-[242457](https://runbot.odoo.com/odoo/error/242457) --- Forward-Port-Of: odoo/enterprise#116162
Code cleanup and technical improvements
This update enhances the planning module by changing the `im_status` field from a text box to a predefined selection. This ensures data consistency and aligns with recent changes in the system's logic, preventing incorrect status entries. Unnecessary related fields have also been removed to streamline the module.
Original PR description
Community PR: https://github.com/odoo/odoo/pull/261748 Upgrade PR: https://github.com/odoo/upgrade/pull/10120 This commit converts the `im_status` field from Char to Selection. Because recent refactors restrict this field to a finite set of expected values, using a Selection type better enforces our business logic. This commit also removes unused related fields to `im_status`.
10 changes
Resolved issues and error corrections
A technical issue prevented the confirmation email from being sent correctly when users clicked 'Access Options Anyway'. This update corrects a version mismatch in the email template, ensuring that confirmation emails are delivered with the correct content. This resolves a problem where users received blank emails.
Original PR description
The Confirmation mailing template ships an `s_text_block` section without `data-vxml`. The mass_mailing builder compares it against the canonical snippet's `data-vxml="001"` and flags the block as…
The Confirmation mailing template ships an `s_text_block` section without `data-vxml`. The mass_mailing builder compares it against the canonical snippet's `data-vxml="001"` and flags the block as outdated. Clicking ACCESS OPTIONS ANYWAY in the sidebar leaves the section flagged but saves an empty `body_html`, so the confirmation test email arrives blank. https://github.com/odoo/odoo/blob/b293ce50e0fc9355ffd233557f079916b514eac7/addons/mass_mailing/static/src/builder/plugins/version_control_plugin.js#L23 The section is structurally identical to the canonical snippet and to the version already used by the default theme template, so adding `data-vxml="001"` makes the version check match and the outdated banner is no longer shown. https://github.com/odoo/odoo/blob/b293ce50e0fc9355ffd233557f079916b514eac7/addons/mass_mailing/views/snippets/mass_mailing_text_snippets.xml#L3 https://github.com/odoo/odoo/blob/b293ce50e0fc9355ffd233557f079916b514eac7/addons/mass_mailing/views/themes_templates.xml#L41 Steps to reproduce: 1. Marketing Automation > New > Marketing > Double Opt-in > Create Campaign 2. Open the Templates smart button and click the Confirmation row 3. Click the welcome block in the email body 4. Click ACCESS OPTIONS ANYWAY in the right sidebar 5. Click Test and send to your address => arriving email body is empty Ticket [link](https://www.odoo.com/odoo/project/49/tasks/6143321) opw-6143321
This update resolves a duplication issue in the French Profit and Loss report by removing a mistakenly included account. The fix ensures accurate reporting of financial data for French businesses using Odoo Enterprise. This improves the reliability of financial statements.
Original PR description
This commit is an addon to this commit[[1]] where we tried to avoid duplicate accounts in the Profit And Loss report. The problem is that we don't exclude the separated account 6492 from the original one (649). This commit adds the removal of this account in the report formula. task-6053784 Here is the coverage: [Profit and loss account (FR) - Accounts Coverage Report (2).xlsx](https://github.com/user-attachments/files/27011824/Profit.and.loss.account.FR.-.Accounts.Coverage.Report.2.xlsx) The correct separation: <img width="837" height="485" alt="image" src="https://github.com/user-attachments/assets/ebe98976-f689-4389-866a-c9a0c8b50534" /> [1]: https://github.com/odoo/enterprise/commit/4587c49c4b220305652150d2f21a95fb7cfa188d Forward-Port-Of: odoo/enterprise#115060 Forward-Port-Of: odoo/enterprise#114858
This update resolves an issue where Amazon's stock synchronization was failing due to incorrect fulfillment channel data. The system now uses a more reliable field from the Listings API to determine channel availability, defaulting to FBM when necessary. Users can further manage channel selections using the existing `sale_amazon_channel_management` module.
Original PR description
During the upgrade from XML-based feeds to the new JSON Listings API for stock management, we chose to use Amazon's API to fetch a listing's fulfillment channel information. However, Amazon does not…
During the upgrade from XML-based feeds to the new JSON Listings API for stock management, we chose to use Amazon's API to fetch a listing's fulfillment channel information. However, Amazon does not provide a clear answer for a given listing. After some research, we assumed an offer was FBM when the listing contained a `merchant_shipping_group`, because this setting is specific to FBM listings. See also e6d620e4b200cadabb00ce37ab03289cfeb4ae58. This assumption was flawed: Amazon can keep the shipping group even after a listing switches to FBA, which can block stock synchronization. This commit uses the `fulfillmentAvailability` field from the Listings API instead. This field stores the available quantity for each fulfillment channel in which the listing is sold. When multiple fulfillment channels are present, the offer defaults to FBM so stock synchronization can continue. The `sale_amazon_channel_management` module can then be installed to manually select and disambiguate the channel. This commit also upgrades the patching method used to update the FBM stock to ensure user specific configuration aren't overriden during the synchronization. opw-6064896 opw-5152359 Forward-Port-Of: odoo/enterprise#115899 Forward-Port-Of: odoo/enterprise#114473
This update resolves a bug that caused bank reconciliation balances to reset to zero after editing a bank statement move line when using multiple currencies. The fix ensures accurate balance calculations during bank reconciliation processes, improving financial reporting reliability.
Original PR description
Fixed an issue where when editing a move line for the bank reconciliation and setting the currency to a currency other than the company's currency if we edit the move line again we will find that the balance is equal to 0. task-6037835 Forward-Port-Of: odoo/enterprise#114898
This update resolves an issue where the Intrastat CSV export was failing due to data formatting and database synchronization problems. The fix ensures accurate data is included in the export, addressing a disruption to reporting on Dutch Intrastat data.
Original PR description
Since the technical refactoring of intrastat in 18.0, the csv export in `l10n_nl_intrastat` seems broken. Here is the fixes done in this commit: 1. `Commodity flow` is supposed to be a single diggit (6 or 7) but an empty blank space was hidden. 2. Switching the condition on `country_origin_code` as it was the opposite 3. Add a `flush_all` before calling the report during the export, to be sure the database is up to date. opw-5799126 Forward-Port-Of: odoo/enterprise#116153 Forward-Port-Of: odoo/enterprise#115791
This update resolves a rounding error issue that occurred when importing purchase orders processed through OCR. The fix restores the original rounding precision, which was designed for EDI processing, rather than the OCR method. This ensures accurate financial calculations during import.
Original PR description
Since commit odoo/odoo@86463ce, there could be rounding issues when importing a purchase order matched through the OCR. A first attempt at fixing this was done in commit odoo/odoo@5dbb814, but it was eventually reverted as deemed too risky for a stable branch. More information about how the rounding error occurred is available in that commit description. This second fix should be much safer, we simply don't disable the rounding precision when the OCR is used, as this was intended for EDI in mind in the first place, not the OCR. opw-[6113387](https://www.odoo.com/odoo/my-support-tasks/6113387) Forward-Port-Of: odoo/enterprise#116141 Forward-Port-Of: odoo/enterprise#116021
This update fixes an issue where users without specific permissions couldn't access audit reports linked to knowledge articles. By updating access rules, the system now automatically hides inaccessible audit reports, preventing errors and improving the user experience. This ensures a smoother workflow for all users.
Original PR description
When both `accountant` and `knowledge` are installed, the `accountant_knowledge` module is automatically added and extends the `knowledge.article` model. It introduces a link from articles to audit…
When both `accountant` and `knowledge` are installed, the `accountant_knowledge` module is automatically added and extends the `knowledge.article` model. It introduces a link from articles to audit reports via the `audit_report_id` field (see: `audit_report_id` field). Currently, only users in the `account.group_account_user` group have full CRUD access to audit reports. Users outside this group may encounter access errors when loading an article or a template. This happens because the ORM attempts to read the `audit_report_id` field, but fails due to insufficient permissions on the related model. To resolve this, new access rules and record rules will be introduced on the `audit.report` model so that its permissions are derived from the linked article. The user should then no longer get an access error when loading the `audit_report_id` field from an article or a template. Thanks to these new security rules, audit reports that users cannot access will be hidden from the interface. This improves the overall user experience and prevents errors, such as crashes when attempting to open the article linked to the audit report. opw-6067390
This update resolves a build error in the l10n_ae_faf module related to a dependency issue with a related Odoo module. By adjusting the view's location, the update eliminates the need for the problematic dependency, ensuring the module builds correctly and functions as intended.
Original PR description
the inherited tax view form was raising an error since ubl_cii_tax_category_code is in the view under the module account_edi_ubl_cii and this module is not in the resolved dependencies of l10n_ae_faf but is usually autoinstalled. to fix this we are changing the xpath to be something that doesn't need the dependency of the account_edi_ubl_cii but only account. runbot-239123
This update resolves an issue where setting a maximum package weight in Sendcloud prevented accurate shipping rate calculations. The fix ensures that shipments are correctly split into packages based on weight, allowing for proper rate retrieval and avoiding errors when dealing with products exceeding the maximum deliverable weight.
Original PR description
Issue ----- Putting a max weight on a package type causes getting a rate with Sendcloud to fail. Steps to reproduce ----- - Setup Mondial Relay using Sendcloud - Set a default package type with max…
Issue ----- Putting a max weight on a package type causes getting a rate with Sendcloud to fail. Steps to reproduce ----- - Setup Mondial Relay using Sendcloud - Set a default package type with max weight 2kg - Create a product with a 500g weight - Create a SO with the product - Add delivery - Sendcloud Mondial Relay - Get rate > Impossible to get a rate Cause ----- When retrieving the shipping method to use when retrieving a rate, we use the real weight of the order. https://github.com/odoo/enterprise/blob/cca1433f5a064673b8e007530e20e8a9fe72949b/delivery_sendcloud/models/sendcloud_service.py#L67 https://github.com/odoo/enterprise/blob/cca1433f5a064673b8e007530e20e8a9fe72949b/delivery_sendcloud/models/sendcloud_service.py#L81 However, when making the rate call, we use the value returned by `_split_shipping` https://github.com/odoo/enterprise/blob/cca1433f5a064673b8e007530e20e8a9fe72949b/delivery_sendcloud/models/sendcloud_service.py#L91 which is equal to the maximum weight of the package. This is blocking in some cases, like if - the real weight is 750g - the package max is 2kg - Sendcloud returns a shipping method for [500g;1kg] Asking a rate for this method & a 2kg package will fail (rightfully so). Solution ----- The shipment should be split into packages before retrieving the shipping methods. Otherwise the problem might be the other way around where we retrieve a shipping method for the whole order, only to split it into multiple packages because they don't fit in one. Also, the `shipping_weight` returned by `_split_shipping` should only be different from the order's total weight if it is higher than the maximum deliverable weight. ----- Ticket: opw-5947199
This update resolves an issue where the custom declaration field for international World Express Pro shipments within the BPost module was not being automatically filled. Now, the system correctly populates this critical field, ensuring accurate customs documentation for international orders. This improves compliance and streamlines the shipping process.
Original PR description
Before this commit, the bpost module was not filling the custom declaration in case of international shipping (World Express Pro) After this commit, the section is filled opw-4932970 Forward-Port-Of: odoo/enterprise#114218 Forward-Port-Of: odoo/enterprise#101476
6 changes
Resolved issues and error corrections
This update fixes an issue where CodaBox statements were incorrectly routed to the wrong bank journal due to differing currency settings. The system now prioritizes journals with explicit currency IDs, ensuring statements are accurately assigned to the correct currency-specific account. This prevents financial discrepancies and improves the reliability of CodaBox data integration.
Original PR description
When several journals share the same IBAN but use different currencies, a CODA could land on the wrong journal instead of the currency-specific one. Split the lookup in two passes: first a journal with an explicit currency_id matching the CODA, then fall back to the no-currency journal (qualified by the company currency). Steps to reproduce: - Create 2 bank journals sharing the same IBAN; one without currency and one with USD. - Setup CodaBox connection and retrieve USD statements. - Before this fix: may land on the EUR journal. opw-6048931 Forward-Port-Of: odoo/enterprise#114590
This update fixes an issue where the Master Production Schedule (MPS) displayed dates in UTC, potentially showing dates for tomorrow instead of today. The fix ensures MPS dates are displayed correctly based on the user's configured timezone, allowing users to accurately plan and manage production schedules. This improves usability and reduces potential errors.
Original PR description
# How to reproduce - Set your timezone to one that is very behind UTC (e.g. Etc/GMT-14) - Go to the MPS page - Use the day filter # The problem The first date displayed is in UTC, so it may be tomorrow if you go to the MPS page early in the morning, preventing the user to edit the MPS line for today. # Cause `_date_range_to_str` does not account for timezone. opw-6032156
This update fixes an issue where comment counts on slides weren't accurately reflecting the number of active comments due to changes in how Odoo handles messages. The fix ensures that comment counts are synchronized with the actual number of comments, improving the user experience and data accuracy for course slides.
Original PR description
Steps to reproduce: - Open a slide of a course in non fullscreen mode (website). - Go to the comments tab and add a comment in the chatter. - The comments count does not change in the tab. - The same thing happens when a comment is deleted. - Another way to see the incorrect counter is to add a note in the slide form view (backend). Before this change, `website_slides` used `website_message_ids` to calculate the comments. Since #138233 the old portal chatter has been replaced with the mail chatter and the way messages are displayed on the portal has changed. For example notes are no longer considered portal messages and also deleted messages should not be displayed or counted as such. This change ensures that comments calculations are based on a domain that considers those changes meaning that comments will be synced with the actual number of available comments.
This update fixes a visual issue where the background color of selected table cells wasn't displayed in the toolbar. The changes add a mechanism to calculate and show the correct background color for selected cells, ensuring a more accurate and user-friendly experience when working with tables in the HTML editor.
Original PR description
Before this commit: the background color of selected table cells isn't shown in the toolbar. After this commit: we have a background color processor in the table plugin to calculate the background color of selected cells. The color and background color are also properly reset to update the selected color when selecting an empty table cell. table_selectionchange_handlers is created to make sure the selected color is updated after it. task-5976046 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update corrects a bug preventing invoices from correctly reflecting free FSM services linked to prepaid invoicing. Previously, the system incorrectly set invoice quantities to zero for these services. Now, prepaid FSM services will appear on invoices as expected, ensuring accurate billing for these services.
Original PR description
Changed _compute_qty_to_invoice in industry_fsm_sale, SaleOrderLine to no longer set qty_to_invoice to 0 for free services with prepaid invoicing. Previous changes seem intended for goods. Steps to reproduce: - Create service product with 0 price, prepaid invoice policy, creates FSM task - Create/Confirm sales order with created product - Attempt to create invoice, get 0 quantity to invoice error Current Behavior: Free services linked to FSM tasks do not appear on invoices due to compute 0 qty_to_invoice Expected Behavior: Prepaid Invoice Services linked to FSM tasks appear on invoices. Other invoice policies can be invoiced through the generated sales order lines (timesheets, delivered quantity, etc.) opw-6047992 Forward-Port-Of: odoo/enterprise#113718
This update fixes an issue where product unit prices in sales quotes were not being rounded to two decimal places, leading to inaccurate pricing calculations. The change ensures that unit prices are correctly rounded, aligning with expected business practices and improving quote accuracy. This resolves a reported bug impacting sales quote generation.
Original PR description
### Steps to reproduce: - Download 'Sales' app - Create a product with a sale price of : 208.05 - Create a pricelist with discount rule on the sales price : -35% - Create a new quotation that has the new pricelist and product > The unit price has 4 decimal instead of 2, only the unit price column is affected. ### Cause of Issue: When you add a product to a quotation (or change the price list and click "Update Prices"), `_reset_price_unit()` is called, which calls `_get_tax_included_unit_price_from_price()` https://github.com/odoo/odoo/blob/d73e5662a0af7c549008661f743ba5d51f765339/addons/sale/models/sale_order_line.py#L592-L606 In `_get_tax_included_unit_price_from_price()`, the first 2 if blocks just return the `product_price_unit` without any rounding https://github.com/odoo/odoo/blob/d73e5662a0af7c549008661f743ba5d51f765339/addons/account/models/product.py#L275-L280 opw-6185661
3 changes
Resolved issues and error corrections
This update resolves a technical issue preventing the correct import of product data for the product_unspsc module. The problem stemmed from an outdated requirement in the database system (PostgreSQL) regarding how the 'Header' option is used when importing data. This fix ensures data imports function correctly.
Original PR description
last week this fix deployed https://github.com/odoo/enterprise/pull/112652 https://www.postgresql.org/docs/14/sql-copy.html in older version posgress like 14.0 ``Header`` is only accepting [boolean]…
last week this fix deployed https://github.com/odoo/enterprise/pull/112652
https://www.postgresql.org/docs/14/sql-copy.html
in older version posgress like 14.0 ``Header`` is only accepting [boolean] parameter.
```
Traceback (most recent call last):
File "/tmp/tmpfiag6d7a/odoo/17.0/odoo/service/server.py", line 1374, in preload_registries
registry = Registry.new(dbname, update_module=update_module)
File "<decorator-gen-16>", line 2, in new
File "/tmp/tmpfiag6d7a/odoo/17.0/odoo/tools/func.py", line 87, in locked
return func(inst, *args, **kwargs)
File "/tmp/tmpfiag6d7a/odoo/17.0/odoo/modules/registry.py", line 110, in new
odoo.modules.load_modules(registry, force_demo, status, update_module)
File "/tmp/tmpfiag6d7a/odoo/17.0/odoo/modules/loading.py", line 481, in load_modules
processed_modules += load_marked_modules(env, graph,
File "/tmp/tmpfiag6d7a/odoo/17.0/odoo/modules/loading.py", line 366, in load_marked_modules
loaded, processed = load_module_graph(
File "/tmp/tmpfiag6d7a/odoo/17.0/odoo/modules/loading.py", line 234, in load_module_graph
migrations.migrate_module(package, 'post')
File "/tmp/tmpfiag6d7a/odoo/17.0/odoo/modules/migration.py", line 216, in migrate_module
exec_script(self.cr, installed_version, pyfile, pkg.name, stage, version)
File "/tmp/tmpfiag6d7a/odoo/17.0/odoo/modules/migration.py", line 240, in exec_script
migrate(cr, installed_version)
File "/tmp/tmpfiag6d7a/enterprise/17.0/product_unspsc/upgrades/0.3/post-update-codes.py", line 16, in migrate
cr.copy_expert("COPY _upgrade_product_unspsc_code FROM STDIN WITH (DELIMITER '|', HEADER MATCH)", csv_file)
psycopg2.errors.SyntaxError: header requires a Boolean value
```
detected here
https://upgradeci.odoo.com/upgradeci/run/294631This update corrects a problem where users with specific permissions (marc demo) experienced errors accessing planning records after archiving employees. The fix ensures that pending calculations are properly handled, preventing access issues and maintaining data integrity within the planning module.
Original PR description
- Step to reproduce: with hr_attendance and planning installed, archive an employee with marc demo -> access error on planning records - Cause: some records are recomputed after departure wizard closes using marc demo rights - Solution: flush all pending planning.slot computations from the wizard using .sudo() Task: 6131692
This update corrects a technical issue preventing users from selecting alternative DHL label formats (like ZPL2) when setting the 'Label Format' in the delivery method. The fix ensures DHL label requests are correctly formatted for the API, resolving a problem where labels consistently returned as PDF.
Original PR description
Backport of commit 2b26341 (original PR: #103660) ----- Ticket: opw-6152014