Daily updates from Odoo
Friday, April 24, 2026
156 changes
5 changes
Resolved issues and error corrections
This update resolves a problem where validating deliveries for kit products could trigger errors. The code was adjusted to correctly handle kit explosions during delivery validation, preventing tracebacks and ensuring accurate stock accounting. This ensures deliveries of kit products can be processed without interruption.
Original PR description
**Issue**: Making a product a kit could prevent confirming deliveries. **Steps to reproduce**: - Make sure the account application is installed - Create a product P without kit - Create a SO and…
**Issue**: Making a product a kit could prevent confirming deliveries. **Steps to reproduce**: - Make sure the account application is installed - Create a product P without kit - Create a SO and confirm it - Make the product P a kit - Validate the delivery associated to the SO -> A traceback occurs: the record does not exist anymore **Cause**: While confirming the delivery: https://github.com/odoo/odoo/blob/a253cff9039fcf729a9922b119acad5ec7c7a0bd/addons/stock_account/models/stock_move.py#L168 It first filters which moves are out (`moves_out`). On the move associated with product P, since the kit is not exploded yet: https://github.com/odoo/odoo/blob/a253cff9039fcf729a9922b119acad5ec7c7a0bd/addons/stock_account/models/stock_move.py#L172 Then explodes the kit: https://github.com/odoo/odoo/blob/a253cff9039fcf729a9922b119acad5ec7c7a0bd/addons/stock_account/models/stock_move.py#L174 https://github.com/odoo/odoo/blob/ea18f34a48d61350f80c79894bef66bf02840bfc/addons/mrp/models/stock_move.py#L357-L361 By doing so, the original move associated to the product P are deleted: https://github.com/odoo/odoo/blob/ea18f34a48d61350f80c79894bef66bf02840bfc/addons/mrp/models/stock_move.py#L399 Thus, `moves_out` contains moves that no longer exist, and eventually, and eventually while accessing `product_id`: https://github.com/odoo/odoo/blob/a253cff9039fcf729a9922b119acad5ec7c7a0bd/addons/stock_account/models/stock_move.py#L179 A traceback is thrown **Aditionnal information** Validating a delivery of a kit product whose moves were not exploded will trigger their explosion and require a second validation. Therefore, no stock valuation errors will be created. opw-6063602 Forward-Port-Of: odoo/odoo#260844 Forward-Port-Of: odoo/odoo#258403
This update fixes a bug where the shipping address wasn't appearing on Purchase Order and Request for Quotation (PO/RFQ) reports. The change involves updating how address information is passed within the Odoo system, ensuring that customer shipping addresses are now correctly displayed in these reports. This improves the accuracy of purchase order data.
Original PR description
Version: ---------- - saas-19.2+ Steps to reproduce: ---------------------- 1. Install `stock_dropshipping` and `sale_management` modules. 2. Create a Customer (res.partner) with a proper address…
Version:
----------
- saas-19.2+
Steps to reproduce:
----------------------
1. Install `stock_dropshipping` and `sale_management` modules.
2. Create a Customer (res.partner) with a proper address block.
3. Create a dropship product (route: Dropship).
4. Create a Sales Order for the created customer.
5. Add the dropship product.
6. Confirm the Sales Order to generate a Purchase Order.
7. Open the generated PO/RFQ and print the report.
Issue:
------
The shipping address is missing in the printed PO/RFQ report.
Cause:
--------
The `t-call` syntax is updated to use the new semantic, which passes
values *as attributes/parameters* on the `<t>` (with `t-call`) tag itself,
instead of relying on nested `t-set` directive.
- Old (Deprecated): Used nested `<t t-set='var_name' t-value='x'/>` tags
inside the calling element to define variables.
- New: Variables are passed as attributes directly on the element where
the `t-call` is located (e.g., `<t t-call='module.template' var_name='x'/>`).
A warning is added to alert developers when using the old deprecated
syntax.
see Reference: https://github.com/odoo/odoo/pull/197296
<details>
<summary>Click here to see the results:</summary>
<p><strong>Before:</strong></p>
<div class="image-row">
<img src="https://github.com/user-attachments/assets/c6892b30-10d6-4fb4-881c-1433d4fe07a0" />
</div>
<p><strong>After:</strong></p>
<div class="image-row">
<img src="https://github.com/user-attachments/assets/6109fcc3-5773-44a8-b07b-6566ed855d3f" />
</div>
</details>
> NOTE: We can also move test into `purchase_stock`
----
opw-6075017
---
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#257522This update fixes a bug preventing calendar organizers (like administrators) from receiving reminder notifications. The issue stemmed from an outdated filtering method for identifying internal users, now corrected to ensure all organizers receive timely alerts. This improves meeting management and communication.
Original PR description
Steps to reproduce: --------------------------------- 1. Install Calendar module with demo 2. For both Users: User > Preferences > Notifications > In Odoo 3. Log in through Admin > Calendar > New…
Steps to reproduce:
---------------------------------
1. Install Calendar module with demo
2. For both Users: User > Preferences > Notifications > In Odoo
3. Log in through Admin > Calendar > New meeting
4. Set a start time in the near future
5. Add Marc Demo as an attendee
6. Under Options > Reminders, add a reminder that triggers shortly before the meeting (e.g., 15 minutes)
7. Save the meeting
8. Log in as Marc Demo in another browser window
9. Wait until the reminder time is reached
Observation:
---------------------------------
The reminder notification is displayed for Marc Demo. The Administrator (Mitchell Admin) does not receive any notification.
Issue:
---------------------------------
In `_notify_next_alarm`, the domain
`('group_ids', 'in', self.env.ref('base.group_user').ids)`
was used to filter internal users. However, the admin user does not have
`base.group_user` directly in their `group_ids`, it is only present in `group_ids.all_implied_ids` (inherited through group hierarchy). This caused the admin user to be excluded from the user search, so no bus alarm notification was sent to them.
Solution:
---------------------------------
The `share` field on `res.users` correctly identifies internal users (`share=False`) vs portal/public users (`share=True`) by checking the full group hierarchy, including implied groups. This ensures the admin (and all internal users) receive alarm notifications while still excluding portal and public users.
https://github.com/odoo/odoo/blob/b261223c8e15c412a06a0d938d217bdf0ab9f9ff/odoo/addons/base/models/res_users.py#L459-L464
opw-6010337
Forward-Port-Of: odoo/odoo#255263This update resolves an issue preventing the AI's graph view feature from working correctly. The fix ensures that AI-generated groupings are processed properly, preventing a crash and allowing users to successfully generate and view data visualizations through the 'Ask AI' tool. This improves the usability of the AI-powered insights.
Original PR description
Steps to reproduce:
1. Install `crm`, `sale_management`.
2. Navigate to a list view (e.g. Sales > Orders).
3. Open the "Ask AI" chatbox from the system bar.
4. Ask: "graph view of opportunities per month".
5. [ISSUE] Client traceback after the agent loop tries to open the graph view with groupbys.
The pivot and graph AI tools emitted `rowGroupBys` / `groupBys`, but `search_model_patch` relies on `selectedGroupBys` (the key already used by the list/kanban tools). As a result, groupbys bypassed `applyAISearch` and, for graph, landed as raw `{field_name, intervals}` dicts in `modelParams.groupBy`, where `_normalize` crashed.
Rename the keys to `selectedGroupBys` so pivot/graph go through `applyAISearch` like list/kanban.
Task-ID: 6148879This update corrects a UI issue that occurred when sign templates included roles with assigned users. A technical problem with how binary data was being handled caused errors and a broken user interface. The fix converts binary data to a standard base64 format, ensuring proper rendering and preventing errors during template loading.
Original PR description
Version: - saas-19.3 Steps to reproduce: - Create sign template with one role. - Set 'assign to' value to that role. - Try to refresh the page or again open the template. Issue: - sign item and roles are not render on template properly and UI get broken. - ConnectionLostError occurs when loading sign template with 'assign to' value on role. Cause: - After recent changes, Binary fields (avatar_128/avatar_1920) now return BinaryValue objects instead of base64 strings. - These objects are not JSON serializable and cause UnicodeDecodeError during RPC response serialization. Solution: - Convert BinaryValue to base64 string using .to_base64() before returning in get_template_items_roles_info. task-6122941
5 changes
Resolved issues and error corrections
This update fixes a confusing error message that appeared when employees changed their contracts and working schedules, particularly when leaves were involved. The fix now includes the original error traceback, making it easier for administrators to understand and resolve the issue related to leave allocations.
Original PR description
A validation error is raised if changing employee's contract with a new working schedule on a period with leaves and the new working schedule changes the duration of these leaves in such a way that the employee no longer has the required allocation for them. This adds to the error message the original error traceback for debuggig purposes. Task: 6105516 Forward-Port-Of: odoo/odoo#258280
This update fixes an issue where increasing the quantity of a service product in a sales order incorrectly generated a purchase order with an inflated quantity. The fix ensures the quantity is always calculated and expressed in the sales order's unit of measure, resolving a discrepancy in the purchase order generation process. This prevents over-ordering and ensures accurate purchase order quantities.
Original PR description
Steps to reproduce the bug: - Create a service product "P1": - In the Purchase tab: - Vendor: Azure Interior - Subcontract Service: True - UoM: dozen - Purchase UoM: unit - Create a sales order with…
Steps to reproduce the bug:
- Create a service product "P1":
- In the Purchase tab:
- Vendor: Azure Interior
- Subcontract Service: True
- UoM: dozen
- Purchase UoM: unit
- Create a sales order with 1 dozen of P1
- Confirm -> a purchase order with 12 units of P1 is generated
- Confirm the purchase order
- Go back to the sales order:
- Update the quantity from 1 to 2 dozen
Problem:
A new purchase order is generated, but with 144 units instead of 12
units. The quantity difference between the old SO quantity and the new
one is computed twice in the purchase order line UoM, in both
`_purchase_increase_ordered_qty` and `_purchase_service_prepare_line_values`:
https://github.com/odoo/odoo/blob/17.0/addons/sale_purchase/models/sale_order_line.py#L186
Solution:
The `quantity` parameter must be expressed in the SO line UoM, as
described in the documentation of the function `_purchase_service_prepare_line_values`.
https://github.com/odoo/odoo/blob/17.0/addons/sale_purchase/models/sale_order_line.py#L178
opw-6049106
Forward-Port-Of: odoo/odoo#260517
Forward-Port-Of: odoo/odoo#255478This update fixes an issue where MTSO procurements were incorrectly estimating available stock due to how free quantities were calculated. The change ensures that stock availability is accurately reflected across multiple levels of a product's bill of materials, preventing over-ordering of components. This improves procurement accuracy and reduces potential stock discrepancies.
Original PR description
When creating a procurement through mtso, if the product has a muti level bom with the same component at multiple levels, it will consider the available quantity multiple times. Steps to reproduce:…
When creating a procurement through mtso, if the product has a muti level bom with the same component at multiple levels, it will consider the available quantity multiple times. Steps to reproduce: ------------------- * Enable MTO and change supply method to: "Take From Stock, if unavailable, Trigger Another Rule" * Create three products : final, semi, component - final: mtso, manufacture - semi: mtso, manufacture - component: mtso, buy, on hand quantity to 4 * Create a bom for final: - 10 components - 1 semi * Create a bom for semi: - 10 components * Create and confirm a MO for 1 "final" -> Issue the purchase order is only for 12 components and not 16. Observation: ------------- When confirming our MO, it will create a manufacture procurement for the products. The procurement will recursively create procurements and stock moves for each of its components. https://github.com/odoo/odoo/blob/b0b8a102153eaa9231321524ec5140cc6d754502/addons/stock/models/stock_move.py#L1563-L1571 Since its a MTSO, it will first check the products if there is available products in stock (free_qty) and create the procurement for the missing quantity: https://github.com/odoo/odoo/blob/b0b8a102153eaa9231321524ec5140cc6d754502/addons/stock/models/stock_move.py#L1646-L1647 https://github.com/odoo/odoo/blob/b0b8a102153eaa9231321524ec5140cc6d754502/addons/stock/models/stock_move.py#L1657-L1663 And each procurement, if it is of the manufacture type, will create corresponding procurements for their components. Once all the procurements and stock moves have been created, the stock move will confirmed and assigned. https://github.com/odoo/odoo/blob/942cbbbf243ff28f84fdaa40ed73b6572e0032a6/addons/stock/models/stock_move.py#L1627-L1629 -> The issue arise because the free_qty will only be updated when the stock moves are assigned which happen after all the procurement quantity are calculated for all the levels. opw-5514788 Forward-Port-Of: odoo/odoo#253958
This update ensures that Brazilian fiscal documents generated for EDI comply with local tax regulations. The system now incorporates approximate tax values provided by Avalara, which are legally required to be included in all documents, even when no specific tax information is available. This improves accuracy and avoids potential compliance issues.
Original PR description
All fiscal documents are required by Brazil law to include the approximate value of fed, state, and city taxes that affect it. Avalara already provides back these values in their tax calculation response, we just missed sending it to the EDI. This commit takes the information from that response and adds it to the EDI payload to make sure that it is generated properly into the generated documents. We are required to always show this even if there are no informative taxes as such we combine it with the T&C sent already. task-5478059 Forward-Port-Of: odoo/enterprise#113732
This update resolves an issue where downloading attachments from Odoo's mobile apps was failing. The fix ensures that absolute URLs for attachments are correctly handled, preventing errors and restoring the ability to download files from the chatter interface. This improves the user experience for mobile users.
Original PR description
In Odoo 18.4+, downloading attachments from the chatter is broken.
See: https://github.com/odoo/odoo/pull/200099
The `onClickDownload` function now passes an absolute URL to `downloadFile`.
The download function is implemented natively in the mobile apps.
The Android implementation always prefixes the provided URL with the
database origin (i.e.: `https://example.odoo.com`).
`download({url: "https://example.odoo.com/web/content"})` will try to
download `https://example.odoo.comhttps://example.odoo.com/web/content`.
This results in an UnknownHostException.
We can remove the origin from the url before calling the native method.
By doing this on the JS side, there is no need to update the Android app.
opw-6033150
Forward-Port-Of: odoo/enterprise#11483215 changes
Resolved issues and error corrections
This update fixes an issue where stock quantities weren't always correctly reflected in purchase and sales orders. It now ensures quantities match the original order unit of measure and creates pickings for partial orders, improving order fulfillment accuracy. Additionally, it corrects a demo stock imbalance to prevent negative stock levels in demo data, ensuring consistent reporting.
Original PR description
Make sure that the quantity received is in the unit of measure of the purchase order line. Also, when installing stock, create pickings for partial and empty sale/purchase orders. Finally, since creating we're creating more pickings, we need to raise the demo stock of product_product_12 to not be in negative stock for other modules demo data. task 5431550 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes a confusing error message that appeared when employees changed their work schedules while existing holiday periods were in place. The fix now includes the original error traceback, making it easier for support teams to diagnose and resolve the issue quickly. This improves the overall user experience and reduces troubleshooting time.
Original PR description
A validation error is raised if changing employee's contract with a new working schedule on a period with leaves and the new working schedule changes the duration of these leaves in such a way that the employee no longer has the required allocation for them. This adds to the error message the original error traceback for debuggig purposes. Task: 6105516 Forward-Port-Of: odoo/odoo#258280
This update corrects a bug in the self-ordering point-of-sale system that caused incorrect pricing when customers ordered multiple units of combo products. The fix ensures that free item quantities are properly scaled with the parent order, preventing miscalculations and ensuring accurate pricing for larger purchases. This improves the reliability of combo pricing.
Original PR description
When buying more than one unit of a combo product, the free-item quota (qty_free) was not scaled by the parent quantity, causing child lines with qty > 1 to be partially mis-classified as extra. This meant the same line was processed by both the free and extra loops, with the extra loop overwriting the correct price. Additionally, the proportional price_unit for free child lines used the unscaled original_total (which already includes the parent qty factor) against a per-unit parent_lst_price, resulting in a price that was too low by exactly the parent qty factor. opw-6045562 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258753
This update resolves a performance issue that caused slowdowns and crashes when working with many2many fields containing a large number of records. The change replaces a slow search method with a faster one, ensuring smoother operation and preventing UI freezes when handling large datasets.
Original PR description
### Issue before this commit: When handling many2many fields with a large number of records (e.g., 20k+), the client-side performance degraded significantly. In extreme cases, the browser became…
### Issue before this commit: When handling many2many fields with a large number of records (e.g., 20k+), the client-side performance degraded significantly. In extreme cases, the browser became unresponsive or crashed when triggering onchange or compute logic. ### Steps to Reproduce: Create a computed many2many field. Add it to a form view (can be invisible). Populate the related model with a large dataset (20k+ records). Trigger an onchange that recomputes the field. ### Cause of the Issue: In _applyCommands (LINK case), the system checks for existing record IDs using Array.includes(), which has O(n) time complexity. When handling thousands of records, repeated ID lookups using includes() result in O(n²) complexity. ### With This Commit: Replaced Array.includes() with a Set (Set.has()), reducing lookup time to O(1). The set is updated incrementally as new IDs are added, improving overall complexity to O(n) and preventing UI freezes for large datasets. opw-6122024 Forward-Port-Of: odoo/odoo#260993
This update fixes an error in how holiday leave time off is calculated. Previously, public holidays were incorrectly included in the time off duration, leading to inaccurate 'Approved Time Off' values. The fix ensures that time off is calculated correctly, aligning with the 'Ignore Public Holidays' option.
Original PR description
# Setup You'll need a User with : - An active contract (for easiness of testing, a contract that started long ago with 8hrs/day) # How to reproduce - Create a new Time Off type with "Ignore Public…
# Setup
You'll need a User with :
- An active contract (for easiness of testing, a contract that started long ago with 8hrs/day)
# How to reproduce
- Create a new Time Off type with "Ignore Public Holidays" enabled
- Create a Public Holiday for Period X
- Create A Time Off request for the User for a Period Y that contains Period X
- Go to the Time Off Ledger
- Remove the Missing Hours filter and search for the dates in Period Y
Exemple of periods :
- Period X => Feb 10 2026 - Feb 10 2026
- Period Y => Feb 9 2026 - Feb 11 2026
# The problem
The "Approved Time Off" and "Difference" values are wrong.
With the given exemples, we'll see Feb 9 and Feb 11 with "Approved Time Off" values of 12hrs, which is wrong since the employee is supposed to work 8hrs a day, so he should have a time off of also 8hrs.
# Cause
The calculation for "Approved Time Off" is the following :
Divide the `number_of_hours` of a hr_leave
By the number of working days during the period of the leave
Using our exemple, we get :
`number_of_hours` = 24hrs
number of working days = 2
Approved Time Off = 24hrs / 2 => 12hrs, but we expect 8hrs
The `number_of_hours` is correct since we checked "Ignore Public Holidays" (which actually means : include the public holidays in the number of hours of a leave)
The problem is that the aggregation for the number of working days excludes automatically
public holidays, without paying attention to the value of "Ignore Public Holidays" :
https://github.com/odoo/odoo/blob/5e623af55fba64e812db6bcaf06d8f7c5d08f055/addons/hr_holidays_attendance/report/hr_leave_attendance_report.py#L193-L202
Explanation for this part of the query : we only keep days where there is no record in
resource_calendar_leaves (`WHERE rcl2.id IS NULL`) that contains that day
and that are considered public (`AND rcl2.resource_id IS NULL`)
# Proposed Solution
We add a `JOIN hr_leave_type` to be able to get the value for
`include_public_holidays_in_duration` ("Ignore Public Holidays").
Then, we make it so we exclude the Public Holidays only if that value is
false (`AND NOT lvt.include_public_holidays_in_duration`)
opw-6082422
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#258963This update resolves an issue where attachment downloads from the Odoo chatter were failing in Odoo 18.4+. The fix ensures that absolute URLs for attachments are correctly handled by the mobile apps, preventing errors and restoring reliable download functionality. This change was made on the JavaScript side to avoid requiring an update to the Android app.
Original PR description
In Odoo 18.4+, downloading attachments from the chatter is broken.
See: https://github.com/odoo/odoo/pull/200099
The `onClickDownload` function now passes an absolute URL to `downloadFile`.
The download function is implemented natively in the mobile apps.
The Android implementation always prefixes the provided URL with the
database origin (i.e.: `https://example.odoo.com`).
`download({url: "https://example.odoo.com/web/content"})` will try to
download `https://example.odoo.comhttps://example.odoo.com/web/content`.
This results in an UnknownHostException.
We can remove the origin from the url before calling the native method.
By doing this on the JS side, there is no need to update the Android app.
opw-6033150
Forward-Port-Of: odoo/enterprise#114832This update ensures that the AI chat window now opens in full-screen mode, regardless of how it's initiated – through the system tray or command palette. Previously, the chat would open in a background window, which has now been resolved for a smoother and more convenient user experience.
Original PR description
Prior to this commit, when opening the chat with an agent from the systray button, the chat window was opened in the background. This commit fixes the issue by adding a call to `channel.open` which opens the chat when in full-screen mode. This commit also fixes an issue where the chat window wasn't properly opened when done from the command palette. task-5172978 Forward-Port-Of: odoo/enterprise#114598
This update fixes an issue where MTSO procurements incorrectly calculated available stock quantities, leading to inaccurate purchase order quantities. The change ensures that stock availability is accurately considered across multiple BOM levels during procurement creation, preventing overestimation of required components.
Original PR description
When creating a procurement through mtso, if the product has a muti level bom with the same component at multiple levels, it will consider the available quantity multiple times. Steps to reproduce:…
When creating a procurement through mtso, if the product has a muti level bom with the same component at multiple levels, it will consider the available quantity multiple times. Steps to reproduce: ------------------- * Enable MTO and change supply method to: "Take From Stock, if unavailable, Trigger Another Rule" * Create three products : final, semi, component - final: mtso, manufacture - semi: mtso, manufacture - component: mtso, buy, on hand quantity to 4 * Create a bom for final: - 10 components - 1 semi * Create a bom for semi: - 10 components * Create and confirm a MO for 1 "final" -> Issue the purchase order is only for 12 components and not 16. Observation: ------------- When confirming our MO, it will create a manufacture procurement for the products. The procurement will recursively create procurements and stock moves for each of its components. https://github.com/odoo/odoo/blob/b0b8a102153eaa9231321524ec5140cc6d754502/addons/stock/models/stock_move.py#L1563-L1571 Since its a MTSO, it will first check the products if there is available products in stock (free_qty) and create the procurement for the missing quantity: https://github.com/odoo/odoo/blob/b0b8a102153eaa9231321524ec5140cc6d754502/addons/stock/models/stock_move.py#L1646-L1647 https://github.com/odoo/odoo/blob/b0b8a102153eaa9231321524ec5140cc6d754502/addons/stock/models/stock_move.py#L1657-L1663 And each procurement, if it is of the manufacture type, will create corresponding procurements for their components. Once all the procurements and stock moves have been created, the stock move will confirmed and assigned. https://github.com/odoo/odoo/blob/942cbbbf243ff28f84fdaa40ed73b6572e0032a6/addons/stock/models/stock_move.py#L1627-L1629 -> The issue arise because the free_qty will only be updated when the stock moves are assigned which happen after all the procurement quantity are calculated for all the levels. opw-5514788 Forward-Port-Of: odoo/odoo#253958
This update fixes an issue where IoT events were missed due to a failure in the longpolling fallback mechanism. Now, if longpolling requests fail, the system automatically switches to using the more reliable WebSocket connection, preventing disruptions like failed Worldline payments. This ensures consistent event delivery.
Original PR description
Community PR: https://github.com/odoo/odoo/pull/260931 Before this commit, if `onMessage` in `iot_http_service` was called directly, it would fail to fallback to websocket if the longpolling request failed, causing events to be missed. One symptom of this is Worldline payments failing to confirm when using websocket. After this commit, the `_longpolling` method will now throw an error in this case, causing the fallback mechanism to attempt websocket instead. Forward-Port-Of: odoo/enterprise#114779
This fix ensures that the default website correctly updates when the sequence order is changed, particularly in incognito browsing sessions. Previously, website defaults weren't refreshed after reordering, leading to incorrect website selection. The update restores a cache clearing mechanism to maintain accurate website defaults.
Original PR description
**Problem:** Changing the order of websites does not update which website is shown as the default when visiting from an incognito window (no domain match). **Steps to reproduce:** 1. Create two…
**Problem:** Changing the order of websites does not update which website is shown as the default when visiting from an incognito window (no domain match). **Steps to reproduce:** 1. Create two websites with no domain set 2. Change their sequence order via the handle widget in the backend 3. Open an incognito window 4. The default website shown is still the old one **Current behavior:** The default website does not change after reordering. **Expected behavior:** The website with the lowest sequence should be served as the default. **Cause of the issue:** Commit d6f4af2790a0 replaced `models.Model` with `models.CachedModel` and removed the blanket `self.env.registry.clear_cache()` from the top of `write()`. CachedModel only auto-clears caches for fields listed in `_cached_data_fields`, but `sequence` is not in that list. As a result, `_get_current_website_id` (decorated with `@tools.ormcache`) keeps returning the stale cached website ID after a sequence change. https://github.com/odoo/odoo/commit/d6f4af2790a0abacba6e616b00d999eddc30edc9#diff-5e92e473fa4d3da6db7ef727fb217dad51ef6c2383913edca73fe040a23e82c2L339-L341 **Fix:** Restoring `clear_cache()` scoped to the existing sequence/company_id check ensures the ormcache is invalidated only when relevant fields change, rather than on every write as before. opw-6102426
This update ensures that all Brazilian tax documents generated through EDI comply with local law. It incorporates approximate tax values provided by Avalara, which are now included in the EDI payload regardless of whether actual tax information is available. This ensures accurate and compliant reporting for Brazilian businesses.
Original PR description
All fiscal documents are required by Brazil law to include the approximate value of fed, state, and city taxes that affect it. Avalara already provides back these values in their tax calculation response, we just missed sending it to the EDI. This commit takes the information from that response and adds it to the EDI payload to make sure that it is generated properly into the generated documents. We are required to always show this even if there are no informative taxes as such we combine it with the T&C sent already. task-5478059 Forward-Port-Of: odoo/enterprise#113732
This update resolves an issue where creating a filter with invalid data in Odoo views would cause the application to crash. Now, the system gracefully handles these errors without a crash, although the filter itself isn't active. This improves stability and prevents disruptions to users creating and editing filters.
Original PR description
On some view, create and edit a filter, but put something unparseable by JS in the `context` field eg: `{123}`.
Go back to the view.
Before this commit there was a crash, because the python parser in JS crashed.
After this commit, there is no crash, the filter is visible but not activable.
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#260612This update resolves an issue where the minimum IS (Insurance Savings) amount was incorrectly calculated in the Swiss payroll module. The fix ensures accurate IS calculations, aligning with Swiss tax regulations and improving payroll accuracy. This impacts the correct processing of employee insurance contributions.
Original PR description
Forward-Port-Of: odoo/enterprise#114463
This update resolves an issue where deleting a project stage incorrectly navigated users to a different view and displayed archived tasks. The fix ensures the original view remains active, the stage is properly deleted, and the user's intended task list is displayed correctly. This improves the user experience when managing project stages.
Original PR description
# Steps to reproduce 1. Create a project 2. Create a stage 4. Remove the stage # Current behavior Instead of remaining in the project tasks view, it switches to the tasks view filtered with the current project. Additionally, it displays archived tasks because no filter is selected, thereby discarding original ones. This also applies to stage deletion in other views (e.g., My Tasks), where the search filters are completely discarded. # Expected behavior The dialog should be closed, the stage should be deleted, and the original view should remain active. This is done through a soft-reload of the page, ensuring the original view is kept, together with original breadcrumbs, and the stage is visually disappearing. task-5498274 Forward-Port-Of: odoo/odoo#260213 Forward-Port-Of: odoo/odoo#246935
This update corrects a bug where the DIAN web service was incorrectly overwriting customer contact information (names and emails) with fiscal data, leading to data loss and incorrect invoice delivery. The fix now intelligently handles email differences, creating a new contact if needed and giving users control over their data.
Original PR description
The DIAN web service was overwriting partner names and emails with fiscal data, causing data loss for CRM contacts. The fiscal email often differs from the commercial one, and the overwrite broke the sales flow by sending invoices to the wrong address. Users had no standard workaround short of manually re-entering emails after every invoice generation. Instead of blindly overwriting, only update empty fields and create a child invoicing contact when the DIAN email differs from the existing one. Also remove the automatic onchange and periodic re-fetch triggers to leave existing data under user control. task-5912005 Forward-Port-Of: odoo/enterprise#114017
5 changes
Resolved issues and error corrections
This update fixes an error in how tax returns are calculated for companies with multiple branches. Previously, rounding adjustments were incorrectly applied, leading to inaccurate closing entries. The fix ensures accurate tax return calculations by isolating company-specific rounding data.
Original PR description
Some countries lile Estonia, Nederlands or France apply a rounding from the tax report by adding a line to the end of the query results representing the sum of the roundings on each line of the tax…
Some countries lile Estonia, Nederlands or France apply a rounding from the tax report by adding a line to the end of the query results representing the sum of the roundings on each line of the tax report. When having a company with branches, the rounding is applying in each closing move (one per company/branch) but the value is coming from the aggregated report lines, this leads to wrong computation of the closing entries. Cause: In `_generate_tax_closing_entries` we loop over each company, therefore `_compute_tax_closing_entry` is called one time for each company, but it uses the report options containing all companies Fix: Use options with only the current company in `_compute_tax_closing_entry` Steps: - Install FR localisation - Select FR company and create two branches - Create, for last month: - 1 bill for parent company (100 with tax 20% G) - 1 invoice per branch (200 and 300 with tax 20% G) - Create a tax return with opining date at the beginning of the current month - Submit the last return and go to the created closing entries -> See that closing entries are wrong opw-5976359 Forward-Port-Of: odoo/enterprise#110652
This update fixes a security issue where unauthorized users could access asset information within invoices. Now, access to assets is restricted to specific user groups within the accounting module, preventing potential data breaches and ensuring data integrity. This change enhances the security of our invoicing process.
Original PR description
Only groups `account.group_account_readonly`, `account.group_account_invoice` or higher have access to model `account.asset`, therefore if an user goes to see an invoice with assets and they are not on either group, they will receive an error and won't be able to access said invoice. How to reproduce: - Create a vendor bill - Create an account.asset and link it to said account.move - Go to the form view with an user that it's on group "Purchase: User" for example --> They get a traceback --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/enterprise#113858 Forward-Port-Of: odoo/enterprise#112890
This update resolves an issue where the DIAN web service was incorrectly overwriting customer contact information (names and emails) with fiscal data, leading to data loss and incorrect invoice delivery. The fix now intelligently handles email differences, creating a new contact if needed and giving users control over their existing data.
Original PR description
The DIAN web service was overwriting partner names and emails with fiscal data, causing data loss for CRM contacts. The fiscal email often differs from the commercial one, and the overwrite broke the sales flow by sending invoices to the wrong address. Users had no standard workaround short of manually re-entering emails after every invoice generation. Instead of blindly overwriting, only update empty fields and create a child invoicing contact when the DIAN email differs from the existing one. Also remove the automatic onchange and periodic re-fetch triggers to leave existing data under user control. task-5912005 Forward-Port-Of: odoo/enterprise#114017
This update resolves an issue where the minimum IS (Insurance Savings) amount was incorrectly calculated in the Swiss payroll module. The change ensures accurate IS calculations for Swiss employees, aligning with local tax regulations. This update improves the reliability of payroll reporting for our Swiss clients.
Original PR description
Forward-Port-Of: odoo/enterprise#114463
This update fixes a problem where opening a restaurant order with an active Fiskaly transaction on a second device would cause duplicate transaction attempts and errors. The fix ensures that transaction state information is properly saved and shared between devices, preventing these errors and improving the reliability of the POS system.
Original PR description
In a restaurant POS, when an order with an active Fiskaly transaction is opened on a second device, `transactionState` and `tx_revision` were not available (uiState is not persisted to the server), causing the new device to attempt creating a duplicate transaction with a stale revision, which resulted in a Fiskaly API error. opw-6147654 Forward-Port-Of: odoo/enterprise#114911 Forward-Port-Of: odoo/enterprise#114599
4 changes
Resolved issues and error corrections
This update corrects a bug where the DIAN web service was incorrectly overwriting customer contact information (names and emails) with fiscal data, leading to lost sales data. The fix now intelligently handles email differences, creating a separate invoicing contact if needed and giving users control over their existing data.
Original PR description
The DIAN web service was overwriting partner names and emails with fiscal data, causing data loss for CRM contacts. The fiscal email often differs from the commercial one, and the overwrite broke the sales flow by sending invoices to the wrong address. Users had no standard workaround short of manually re-entering emails after every invoice generation. Instead of blindly overwriting, only update empty fields and create a child invoicing contact when the DIAN email differs from the existing one. Also remove the automatic onchange and periodic re-fetch triggers to leave existing data under user control. task-5912005 Forward-Port-Of: odoo/enterprise#114017
This update resolves a problem where sales orders using products with different projects for each company would fail to process correctly through the customer portal. The fix ensures the correct company context is used when accessing company-dependent fields, preventing errors and ensuring proper order processing across multiple companies. This improves the reliability of the sales process for businesses using multiple company accounts.
Original PR description
project_template_id is a company dependent field. When creating a project, it is called without the proper company context set up. When confirming an SO through the portal, the order's env is setup…
project_template_id is a company dependent field. When creating a project, it is called without the proper company context set up. When confirming an SO through the portal, the order's env is setup without a company and `.with_user(SUPERUSER_ID)`, making future company_dependent variables use OdooBot's company. Following examples earlier in the function, call `.with_company` while accessing project_template_id. Steps to reproduce: 1. Install Sales and Project 2. Create second company 3. Create Customer with portal access, under created company 4. Create service product with different projects for each company 5. Create sales order with customer and service product, send to customer 6. Login as customer on portal, accept and sign SO a. Should stall, RPC Error in console Ticket: opw-6082772 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#260387
This update corrects a previous issue where loyalty point history records only showed the net difference between earned and spent points in a single order. The fix now accurately tracks and records both the gross amount of points earned and the gross amount of points spent, providing a more complete and reliable record of customer loyalty transactions. This ensures accurate reporting and better customer understanding.
Original PR description
When a loyalty card both earned and spent points in the same POS order, the history entry only reflected the net difference instead of the gross amounts. The root cause was that the JS payload sent only a single `points` field representing the net change. Fix by tracking `points_earned` and `points_spent` separately in `couponData` and sending them to the server. opw-6041420 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#258176 Forward-Port-Of: odoo/odoo#256022
This update fixes a problem in our restaurant POS system where opening an order with a connected Fiskaly transaction on a second device would cause duplicate transaction attempts and errors. The fix ensures that transaction state information is properly saved and shared between devices, preventing these errors and improving the reliability of Fiskaly integration.
Original PR description
In a restaurant POS, when an order with an active Fiskaly transaction is opened on a second device, `transactionState` and `tx_revision` were not available (uiState is not persisted to the server), causing the new device to attempt creating a duplicate transaction with a stale revision, which resulted in a Fiskaly API error. opw-6147654 Forward-Port-Of: odoo/enterprise#114911 Forward-Port-Of: odoo/enterprise#114599
1 change
Resolved issues and error corrections
This update corrects a previous error in Odoo's French reporting module. Accounts 657 and 757, introduced by a recent French accounting reform (PCG 2025), are now correctly classified as current operations, ensuring accurate profit and loss statements. This resolves a mismatch previously impacting financial reporting.
Original PR description
…tions As part of the PCG 2025 reform in France, accounts 657 and 757 were introduced to handle capital gains and losses on the disposal of tangible and intangible assets related to normal, current activities. Previously, Odoo incorrectly categorized these under exceptional items which led to mismatches in the P&L. Source: https://www.anc.gouv.fr/files/anc/files/1_Normes_fran%C3%A7aises/Plans%20comptables/PCG--1er-janvier-2025.pdf Relevant excerpts: <img width="630" height="372" alt="image" src="https://github.com/user-attachments/assets/88a66dac-1cc0-4a33-a902-edb6b626f18f" /> <img width="631" height="318" alt="image" src="https://github.com/user-attachments/assets/403b65dc-20ba-447e-937d-20575f1f45ab" /> opw-6105764 Forward-Port-Of: odoo/enterprise#114897 Forward-Port-Of: odoo/enterprise#114837
7 changes
Resolved issues and error corrections
This update enhances data privacy within the Helpdesk module by restricting access to reporting menus (Ticket Analysis & SLA Status Analysis) to manager users only. Previously, non-admin users could access these reports; this change removes complex security overrides and directly restricts access, improving data security and user experience.
Original PR description
Before this commit: Currently, the `Ticket Analysis` and `SLA Status Analysis` reporting menus from the helpdesk module are accessible to non-admin users. To manage data privacy and ensure users only see their own ticket data, custom Python overrides `(specifically _load_menus_blacklist in ir.ui.menu.py)` and complex record rules `(ir.rule in helpdesk_security.xml)` were maintained to filter report data. After this commit: helpdesk: Hide the reporting menus directly by restricting the `Ticket Analysis` and `SLA Status Analysis` menu items to the manager group. Removed the custom ` _load_menus_blacklist `Python override from ir.ui.menu.py since conditionally hiding the menus in Python is no longer necessary. Removed the obsolete `ir.rule` data filters for standard users in `helpdesk_security.xml`. Revoked base read access in the `ir.model.access.csv`file for standard users to prevent direct access to the reports via URL. task-5119293
This update resolves an issue where crucial fiscal data was missing from Swedish POS receipts printed from both the online and offline systems. The fix corrects the receipt template and data generation process, ensuring accurate reporting for Swedish accounting requirements. This ensures compliance and accurate record-keeping.
Original PR description
Since the receipt printing refactor that allowed printing receipts from either the frontend or backend, the fiscal data for Swedish blackbox receipts has been broken. In the frontend, the receipt prints but the blackbox data is missing from the footer. In the backend, attempting to print the receipt gives a 500 error. This commit fixes both these issues by correcting the receipt template and data generation. Community - https://github.com/odoo/odoo/pull/260587 Forward-Port-Of: odoo/enterprise#114579
This update resolves an issue where planned hours were incorrectly displayed on public holiday days in the project timesheet reports. The fix ensures the report accurately excludes public holidays, regardless of whether they're linked to a specific schedule, and accounts for timezone differences to prevent date shifting.
Original PR description
### Steps to reproduce: - Install project_timesheet_forecast module - Configure your database to have a far timezone (Montevideo/Uruguay in my case) - Create a public holiday starts from 12AM to…
### Steps to reproduce: - Install project_timesheet_forecast module - Configure your database to have a far timezone (Montevideo/Uruguay in my case) - Create a public holiday starts from 12AM to 11:59PM with a calendar - Create a planning slot for a resource that overlap with the public holiday - Check the Timesheets / Planning analysis report - Group by employees > day **- Check the date of the public holiday and notice there are still planned hours shown** - Remove the calendar from the public holidays that we created previously - Check the report once again **- Notice the day of the public holiday and the day after has no planned hours** ### Cause: In the query we are using to exclude the leave days from the report we only exclude the ones that has calendar_id assigned, not taking into consideration that some of the public holiday are general and is not applied to just one working schedule. Also if we have a leave starting midnight to 11:59PM since we store dates in database as UTC for timezone like Uruguay's one it will shift the end with one day which will introduce inconsistencies ### Fix: We check if the calendar_id is null on the resource_calendar_leaves and make sure we take timezone of the resource into account when checking the dates of the leaves. opw-5027070 Forward-Port-Of: odoo/enterprise#114757 Forward-Port-Of: odoo/enterprise#111846
This update resolves an issue where attachments couldn't be downloaded from the Odoo chatter on mobile devices (Odoo 18.4+). The fix ensures that URLs are correctly formatted for download, preventing errors and restoring the ability to access attachments. This improvement impacts mobile users' ability to retrieve files.
Original PR description
In Odoo 18.4+, downloading attachments from the chatter is broken.
See: https://github.com/odoo/odoo/pull/200099
The `onClickDownload` function now passes an absolute URL to `downloadFile`.
The download function is implemented natively in the mobile apps.
The Android implementation always prefixes the provided URL with the
database origin (i.e.: `https://example.odoo.com`).
`download({url: "https://example.odoo.com/web/content"})` will try to
download `https://example.odoo.comhttps://example.odoo.com/web/content`.
This results in an UnknownHostException.
We can remove the origin from the url before calling the native method.
By doing this on the JS side, there is no need to update the Android app.
opw-6033150
Forward-Port-Of: odoo/enterprise#114832This update ensures that VAT numbers in the VIES summary reports are formatted correctly, removing the country code. This is necessary to comply with Czech tax regulations and generate reports that meet official VIES XML requirements, preventing potential reporting errors.
Original PR description
**Steps to reproduce:** - Install the `l10n_cz_reports` module and switch to a `CZ Company` - Create an invoice for a customer with a VAT number, add a product, and set the Transaction Code (enable…
**Steps to reproduce:** - Install the `l10n_cz_reports` module and switch to a `CZ Company` - Create an invoice for a customer with a VAT number, add a product, and set the Transaction Code (enable it from the optional columns if needed). - Navigate to Reporting > VIES Summary Report. - Observe the value in the `VAT Number` column (includes country code). - From the dropdown, export the report as XML. **Observation:** In the generated XML file, the `c_vat` field contains the VAT number including the country code (e.g., `CZ12345679`) instead of only the numeric part (`12345679`). **Root cause:** At [1], the VAT number is directly taken from the report lines without removing the country code. **Fix:** This commit ensures that the `c_vat` field contains only the VAT number without the country code, complying with the official VIES XML format requirements. Ref: https://adisspr.mfcr.cz/dpr/adis/idpr_pub/epo2_info/popis_struktury_detail.faces?zkratka=DPHSHV#:~:text=Tax%20identification%20number%20of%20the%20purchaser%20(only%20the%20numeric%20part) [1]: https://github.com/odoo/enterprise/blob/c4f2c3442f30f5ac972dd136a3642acc5bcc6da2/l10n_cz_reports_2025/models/l10n_cz_vies_summary_handler.py#L29-L62 opw-6093259 Forward-Port-Of: odoo/enterprise#114990 Forward-Port-Of: odoo/enterprise#113083
A recent update caused crashes in the Self-Ordering and Mobile Menu (QR ordering) interfaces. This fix corrects a naming issue within the POS data loading process, ensuring these key features now function correctly. The change updates a field name to align with the current system, resolving the loading errors.
Original PR description
## Overview Accessing the Mobile Menu (QR ordering) or Self-Ordering interface crashes after installing `pos_blackbox_be` on SaaS-19.1. The interface fails to load due to a missing field in the POS…
## Overview Accessing the Mobile Menu (QR ordering) or Self-Ordering interface crashes after installing `pos_blackbox_be` on SaaS-19.1. The interface fails to load due to a missing field in the POS data loading flow. ## Steps to Reproduce 1. Install `pos_blackbox_be` 2. Open POS 3. Access the Mobile Menu (QR code) or Self-Ordering page ## Current Behavior - A traceback is raised - The interface does not load ## Root Cause The method `_load_pos_self_data_fields` returns the field: iface_fiscal_data_module However, from SaaS-19.1 this field was renamed to: iot_fdm_be_id This mismatch causes the POS self-ordering data loading to fail. ## Fix Updated the returned field to match the new field name. # Before return fields + ['iface_fiscal_data_module'] # After return fields + ['iot_fdm_be_id'] ## Impact - Restores proper loading of Mobile Menu (QR ordering) - Fixes Self-Ordering interface crash opw-6044883 ## Reproduction Video https://drive.google.com/file/d/1R5TYVIXvtts12YLF5iB4GKZirMZePoGr/view?usp=sharing Forward-Port-Of: odoo/enterprise#114357
This update ensures that Brazilian tax documents (EDI) accurately reflect tax amounts provided by Avalara, as required by Brazilian law. Previously, this information was missing, and now it's automatically included in all generated documents, regardless of tax information, to maintain compliance.
Original PR description
All fiscal documents are required by Brazil law to include the approximate value of fed, state, and city taxes that affect it. Avalara already provides back these values in their tax calculation response, we just missed sending it to the EDI. This commit takes the information from that response and adds it to the EDI payload to make sure that it is generated properly into the generated documents. We are required to always show this even if there are no informative taxes as such we combine it with the T&C sent already. task-5478059 Forward-Port-Of: odoo/enterprise#113732
6 changes
Resolved issues and error corrections
This update resolves a crash that occurred when opening salary adjustments on mobile devices. The fix addresses a missing delete action in the mobile view and added a basic kanban view to ensure proper functionality. This improves the user experience for mobile users managing employee salaries.
Original PR description
Steps to reproduce ================== - Install hr_payroll - Use a mobile viewport - Go to Employees - Open a record - Switch to the Salary Adjustments notebook tab => TypeError: undefined is not an…
Steps to reproduce ================== - Install hr_payroll - Use a mobile viewport - Go to Employees - Open a record - Switch to the Salary Adjustments notebook tab => TypeError: undefined is not an object (evaluating 'props.activeActions.onDelete=this.onDelete.bind(this)' Cause of the issue ================== The SalaryAttachment2ManyField widget overrides the rendererProps to handle the delete action, but this isn't defined on mobile (because a kanban view is used) See https://github.com/odoo/odoo/blob/9f93f22ed5f6d5dbbafeb0a8c6fababdc2a65d45/addons/web/static/src/views/fields/x2many/x2many_field.js#L196-L212 Solution ======== Since there is no delete action on the kanban view, there is no need for an override. While we are at it, there was no kanban view defined. Thus a default view was used https://github.com/odoo/odoo/blob/138fad6d54a0b59885b1e5c712beb8f581c9555c/odoo/addons/base/models/ir_ui_view.py#L2835-L2846 It only contained the field description. Since that one is optional, records without a description were almost invisible.. Thus we also add a basic kanban view opw-6047295
This update resolves a technical issue that was limiting the efficiency of WhatsApp marketing automation. Previously, the system processed only a portion of related messages, now all relevant messages are processed, improving the speed and scalability of the automation workflow. This ensures a smoother and more reliable experience for users.
This update resolves an issue where attachments couldn't be downloaded from the Odoo mobile app (versions 18.4+). The fix ensures that absolute URLs are handled correctly, preventing errors and restoring the ability to download files from chatter. This improvement impacts mobile users' ability to access and share attachments.
Original PR description
In Odoo 18.4+, downloading attachments from the chatter is broken.
See: https://github.com/odoo/odoo/pull/200099
The `onClickDownload` function now passes an absolute URL to `downloadFile`.
The download function is implemented natively in the mobile apps.
The Android implementation always prefixes the provided URL with the
database origin (i.e.: `https://example.odoo.com`).
`download({url: "https://example.odoo.com/web/content"})` will try to
download `https://example.odoo.comhttps://example.odoo.com/web/content`.
This results in an UnknownHostException.
We can remove the origin from the url before calling the native method.
By doing this on the JS side, there is no need to update the Android app.
opw-6033150
Forward-Port-Of: odoo/enterprise#114832This update corrects a bug where the DIAN web service was incorrectly overwriting customer contact information (names and emails) with fiscal data, leading to data loss and incorrect invoice delivery. The fix now preserves commercial contact details, creating a separate invoicing contact only when the DIAN email address differs, giving users control over their data and preventing future issues.
Original PR description
The DIAN web service was overwriting partner names and emails with fiscal data, causing data loss for CRM contacts. The fiscal email often differs from the commercial one, and the overwrite broke the sales flow by sending invoices to the wrong address. Users had no standard workaround short of manually re-entering emails after every invoice generation. Instead of blindly overwriting, only update empty fields and create a child invoicing contact when the DIAN email differs from the existing one. Also remove the automatic onchange and periodic re-fetch triggers to leave existing data under user control. task-5912005 Forward-Port-Of: odoo/enterprise#114017
This update corrects a flaw in how overtime entries are identified, which previously led to duplicate entries being created. The change ensures overtimes are accurately calculated based on the correct time range, regardless of timezone settings. This improves the reliability of overtime tracking and reporting.
Original PR description
This function searches for overtimes by the date of hr.attendance.overtime.line. This is simply a date and can lead to problems if not using the UTC timezone. Steps to reproduce: 1. Set timezone to…
This function searches for overtimes by the date of hr.attendance.overtime.line. This is simply a date and can lead to problems if not using the UTC timezone.
Steps to reproduce:
1. Set timezone to anything ahead of UTC (Europe/Chisinau) (Not required, but helps)
2. Create a new employee
3. Set the Contract
4. Set Work Entry Source to Attendances
5. Set the timezone of Working Hours to anything ahead of UTC (Europe/Chisinau)
6. Create an attendance for the employee that causes overtime (default anything over 8 hours)
7. Two work entries will be created. One for the default time and one for the overtime.
8. Create an attendance for the next day (no need for overtime)
9. Alter the Check Out time
10. Duplicate overtime work entry created for the day prior
Example:
Searching for Overtimes on April 17th.
date_start = datetime(2026, 4, 17, 0, 0)
date_stop = datetime(2026, 4, 17, 23, 59, 59, 999999)
Translated from Europe/Chisinau time (3 hours ahead):
date_start = datetime(2026, 4, 16, 21, 0)
date_stop = datetime(2026, 4, 17, 20, 59, 59, 999999)
start/stop times are cut to dates as overtime.line.date is just a Date:
start_naive.date() = date(2026, 4, 16)
end_naive.date() = date(2026, 4, 17).
Then, given the domain:
('date', '<=', end_naive.date()),
('date', '>=', start_naive.date()),
Result: all overtimes on April 16th and 17th returned.
This commit aims to change the function to truly return overtimes between the given datetimes (start_dt, end_dt)
opw-5952995This update resolves an issue where the minimum IS (Insurance Savings) amount was incorrectly calculated in the Swiss payroll module. The fix ensures accurate IS calculations for employees, aligning with Swiss tax regulations. This improves payroll accuracy and compliance for businesses using the Odoo Enterprise solution.
Original PR description
Forward-Port-Of: odoo/enterprise#114463
2 changes
Resolved issues and error corrections
This update ensures that the barcode app validates the destination of products before confirming a receipt, even when a destination is forced. This prevents issues where users couldn't validate receipts if they hadn't scanned a destination, improving the reliability of the barcode picking process.
Original PR description
### Steps to reproduce: - In the settings: Enable "Storage Locations" - Inventory > Configuration > Warehouse Management > Operation Types - On receipts, in the Barcode App tab enable: "Force a…
### Steps to reproduce: - In the settings: Enable "Storage Locations" - Inventory > Configuration > Warehouse Management > Operation Types - On receipts, in the Barcode App tab enable: "Force a destination on all products" - Open the barcode app, create a new receipt - Scan a product > Validate #### > You are not blocked by the fact that you did not scan any destination even just to validate the default one ### Cause of the issue: The `barcode_validation_after_dest_location` operation type setting is not used at any point in the barcode app. ### Note: Line in the barcode app are always created a with a `location_dest_id`: https://github.com/odoo/enterprise/blob/a220fc61d9076decdb987421df9330a1c2c20546/stock_barcode/static/src/models/barcode_picking_model.js#L1310-L1322 In particular, even if the setting says: Force a destination on all products. It should rather be interpreted as force a destination scan before validation. Note that a destination scan will not necessarily update a single line but rather all concerned lines at once: https://github.com/odoo/enterprise/blob/a220fc61d9076decdb987421df9330a1c2c20546/stock_barcode/static/src/models/barcode_picking_model.js#L1558-L1576 It is therefore a valid call to check if a location dest was scanned to determine if the a destination was set on each product before validation of the picking, even if it is just to confirm the default destination. ### Note 2: We modify the `_get_barcode_config` to only provide a `barcode_validation_after_dest_location` if locations re enabled otherwise users enabling the option without the ability to scan locations would be soft lock and unable to validate their picking. That same logic already being applied to the `restrict_scan_dest_location` config parameter: https://github.com/odoo/enterprise/blob/6afe02e3e836df2822d7cae8aebbd5bdde6b34cc/stock_barcode/models/stock_picking_type.py#L109 opw-6110690
This update significantly improves the speed of importing large XML bills, particularly those received via Peppol or manual upload. By optimizing the database queries and update processes, the upload time has been reduced from failing to a manageable 11 minutes for a large bill. This enhances efficiency for accounting operations.
Original PR description
### Description: The upload and import process for large XML bills via Peppol or manual upload was inefficient due to two primary bottlenecks. First, the system performed individual queries per line to match products, taxes, and accounts, leading to an N+1 query issue. Second, multiple write operations were executed on each line to update various fields. This commit introduces batching and improve caching for these operations to reduce database call. ### Benchmark: | N° of lines | Before | After | |-------------|---------|-------| | 30264 | Timeout | 11min | ### Reference: opw-5416612
6 changes
Resolved issues and error corrections
This update fixes a discrepancy in the sale details report by accurately reflecting cash rounding adjustments. Now, the report displays the total cash rounding applied during a session, aligning with how payments are recorded and providing a clearer picture of the transaction total. This ensures greater accuracy and transparency in sales reporting.
Original PR description
The sale details report total_paid was computed from sum(order.amount_total), which does not include the cash rounding adjustment. This caused a discrepancy between the displayed total and the sum of individual payment lines when cash rounding is enabled. Use the sum of actual payment amounts instead, which naturally includes cash rounding since payments are recorded with their rounded values. opw-5253018
This update resolves an issue where the quick create feature for product variants within Bills of Materials was incorrectly creating unrelated product templates. To ensure correct variant creation, the system now requires users to create the variant directly on the product template, providing a more reliable process.
Original PR description
Steps to produce: --- - Install `mrp`. - Go to Manufacturing > Products > Bills of Materials. - Click Create, select a product. - In the Product Variant field, type any value and click "Create".…
Steps to produce: --- - Install `mrp`. - Go to Manufacturing > Products > Bills of Materials. - Click Create, select a product. - In the Product Variant field, type any value and click "Create". Issue: --- Using quick create on the Product Variant field does not create a variant of the selected product template. Instead, it creates a completely new, unrelated `product.template`. This is because the `create()` method on `product.product` is overridden to call super() with context `create_product_product=False`, which suppresses direct variant creation and forces creation through `product.template` instead, see [1]. **Why passing `default_product_tmpl_id` does not help:** One might expect that passing `default_product_tmpl_id` in the field context would cause the newly quick-created `product.product` to be linked to the already-selected `product.template`. However, because of the `create()` override above (introduced in [commit]), the variant creation is always redirected to `product.template`, ignoring any `default_product_tmpl_id` passed in context. It is therefore not possible in any case to quick-create a `product.product` that is correctly and directly linked to the currently selected `product.template`. Fix: --- Disable the "Create" and "Create and Edit" options. Since there is no way to quick-create a `product.product` that is correctly linked to the currently selected `product.template`, the user must create the variant directly on the product template first. [1]https://github.com/odoo/odoo/blob/f04d79d44873d0f1c35303a1a892f3a3a394ea17/addons/product/models/product_product.py#L364-L368 [commit]: https://github.com/odoo/odoo/commit/7389345696720255a9d3c72ca1d9c2f4e4ecd7b8 opw-6127738 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update adds a new unit test to identify and correct a rounding error in the calculation of Arabic withholding taxes. The test specifically checks a scenario where a base amount of 391683 with a 4.5% tax rate should result in a withholding amount of 17625.74. Fixing this issue will ensure accurate tax calculations.
Original PR description
Add test test_07_invoice_and_payment_with_3_decimals_withholding_amount, the base amount is 391683, the percentage applied is 4.5%, the withholding amount must be 17625.74 . Check that this test fails on 18 on this pr https://github.com/odoo/odoo/pull/232893 and will be successful if the bug reported on https://www.odoo.com/es_ES/my/tasks/5154585 (#230641) is fixed. Task Adhoc side: 59222 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves an issue where the minimum IS (Insurance Savings) amount was incorrectly calculated in the Swiss payroll module. The change ensures accurate reporting of IS contributions for Swiss employees, aligning with local tax regulations. This update improves the reliability of payroll data for our Swiss clients.
Original PR description
opw 6133391
This update ensures that when reserving stock for packaged products, the system correctly considers the available quantity of full packages. Previously, a large stock level would override the 'reserve only full packages' setting. This change now accurately reflects the available stock, preventing over-reservation and ensuring accurate order fulfillment.
Original PR description
Issue ----- Forced full packaging reservation setting is ignored when there is a big quant in stock. Steps to reproduce ----- - Enable packagings - Create a product category "Super Category" -…
Issue
-----
Forced full packaging reservation setting is ignored when there is a big quant in stock.
Steps to reproduce
-----
- Enable packagings
- Create a product category "Super Category"
- Reserve Packagings: Reserve Only Full Packagings
- Create a stored product "AAA"
- Product Category: Super Category
- 50 units on hand
- Packaging: 6-Pack (6 units)
- Create a delivery for 15 units of AAA
> Reservation is made for 15 units
Cause
-----
The rounding to a multiple of the packaging quantity takes the stock quant into account. For our example case, we have 8 full 6-Packs on hand, so the `available_quantity` gets set to 48 when doing
https://github.com/odoo/odoo/blob/5e458236ca2ff2ab92c4893495e7a721be902c40/addons/stock/models/stock_quant.py#L923-L925
This leads to the reservation quantity being min(15, 48) = 15
https://github.com/odoo/odoo/blob/5e458236ca2ff2ab92c4893495e7a721be902c40/addons/stock/models/stock_quant.py#L927
-----
Ticket:
opw-5974333This update fixes a previous issue where the General Ledger report displayed journal items out of order, primarily grouped by company instead of date. Now, transactions are correctly sorted by date across all companies, providing a much clearer and more accurate chronological view of financial activity. This improves reporting accuracy and simplifies financial analysis.
Original PR description
### Issue before this commit: Before this commit, the General Ledger report did not correctly order journal items when a company and his branch were involved. Even when entries had different dates,…
### Issue before this commit: Before this commit, the General Ledger report did not correctly order journal items when a company and his branch were involved. Even when entries had different dates, the lines were grouped and displayed primarily by company, resulting in a non-chronological view. ### Steps to reproduce the issue: 1. Download Accounting 2. Create a company branch for your actual company 3. Create 4 invoices (2 for the company with different dates and 2 for the branch with same dates as the company's invoices) 4. Open General Ledger and see that under the account's group the order is per company and not per date ### Cause of the issue: The issue was caused by the SQL query used to retrieve account move lines in the General Ledger (PR that introduce the bug: https://github.com/odoo/enterprise/pull/107638) Specifically, the ORDER BY clause prioritized company-related fields before the transaction date. As a result, the sorting logic first grouped entries by company and only then applied date ordering within each company group, instead of performing a global chronological sort. ### Reason to introduce the fix: The fix ensures that journal items are primarily ordered by date across all companies, providing a correct chronological view of transactions. ### Fix details: It's not possible to reorder the attributes in the ORDER BY clause without braking the test test_general_ledger_export_csv_multi_comp so it has been decided to create this trick to solve only the bug in the visualization of the General Ledger report leaving the bug in the export of csv. opw-6000740