Daily updates from Odoo
Thursday, May 28, 2026
93 changes
22 changes
Enhancements to existing features
This update introduces a new EC Sales list report specifically for Hungary, providing more detailed sales data. Instead of grouping solely by partner, it now analyzes transactions based on transaction type (B, C, etc.) and transaction state (new or corrected), offering a more granular view of sales activity. This improves reporting accuracy for Hungarian businesses.
Original PR description
This commit implement the EC Sales list for Hungary This report is a bit different from the main EC Sales list, instead of just grouping the lines on partner_id, we need to group on specifics fields on account.move: - l10n_hu_transaction_type: B, C, K, R or V This field represente the type of Intra Community Transaction, it's a selection field with all the legal possible values. We leave the field blank for normal transactions. - l10n_hu_transaction_state: U or T Represent if the transaction is a new one (U) or a correction (T) The grouping of the report works like this: groupby partner_id, l10n_hu_transaction_type, l10n_hu_transaction_state This mean for a single partner, we can have up to 12 different lines. [task-4950959](https://www.odoo.com/odoo/project/967/tasks/4950959) Linked:https://github.com/odoo/enterprise/pull/110448 Forward-Port-Of: odoo/odoo#253556
This update introduces a new report for Hungary, specifically designed to generate the EC Sales list. Unlike the standard report, this version groups data by specific tax codes (B, C, K, R & V) instead of partner ID, ensuring accurate Hungarian tax reporting. It also includes the necessary tax return data for this report.
Original PR description
This report is a bit different from the main EC Sales list, instead of just grouping the lines on partner_id, we need to group on specifics tax.tags [B, C, K, R & V]. It also adds the tax returns for this same report. [task-4950959](https://www.odoo.com/odoo/project/967/tasks/4950959) Linked:https://github.com/odoo/odoo/pull/253556 Forward-Port-Of: odoo/enterprise#110448
Resolved issues and error corrections
This fix resolves an issue where confirming a sales order would only create one lead, even when multiple event registrations were involved. The update now correctly creates multiple leads based on each event registration, ensuring accurate lead tracking for multi-event purchases. This improves the reliability of lead generation within the CRM.
Original PR description
# How to reproduce - Install the Events, Porject & CRM apps - Create two event A & B with tickets that can be purchased - Go to Events > Configuration > Lead Generation - Create a Lead Generation…
# How to reproduce - Install the Events, Porject & CRM apps - Create two event A & B with tickets that can be purchased - Go to Events > Configuration > Lead Generation - Create a Lead Generation Rule with : - Create : Per Order - When : Attendees are created - Event : None - Create a new quotation with two lines : - Product : Even Registration for event A 1st, then B - Confirm the SO # The problem A traceback will appear # Cause of the issue When confirming the SO, we create `event.registrations`s that will check for lead generation rules and create or update `crm.lead`s accordingly : https://github.com/odoo/odoo/blob/3bf89b4f467390807c20f7b007a875a77542e76f/addons/event_crm/models/event_registration.py#L35 We will then group the registrations by leads & grouping model : https://github.com/odoo/odoo/blob/3bf89b4f467390807c20f7b007a875a77542e76f/addons/event_crm/models/event_lead_rule.py#L166 For all groups, if the lead does not exist, we create one : https://github.com/odoo/odoo/blob/3bf89b4f467390807c20f7b007a875a77542e76f/addons/event_crm/models/event_lead_rule.py#L184-L187 `_get_lead_values()` works fine with multiple `event.registrations`s, but crashes when those registrations does not have all the same event, which is our case : https://github.com/odoo/odoo/blob/3bf89b4f467390807c20f7b007a875a77542e76f/addons/event_crm/models/event_registration.py#L170 # Proposed solution Since we have multiple events and leads are associated to a single event : https://github.com/odoo/odoo/blob/3bf89b4f467390807c20f7b007a875a77542e76f/addons/event_crm/models/crm_lead.py#L11 We group the registrations by event and create multiple leads accordingly opw-6167518 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#265017
This update corrects a rounding issue that previously caused the withholding base amount on invoices to exceed the total invoice amount. The fix ensures that withholding calculations are accurate, preventing potential discrepancies in invoice totals. This improves financial reporting and reduces the risk of errors.
Original PR description
**PROBLEM** In some case, because of rounding issues, the withholding base amount can be bigger than the total amount of the invoice, which should not be the case. **STEP TO REPRODUCE** 1. Install…
**PROBLEM** In some case, because of rounding issues, the withholding base amount can be bigger than the total amount of the invoice, which should not be the case. **STEP TO REPRODUCE** 1. Install l10n_pe_edi 2. Create an invoice with those 2 lines: qty: 300, unit_price: 0.481936, tax: VAT 18% + 3% IGV Withholding qty: 300, unit_price: 0.747376, tax: VAT 18% + 3% IGV Withholding 3. Confirm the invoice, and send the xml (if this fail, you may have to change the name of the invoice, using odoo inspector or other means). 4. Open the xml, and notice the base amount for the allowance on the document level is 435.18 which is bigger than the invoice payable amount. **CAUSE** We exclude the withholding taxes to compute the invoice taxInclusiveAmount. When computing this amount, we round the line base and the tax total of the VAT 18% tax leading to the result of 435.17. When creating the allowance node for the Withholding taxes, the base used for the withholding taxes is the sum of the line base, and the tax total of previous tax NOT rounded. There is no easy way to change the withholding tax computation, so we just limit the base to not be bigger than the invoice total when there is rounding issues. opw-6010388 Forward-Port-Of: odoo/enterprise#113689
This update fixes a problem where the IT tax closing process incorrectly rejected valid quarterly VAT reports due to issues with year-end comparisons and incorrect data assumptions. The changes ensure accurate validation by correctly handling period gaps and using debit/credit columns for VAT reporting, preventing errors and improving the reliability of tax closing.
Original PR description
Description of the issue this commit addresses: The IT tax closing validation compared month numbers only, which broke across year boundaries and could reject valid quarterly progressions. It also assumed a balance column existed in monthly VAT report lines, but this report uses debit/credit columns, which could trigger a traceback. --- Desired behavior after this commit is merged: This commit computes the period gap with year-aware month deltas and aligns the allowed gap with periodicity (monthly or quarterly). It also checks VP lines using balance when present, or debit/credit as fallback, preventing crashes and ensuring consistent tax closing validation. --- opw-6131080 Forward-Port-Of: odoo/enterprise#118450 Forward-Port-Of: odoo/enterprise#117428
This update fixes an issue where payments weren't automatically linked to invoices when created after the payment was processed. Previously, invoices created while a payment was being processed would not be correctly associated with the payment, leading to reconciliation problems. This ensures payments are accurately linked to their corresponding invoices.
Original PR description
Steps to reproduce: - Ensure Automatic Invoice setting is on - Create sales order for product with ordered quantites invoicing policy - Generate a Payment Link - Pay with the ACH Direct Debit method via a provider (e.g. Stripe) - While the payment is processing, confirm the sales order, create an invoice, confirm the invoice Current Behavior: When the payment is finished processing, the payment is not automatically linked to the corresponding invoice Expected Behavior: When the payment is finished processing, the payment should be linked to the invoice despite it being created by a user Explanation: The payment transaction's link to invoice_id is severed in PaymentTransaction._invoice_sale_orders if an invoice is created before the payment is cleared. This will eventually lead to the account.payment created automatically later on not being reconciled with the invoice. opw-6087656 Forward-Port-Of: odoo/odoo#264800
This update resolves several issues related to how product attributes are displayed and handled in the Point of Sale (POS) kiosk mode. Specifically, it corrects how custom attributes are presented and ensures the 'Add to Cart' button functions correctly when a product uses a single, custom attribute. This improves the kiosk experience for users.
Original PR description
this pr fixes 3 bug, as all are closely related. Step to reproduce (hide is_custom attr in kiosk mode): - have two attributes A and B - A has only 1 attribute value with is_custom = True - B can have…
this pr fixes 3 bug, as all are closely related. Step to reproduce (hide is_custom attr in kiosk mode): - have two attributes A and B - A has only 1 attribute value with is_custom = True - B can have any two value ( ex. gender: male/female) - use it on a product and make it available in POS for kiosk - start kiosk and open that product Observation: - we do not get option to select option from A but the heading is visible - when we select from B, Add to cart is disabled. Cause: - we do not allow attribute values with is_custom = True in kiosk - but we display the attribute regardless - the Add to cart btn depends on `selectedValues`, which requires value from each attribute, in this case, we are not seletion anything from A - so it is disabled Fix: - we introduced `attributesToDisplay` which will hide heading in case of single custom value for any attribute - for Add to cart, wenow do not expect value from `is_custom` attribute values. Allow product with 1 attr which is `is_custom` to be configurable in configs other than kiosk) correct fix for commit Step to reproduce - have attributes A - A has only 1 attribute value with is_custom = True - use it on a product and make it available in POS - start pos and open that product Observation: - we do not get option to select add text for A Cause: - in pos, we consider product to be configurable only it has more than 1 attributes, which misses is_custom attr Fix: - we backport commit[1] and also considers its side effect by introducing `isProductConfigurable` for pos_self_order, which will still avoid `is_custom` attrs for kiosk [1] https://github.com/odoo/odoo/commit/5155c77a03ed2ff6c914eac41cc81ccb34b1f3c7 Empty page is displayed if product has only `is_custom` attribute value and other attribute with type other then 'no_variant' for combo item Step to reproduce - have attributes A and B - A has only 1 attribute value with is_custom = True - B has two values with type "always" - use it on a product and add that product in combo item and make it available in Kisok - start kiosk and open that combo and select that product Observation: - we do not get option to select Cause: - `availableAttributeValue` only show `no_variant` and non `is_custom` attribute values in attributeSelection component. Fix: - before mounting Attributeselection component, we check if product has required attribute or not. opw-6100965 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#266138 Forward-Port-Of: odoo/odoo#257880
This update corrects a technical issue where the FAIA report was incorrectly referencing suppliers without matching entries in the system. This ensures accurate reporting of financial data, specifically for the LU company, and resolves a validation error within the report generation process. The fix ensures data integrity for financial reporting.
Original PR description
## Steps to reproduce: 1. Install `l10n_lu_reports`, swap to the LU company 2. Look at the partner Azure Interior. 1. They have no open balances on `asset_receivable` or `liability_payable` accounts.…
## Steps to reproduce:
1. Install `l10n_lu_reports`, swap to the LU company
2. Look at the partner Azure Interior.
1. They have no open balances on `asset_receivable` or `liability_payable` accounts.
2. Their `supplier_count` is higher than their `customer_count`.
3. Navigate to Accounting > Reporting > General Ledger.
4. Select the 2026 fiscal year.
5. Select gear > FAIA report.
6. Open the downloaded file. Notice:
1. Azure Interior is listed under /MasterFiles/Customers/Customer.
2. There are no /MasterFiles/Suppliers.
3. Azure Interior's ID (14 in this case) is referenced in a /SupplierID section.
7. Take a gander at the official XSD for LU [1]. The SupplierID must match an element in /MasterFiles/Suppliers.
Video: [2]
## Explanation
This is one of several errors found with the FAIA export. See PR #113316 for more.
It's possible to have a /SupplierID listed on a /Transaction/Line element but not have a /Suppliers/Supplier element that it refers to. This is not valid according to the FAIA report's schema [1].
This happens because /Transaction/Line and /MasterFiles use different criteria to determine if a partner is a Customer or a Supplier.
The element /Transaction/Line [3] determines this from the `partner_vals['type']` value [4]. This value is 'customer' or 'supplier' and is determined by comparing the ResPartner fields `customer_rank` and `supplier_rank`. In case of a tie, the partner is assigned as a 'supplier'.
The element /MasterFiles allows a partner to be both a Customer and a Supplier via `partner_vals['types']` [5]. Partners with an open `asset_receivable` balance at the start or end of the reporting period are listed as Customers [6]. Likewise, partners with an open `liability_payable` balance are listed as Suppliers [7]. If there are no open balances, partners are put in the Customer list by default.
The XSD validation error will not show up in a standard Runbot database because the namespace for the XSD is incorrect. If you manually fix the XSD namespace (`xmlns:doc` instead of `xmlns`) and use xmllint to check a generated XML against the XSD, it will raise the following error.
> No match found for key-sequence ['14'] of keyref 'RefGLTransactionLineSupplier'. Downloads/general_ledger (5).xml fails to validate
[1] https://pfi.public.lu/dam-assets/backup/FAIA/FAIA/XSD_Files.zip. I will note that there are three XSDs. Version A has a different namespace and appears to be more restrictive. The "full" XSD document does not raise these errors.
[2] https://drive.google.com/file/d/1xeULpCcGgZk-kYcCjBTKxcfv4ICYRzaB/view?usp=sharing
[3] https://github.com/odoo/enterprise/blob/434d88960abb5e424fdc1106fc93935d328bff78/account_saft/data/saft_report.xml#L244-L248
[4] https://github.com/odoo/enterprise/blob/434d88960abb5e424fdc1106fc93935d328bff78/account_saft/models/account_general_ledger.py#L299
[5] https://github.com/odoo/enterprise/blob/434d88960abb5e424fdc1106fc93935d328bff78/account_saft/models/account_general_ledger.py#L303-L309
[6] https://github.com/odoo/enterprise/blob/434d88960abb5e424fdc1106fc93935d328bff78/account_saft/data/saft_report.xml#L153
[7] https://github.com/odoo/enterprise/blob/434d88960abb5e424fdc1106fc93935d328bff78/account_saft/data/saft_report.xml#L173
opw-6107107
Forward-Port-Of: odoo/enterprise#117799This update ensures that vendor price selections from product.supplierinfo are accurate, regardless of the user's timezone. Previously, the system incorrectly interpreted UTC dates, leading to missed price matches. This fix converts dates to the user's local timezone for precise calculations.
Original PR description
opw-6211908 ## Summary When selecting a vendor price from `product.supplierinfo`, the purchase module converts `purchase.order.date_order` (a `fields.Datetime` stored in UTC) to a `date` using…
opw-6211908 ## Summary When selecting a vendor price from `product.supplierinfo`, the purchase module converts `purchase.order.date_order` (a `fields.Datetime` stored in UTC) to a `date` using Python's `.date()` method. This extracts the **UTC calendar date** rather than the user's local date. For users in positive-offset timezones (e.g. `Pacific/Auckland` UTC+12, `Africa/Johannesburg` UTC+2), this produces the wrong day, causing `product.supplierinfo` records with `date_start`/`date_end` to be incorrectly included or excluded during vendor price selection. ### Affected methods | File | Method | |------|--------| | `addons/purchase/models/purchase_order_line.py` | `_compute_selected_seller_id` | | `addons/purchase/models/purchase_order_line.py` | `_prepare_purchase_order_line` | | `addons/purchase/models/purchase_order.py` | `_get_product_catalog_lines_data` | ### Fix Replace `.date()` calls with `fields.Date.context_today(record, timestamp=...)` which correctly converts the UTC datetime to the user's timezone before extracting the date. Also fixes `fields.Date.today()` → `fields.Date.context_today(self)` in `_prepare_purchase_order_line` for consistency (same issue — `fields.Date.today()` returns UTC date, not the user's local date). ## Steps to reproduce 1. Set user timezone to **Pacific/Auckland** (UTC+12). 2. Create a product with a vendor pricelist (`product.supplierinfo`) entry: - **Vendor**: any partner - **Price**: 50.00 - **Start Date**: 2026-05-13 - **End Date**: 2026-05-31 3. Create a **Purchase Order** for that vendor. 4. Set the **Order Deadline** to **2026-05-13 08:00** NZST (stored as `2026-05-12 20:00 UTC`). 5. Add the product as a line on the PO. **Expected**: The supplier price of 50.00 is selected — the user's local date (May 13) is within the validity window. **Actual**: No supplier price is matched. `.date()` on the UTC datetime returns `2026-05-12`, which is before `date_start` of `2026-05-13`, so the supplierinfo record is skipped. Forward-Port-Of: odoo/odoo#266468 Forward-Port-Of: odoo/odoo#263992
This update optimizes the process of exporting large datasets in Odoo reports. Previously, the system would consume significant memory when exporting many records at once. By batching the export calls and invalidating recordsets, we've reduced memory usage and slightly improved export times, especially for larger datasets.
Original PR description
When exporting a number N of records as XLSX or CSV file, we call the export_data() method for the N records at the same time. This method prefetches the selected fields for all the records which can lead to memory limit errors when N is too large. We propose to batch this call and invalidate the recordsets between batches. Benchmarks ----------- Execution time: | No records | Before PR | After PR | |------------|-----------|----------| | 70 260 | 3.82 s | 3.94 s | | 228 116 | 18.71 s | 19.36 s | | 394 381 | 31.02 s | 32.67 s | Memory usage: | No records | Before PR | After PR | |------------|-----------|----------| | 70 260 | 316.0 MB | 273.5 MB | | 228 116 | 796.9 MB | 620.8 MB | | 394 381 | 1.3 GB | 947.7 MB | opw-5881026 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#266078 Forward-Port-Of: odoo/odoo#257333
This update resolves an issue where production orders created with batch sizes on materials didn't correctly update delivery quantities. The fix ensures that all related production orders are linked to the delivery, regardless of the batch size setting, improving the accuracy of inventory tracking during sales order fulfillment. This prevents discrepancies in stock levels.
Original PR description
### Steps to reproduce: - In the settings enable: Multi-steps routes - Inventory > Configuration > Warehouse Management > Routes - Unarchive MTO - Create a storable product P with a bom using the MTO…
### Steps to reproduce: - In the settings enable: Multi-steps routes - Inventory > Configuration > Warehouse Management > Routes - Unarchive MTO - Create a storable product P with a bom using the MTO Route - In the Miscellaneous tab of the bom tick Batch Size and set it to 2 - Create and confirm a sale order for 6 units of P #### > Three MO's are created but only the last one will update the quantities of the delivery at validation of the production. ### Cause of the issue: The `move_dest_ids` of the `move_finished_ids` is only set on the last of the three productions. That is only the last MO is properly chained to the delivery via an MTO chain. This happens because the `move_dest_ids` field of the `mrp.production` model is a `One2Many` field: https://github.com/odoo/odoo/blob/a2f072fe99a03aaf521bba1965e7f29a1c99e325/addons/mrp/models/mrp_production.py#L223-L224 Which implies that each move can be linked to at most one mrp.production via the `created_production_id` field. However, if you have set a batch size on your bom, it is expected for a single move to create multiple mo's. While the `move_dest_ids` of each of these MO is appropriately set in the create vals to be the mto `stock.move` of the delivery, due to the nature of the `created_production_id` field only the *last* mo will created with a set `move_dest_ids` as this is the only record that will be set as `created_production_id`. However, after the creation of these MO's, the related `move_finished_ids` will be recomputed: https://github.com/odoo/odoo/blob/a2f072fe99a03aaf521bba1965e7f29a1c99e325/addons/mrp/models/mrp_production.py#L1089-L1093 However, the `move_dest_ids` of the created moves will be set to be either the `move_dest_ids` of their production (which is unset for all but the last one) or these of the first production of the same `production_group` that is these generated by a common production split: https://github.com/odoo/odoo/blob/a2f072fe99a03aaf521bba1965e7f29a1c99e325/addons/mrp/models/mrp_production.py#L1263-L1267 Now, since neither are set in our use case, the `move_dest_ids` will not be set on the `move_finished_ids` which implies in particular that the mto link between our productions (but the last one) and the delivery is lost. Fix: Since we can not change the nature of the `move_dest_ids` and `created_production_id` in stable to become Many2Many fields, we need to find a way to propagate the `move_dest_ids` on moves without relying on the probably inaccurate value provided by the production. And, since the compute of the `move_finished_ids` could be launched at many other points than during a create process (because of the many dependencies), we can not solely rely on the creation context but rather new to provide a way to recreate the link from relations at any given point. We therefore rely on the `stock.reference`'s similar to what was done prior to 19.0 via the `procurement_group_ids`: https://github.com/odoo/odoo/blob/132f042ca14012877f608783b57a0ca9c4e565f3/addons/mrp/models/mrp_production.py#L1198-L1202 opw-6188069 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#266184 Forward-Port-Of: odoo/odoo#264951
This update resolves an issue where UBL imports with taxes set to 'price include' were failing to correctly calculate tax amounts, particularly for invoices with multiple items. The fix ensures accurate tax retrieval and adjustment based on quantity, improving the reliability of UBL import processes. This impacts companies using UBL invoices with price-inclusive taxes.
Original PR description
**PROBLEMS** 1. On a company with taxes with price_include = True, we fail to retrieve a tax when importing a ubl. 2. The price_unit adjustement for when importing price-included taxes doesn't account for quantity. **STEP TO REPRODUCE** 1. Have a setup where the tax are only price_include. 2. Import a ubl, the taxes will not be retrieved. 3. Run odoo only with the fix for problem 1, and import the same ubl with some invoice quantity != 1 4. Notice the price unit are messed up for lines with quantity != 1 (odoo tries to correct the untaxed amount with a line, but this doesn't fixes the tax). opw-6159394 Forward-Port-Of: odoo/odoo#266107 Forward-Port-Of: odoo/odoo#262686
This update addresses a printing problem reported by a client who was unable to print without LNA. The fix involved correcting a missing check within the system, ensuring proper handling of printing requests and preventing errors. This resolves a critical issue impacting order fulfillment.
Original PR description
Based on the ticket below the client is experiencing an issue when printing without LNA. This PR fixes the missing key check opw-https://www.odoo.com/odoo/project/49/tasks/6232008 Forward-Port-Of: odoo/enterprise#118101 Forward-Port-Of: odoo/enterprise#118005
This update enhances the accessibility of carousels on our website, making them easier to navigate using a keyboard. Specifically, it adds visual focus indicators and allows users to control the carousel with 'home' and 'end' keys, improving usability for all visitors.
Original PR description
[FIX] website: improve carousel accessibility To improve keyboard accessibility on carousels, the indicators container is not focusable anymore, and the indicators themselves now only have one…
[FIX] website: improve carousel accessibility
To improve keyboard accessibility on carousels, the indicators container
is not focusable anymore, and the indicators themselves now only have
one focusable button at a time.
The tab order is thus: previous button > active indicator > next button.
(The previous and next button may both appear before.)
You can still navigate among indicators with the left and right arrows,
which also moves the focus to the newly targetted indicator.
Note that other accessibility improvements remain to be done on the
carousels (add a pause/play button on auto-sliding carousels, place the
buttons before the carousel slide in the tab order, add some aria
attributes (roledescription, live), adaptative labels...).
[FIX] website: make focus visible on carousel arrows
When focusing manually (with tab / shift+tab) the previous/next arrows
in carousels, it is hard to follow where the focus is, because there is
no outline and the contrast is too small.
This commit adds a specific outline if the button is `:focus-visible`
(with both black and white to work on any background).
[IMP] website: pause carousel on focus within
Carousels are paused on hover (or touchstart), but if the focus is
inside one, it won't pause. That can make it hard to navigate within
interactive carousels during the sliding interval (e.g. the dynamic
products, which by default has 4 different products with 3 different
focusable links/buttons).
This commit applies the same behavior on focusin as Bootstrap's default
on mouseover, and on focusout as on mouseout.
[IMP] website: support home/end keys on carousels
When the focus is in a carousel, pressing the "home" key displays the
first slide and pressing the "end" key displays the last slide.
task-5470023
Forward-Port-Of: odoo/odoo#266428
Forward-Port-Of: odoo/odoo#244939This update corrects a bug preventing employees administrators from seeing the attendance smart button for other employees. The issue stemmed from how the system determined button visibility based on user group permissions, specifically related to attendance management. The fix ensures the correct groups are recognized to display the button, improving usability for managers.
Original PR description
## Issue When logged in with a user who has the *Employee: Administrator* (`hr.group_hr_manager`) and the *User: Read his own attendances* (`hr_attendance.group_hr_attendance_own_reader`) groups, but…
## Issue
When logged in with a user who has the *Employee: Administrator* (`hr.group_hr_manager`) and the *User: Read his own attendances* (`hr_attendance.group_hr_attendance_own_reader`) groups, but not the *Officer: Manage attendances* (`hr_attendance.group_hr_attendance_officer`) group, the user won't be able to see their own attendance on their own employee's form view.
Additionally, a user without no Employee group but with the *Officer: Manage attendances* group could not see the attendance smart button on other employees form view.
## Steps to reproduce
1. Install *Attendances* (`hr_attendance`)
2. Set Marc Demo's groups:
- *Employees: Administrator*
- *Officer: Manage attendances*: unchecked
- *User: Read his own attendances*: checked (implied by Role / User)
3. Log in as Marc Demo and open his own form in Employees
4. **The attendance smart button is missing, even though Marc Demo has the group to see his own attendance.**
For the second issue:
1. Set Marc Demo's groups:
- *Employees: No*
- *Officer: Manage attendances*: checked
- *User: Read his own attendances*: checked (implied by Role / User)
2. Log in as Marc Demo and open another employee's form
3. **The attendance smart button is missing, even though Marc Demo has
the group to manage other employee's attendance.**
## Cause
There are two employee views defined in `hr_attendance`: `hr_employee_public_view_form` and `view_employee_form_inherit_hr_attendance`. The two views have different conditions under which the attendance smart button is displayed:
- In the public view, which is seen by users who do not have the *Employee: Administrator* group, the button is only displayed if the employee form is the one of the current user.
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr_attendance/views/hr_employee_public_views.xml#L9-L15
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr/models/hr_employee_public.py#L119-L123
**This means that a user without the _Employee: Administrator_ group cannot see the attendance button of other employees, even with the _Officer: Manage attendances_ group.** This view should take into account the *Attendance Manager* group.
- In the other view, which is displayed for users with the *Employee: Administrator* group, the button is only displayed for attendance officers.
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr_attendance/views/hr_employee_view.xml#L24-L29
**This means that if a user is an Employee Administrator, but is not an Attendance Officer, they cannot see their own attendance, even with the "own attendance" group.** This second view should take into account the _User: Read his own attendances_ group.
opw-6167399
Forward-Port-Of: odoo/odoo#263826This update resolves an issue where the 'Info & Tags' button was hidden on the Documents mobile Kanban view. The fix adjusts CSS styling to ensure the chatter section is always visible and accessible, improving the user experience for mobile document management. This prevents users from missing important information.
Original PR description
**Steps to reproduce:** - Go to Documents app in mobile - Go to the kanban view - Add some files and select one - Click on `Info & Tags` button in the control panel - Reload the page - Chatter is not…
**Steps to reproduce:** - Go to Documents app in mobile - Go to the kanban view - Add some files and select one - Click on `Info & Tags` button in the control panel - Reload the page - Chatter is not displayed but the button is still enabled - Switching to the list view properly shows it **Issue:** We have two conflicting css styling on mobile: - `overflow-hidden` was added for mobile to avoid multiple scroll bars - `min-height: 100%` which is due to the default `o_kanban_ungrouped` in the controller css This means that the element is present at the bottom of the page, but we can't get to it manually. When re-enabling the action we are properly moved to the existing chatter (but we can't go back to the top). Also the documents panel should have a single scrollbar to display all the records, but we still need a way to scroll the messages of the chatter. **Fix:** Set `min-height: 0;` for documents kanban to ensure the chatter is still visible and accessible on mobile by default. This makes the chatter take the full available height when displayed. original overflow fix: https://github.com/odoo/enterprise/commit/945b9e2b1c6752bd905695aa40b0babcf38c50cd opw-6061993 Forward-Port-Of: odoo/enterprise#118134 Forward-Port-Of: odoo/enterprise#113168
This update optimizes how the Point of Sale system calculates prices, particularly when dealing with complex product pricing lists. By streamlining the process, the system now responds faster, enhancing the overall user experience. This change improves the efficiency of price calculations within the POS module.
Original PR description
The getPrice function in product_template_accounting.js was a performance bottleneck when using large pricelists. This commit introduces the following optimizations: 1. Pre-index pricelist rules by product_id and product_tmpl_id at load time in ProductPricelist. 2. Replace the sort() operation with a single-pass scan to find the best matching rule (highest min_quantity that satisfies the current quantity). 3. Apply sequential rule precedence (Variant → Template → General), stopping as soon as a valid rule is found. 4. Move rule mappings from uiState to direct properties in ProductPricelist to avoid useless reactivity. 5. Centralize rule selection logic in ProductPricelist for better responsibility separation. task-id: 5965826 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#244268
This update fixes an issue where COGS calculations were inaccurate, particularly with multi-stage customer returns. It ensures that quantity conversions are applied correctly and that the 'value' field on stock moves is only set when a move is fully completed, preventing incorrect monetary values from being applied to intermediate return steps. This improves the accuracy of COGS reporting.
Original PR description
[FIX] sale_stock: convert quantity using correct UoM The quantity unit conversion was applied to an already summed value, ignoring the fact that individual COGS lines may have different UoMs. --- [FIX] stock_account: Do not copy field 'value' of StockMove When a customer return is split into multiple steps (e.g., Customer -> Input -> Stock), the `value` field of the stock move was being copied from the first step to the second. This caused the second step (which should not be valued) to inherit the monetary value, leading to incorrect COGS entries when the invoice was posted. The value should only be set when the move is Done, not during a copy. --- OPW-6076350 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#260495 Forward-Port-Of: odoo/odoo#257543
This update replaces the older PostgreSQL 12 installer with a newer version (16). This is necessary because PostgreSQL 12 is no longer supported, ensuring continued stability and security for our Odoo SaaS platform. Additionally, the installer now uses a dedicated Odoo user for database connections, improving security.
Original PR description
The Windows installer installs PostgreSQL 12. That version was chosen for its small size, but now in 2026 the size doesn't matter as much anymore. Also, version 12 is no longer supported, so it's time to bump to version 16. While at it, this commit adds an Odoo user for the PostgreSQL connection instead of using the superuser. Forward-Port-Of: odoo/odoo#266059 Forward-Port-Of: odoo/odoo#265134
This update resolves issues preventing IoT drivers from receiving websocket messages due to startup problems. Specifically, it handles scenarios where the device initially lacks an IP or database connection, and ensures the websocket client starts correctly after a successful data transmission attempt. This enhances the stability and reliability of data transfer from IoT devices.
Original PR description
This commit fixes several issues which can cause websocket messages to not be received: 1. If the IoT box does not have an IP when it first starts, the Websocket class will not be started (due to…
This commit fixes several issues which can cause websocket messages to not be received: 1. If the IoT box does not have an IP when it first starts, the Websocket class will not be started (due to `@require_db`). It will remain closed even if the IoT box connects to the network shortly after. 2. If the IoT box does have an IP but can't reach the database when it starts, the Websocket client will crash due to a missing try/except around the request to get a session from the DB. 3. If the IoT box fails the first `send_all_devices` call, the websocket channel will not be set when the Websocket client starts. This causes no messages to be received, since it does not subscribe to the channel. The changes are as follows: 1. The `@require_db` helper is removed from the Websocket client, and instead the server URL is provided explicitly. 2. Any exception raised by the session request is caught and logged, and the websocket can still continue connect attempts. 3. Instead of starting the websocket client after the first call to `send_all_devices`, it is started after the first *successful* call to `send_all_devices` so the channel is guaranteed to be set. 4. The closing status code is now logged as a warning instead of debug. This is to make it easier to troubleshoot websocket disconnections at a glance. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#266710
This update corrects a bug that prevented accurate invoice generation for Point of Sale (POS) orders. Previously, the system couldn't properly process lot numbers from POS orders, leading to errors. This fix ensures that POS order lot information is correctly linked to invoices, improving order accuracy and financial reporting.
Original PR description
POS order lines store lot/serial numbers as `pos.pack.operation.lot` records, while the shared invoice lot hooks expect `stock.lot` records. When `sale_stock_product_expiry` extends the invoice lot values, it reads `expiration_date` from the received lot. For invoiced POS orders, this crashes because POS passes a `pos.pack.operation.lot`, which has no such field. Resolve the matching `stock.lot` from the POS lot name, product, and company before extracting extra invoice lot values. opw-6193332 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#263495
This update fixes an issue where users weren't notified when expense authorizations were updated or cancelled. Previously, the system ignored events related to authorization changes, preventing users from knowing their expenses were affected. This change ensures users receive timely updates regarding their expense authorizations.
Original PR description
## [FIX] hr_expense_stripe: Fix error messages coherence Fix the incoherent punctuation ## [FIX] hr_expense_stripe: Fix reversed and expired authorizations Before this, when receiving an `issuing_authorization.updated` event, the event would be ignored and the user would never know that the expense had been cancelled opw-6210055 Forward-Port-Of: odoo/enterprise#118574 Forward-Port-Of: odoo/enterprise#117257
14 changes
Enhancements to existing features
This pull request includes performance optimizations across several Odoo modules, primarily focused on improving the speed and responsiveness of key business processes. These changes address identified bottlenecks and enhance the overall user experience. The update is part of the Odoo 19.2 release, ensuring a smoother and more efficient Odoo environment.
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update introduces a new EC Sales list report specifically for Hungary, providing more detailed sales data. Instead of grouping solely by customer, it now analyzes transactions based on transaction type (e.g., B, C) and transaction state (U or T), ensuring accurate reporting according to Hungarian regulations. This allows for a more granular view of sales activity.
Original PR description
This commit implement the EC Sales list for Hungary This report is a bit different from the main EC Sales list, instead of just grouping the lines on partner_id, we need to group on specifics fields on account.move: - l10n_hu_transaction_type: B, C, K, R or V This field represente the type of Intra Community Transaction, it's a selection field with all the legal possible values. We leave the field blank for normal transactions. - l10n_hu_transaction_state: U or T Represent if the transaction is a new one (U) or a correction (T) The grouping of the report works like this: groupby partner_id, l10n_hu_transaction_type, l10n_hu_transaction_state This mean for a single partner, we can have up to 12 different lines. [task-4950959](https://www.odoo.com/odoo/project/967/tasks/4950959) Linked:https://github.com/odoo/enterprise/pull/110448 Forward-Port-Of: odoo/odoo#253556
This update introduces a new EC Sales list report specifically for Hungarian businesses. The report now groups sales data by tax codes (B, C, K, R & V) instead of just customer ID, aligning with Hungarian tax regulations. It also includes the necessary tax return data for this report.
Original PR description
This report is a bit different from the main EC Sales list, instead of just grouping the lines on partner_id, we need to group on specifics tax.tags [B, C, K, R & V]. It also adds the tax returns for this same report. [task-4950959](https://www.odoo.com/odoo/project/967/tasks/4950959) Linked:https://github.com/odoo/odoo/pull/253556 Forward-Port-Of: odoo/enterprise#110448
Resolved issues and error corrections
This update resolves issues preventing IoT drivers from receiving websocket messages due to startup problems. Specifically, it handles scenarios where the device initially lacks an IP or database connection, and ensures the websocket client starts correctly after a successful device send attempt. This enhances the reliability of data transmission from IoT devices.
Original PR description
This commit fixes several issues which can cause websocket messages to not be received: 1. If the IoT box does not have an IP when it first starts, the Websocket class will not be started (due to…
This commit fixes several issues which can cause websocket messages to not be received: 1. If the IoT box does not have an IP when it first starts, the Websocket class will not be started (due to `@require_db`). It will remain closed even if the IoT box connects to the network shortly after. 2. If the IoT box does have an IP but can't reach the database when it starts, the Websocket client will crash due to a missing try/except around the request to get a session from the DB. 3. If the IoT box fails the first `send_all_devices` call, the websocket channel will not be set when the Websocket client starts. This causes no messages to be received, since it does not subscribe to the channel. The changes are as follows: 1. The `@require_db` helper is removed from the Websocket client, and instead the server URL is provided explicitly. 2. Any exception raised by the session request is caught and logged, and the websocket can still continue connect attempts. 3. Instead of starting the websocket client after the first call to `send_all_devices`, it is started after the first *successful* call to `send_all_devices` so the channel is guaranteed to be set. 4. The closing status code is now logged as a warning instead of debug. This is to make it easier to troubleshoot websocket disconnections at a glance. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update ensures that backorders created during point-of-sale transactions are correctly linked to the original POS order. Previously, these backorders lacked a connection, making inventory management more complex. This fix streamlines the process by maintaining a clear link between the POS order and all associated backorder pickings.
Original PR description
The delivery transfer for a product tracked by serial number is not linked to the POS order when there is no available stock. When validating a POS delivery in real time, stock can split the transfer…
The delivery transfer for a product tracked by serial number is not linked to the POS order when there is no available stock. When validating a POS delivery in real time, stock can split the transfer into a completed picking and a backorder (e.g. one line fully delivered with lots, another serial-tracked line with no stock and no serial number). Steps to reproduce: ------------------- * Setup two products: one tracked by qunatity with some quantity on-hand an other tracked by SN but no quantity on-hand * Open Pos * Sell in one order, both products without providing SN * Validate payment * Open Inventory: two deliveries sould exist under Inventory Overview of PoS Orders > Observation: The first picking shows the POS order as Source Document but the backorder has no source document and is not linked to the POS order. Why the fix: ------------ Pos Origin (Source Document, POS order, session) was only written on the pickings returned by `_create_picking_from_pos_order_lines`, which did not include pickings created during `_action_done()`. Extend the write to the initial pickings and their backorders so every transfer stays tied to the originating `pos.order`. opw-6090606 Forward-Port-Of: odoo/odoo#266111 Forward-Port-Of: odoo/odoo#259370
This update resolves an issue where UBL imports with taxes set to 'price_include' were failing to correctly calculate and apply taxes, particularly for invoices with multiple items. The fix ensures accurate tax calculations and adjustments, especially when quantities vary, improving the reliability of UBL import processes.
Original PR description
**PROBLEMS** 1. On a company with taxes with price_include = True, we fail to retrieve a tax when importing a ubl. 2. The price_unit adjustement for when importing price-included taxes doesn't account for quantity. **STEP TO REPRODUCE** 1. Have a setup where the tax are only price_include. 2. Import a ubl, the taxes will not be retrieved. 3. Run odoo only with the fix for problem 1, and import the same ubl with some invoice quantity != 1 4. Notice the price unit are messed up for lines with quantity != 1 (odoo tries to correct the untaxed amount with a line, but this doesn't fixes the tax). opw-6159394 Forward-Port-Of: odoo/odoo#266107 Forward-Port-Of: odoo/odoo#262686
This update resolves a potential issue that caused Out of Memory errors during the installation of the `sale_subscription` module on databases with extensive sales order data. The fix ensures that newly added fields are correctly initialized to 'null' during installation, preventing performance bottlenecks and installation failures.
Original PR description
### Description: Installing `sale_subscription` on databases with a large number of `sale.order` and `sale.order.line` can cause Out of Memory (OOM) errors. The issue comes from two stored compute fields, `last_invoiced_date` and `plan_id`. Since these depend on newly added fields, they should default to `null` during installation. ### Reference: opw-6201267 Forward-Port-Of: odoo/enterprise#118419 Forward-Port-Of: odoo/enterprise#118008
This update resolves a printing problem reported by a client who was unable to print without LNA. The fix addresses a missing check that was causing errors during the printing process. This ensures consistent printing functionality for all users.
Original PR description
Based on the ticket below the client is experiencing an issue when printing without LNA. This PR fixes the missing key check opw-https://www.odoo.com/odoo/project/49/tasks/6232008 Forward-Port-Of: odoo/enterprise#118101 Forward-Port-Of: odoo/enterprise#118005
This update enhances the accessibility of carousels on our website, making them easier to navigate using a keyboard. Specifically, it adds visual focus indicators, pauses the carousel when focused, and supports 'home' and 'end' keys for navigation. These changes improve the user experience for all visitors, particularly those using assistive technologies.
Original PR description
[FIX] website: improve carousel accessibility To improve keyboard accessibility on carousels, the indicators container is not focusable anymore, and the indicators themselves now only have one…
[FIX] website: improve carousel accessibility
To improve keyboard accessibility on carousels, the indicators container
is not focusable anymore, and the indicators themselves now only have
one focusable button at a time.
The tab order is thus: previous button > active indicator > next button.
(The previous and next button may both appear before.)
You can still navigate among indicators with the left and right arrows,
which also moves the focus to the newly targetted indicator.
Note that other accessibility improvements remain to be done on the
carousels (add a pause/play button on auto-sliding carousels, place the
buttons before the carousel slide in the tab order, add some aria
attributes (roledescription, live), adaptative labels...).
[FIX] website: make focus visible on carousel arrows
When focusing manually (with tab / shift+tab) the previous/next arrows
in carousels, it is hard to follow where the focus is, because there is
no outline and the contrast is too small.
This commit adds a specific outline if the button is `:focus-visible`
(with both black and white to work on any background).
[IMP] website: pause carousel on focus within
Carousels are paused on hover (or touchstart), but if the focus is
inside one, it won't pause. That can make it hard to navigate within
interactive carousels during the sliding interval (e.g. the dynamic
products, which by default has 4 different products with 3 different
focusable links/buttons).
This commit applies the same behavior on focusin as Bootstrap's default
on mouseover, and on focusout as on mouseout.
[IMP] website: support home/end keys on carousels
When the focus is in a carousel, pressing the "home" key displays the
first slide and pressing the "end" key displays the last slide.
task-5470023
Forward-Port-Of: odoo/odoo#266428
Forward-Port-Of: odoo/odoo#244939This update corrects a bug preventing employees administrators from seeing the attendance smart button for other employees. The issue stemmed from how the system determined who could view attendance based on group permissions. Now, users with the necessary administrator and attendance manager groups will correctly see the button, ensuring efficient attendance management.
Original PR description
## Issue When logged in with a user who has the *Employee: Administrator* (`hr.group_hr_manager`) and the *User: Read his own attendances* (`hr_attendance.group_hr_attendance_own_reader`) groups, but…
## Issue
When logged in with a user who has the *Employee: Administrator* (`hr.group_hr_manager`) and the *User: Read his own attendances* (`hr_attendance.group_hr_attendance_own_reader`) groups, but not the *Officer: Manage attendances* (`hr_attendance.group_hr_attendance_officer`) group, the user won't be able to see their own attendance on their own employee's form view.
Additionally, a user without no Employee group but with the *Officer: Manage attendances* group could not see the attendance smart button on other employees form view.
## Steps to reproduce
1. Install *Attendances* (`hr_attendance`)
2. Set Marc Demo's groups:
- *Employees: Administrator*
- *Officer: Manage attendances*: unchecked
- *User: Read his own attendances*: checked (implied by Role / User)
3. Log in as Marc Demo and open his own form in Employees
4. **The attendance smart button is missing, even though Marc Demo has the group to see his own attendance.**
For the second issue:
1. Set Marc Demo's groups:
- *Employees: No*
- *Officer: Manage attendances*: checked
- *User: Read his own attendances*: checked (implied by Role / User)
2. Log in as Marc Demo and open another employee's form
3. **The attendance smart button is missing, even though Marc Demo has
the group to manage other employee's attendance.**
## Cause
There are two employee views defined in `hr_attendance`: `hr_employee_public_view_form` and `view_employee_form_inherit_hr_attendance`. The two views have different conditions under which the attendance smart button is displayed:
- In the public view, which is seen by users who do not have the *Employee: Administrator* group, the button is only displayed if the employee form is the one of the current user.
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr_attendance/views/hr_employee_public_views.xml#L9-L15
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr/models/hr_employee_public.py#L119-L123
**This means that a user without the _Employee: Administrator_ group cannot see the attendance button of other employees, even with the _Officer: Manage attendances_ group.** This view should take into account the *Attendance Manager* group.
- In the other view, which is displayed for users with the *Employee: Administrator* group, the button is only displayed for attendance officers.
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr_attendance/views/hr_employee_view.xml#L24-L29
**This means that if a user is an Employee Administrator, but is not an Attendance Officer, they cannot see their own attendance, even with the "own attendance" group.** This second view should take into account the _User: Read his own attendances_ group.
opw-6167399
Forward-Port-Of: odoo/odoo#263826This update resolves an issue preventing users from unreconciling SEPA CT payments with a 'pending' online status. Previously, the system incorrectly blocked this process, causing delays in bank statement reconciliation. The fix allows internal unreconciliation flows to bypass validation, ensuring accurate bank statement matching.
Original PR description
**Issue:** The account_online_payment module overrides `action_draft` to raise a UserError for sepa_ct payments belonging to a batch with a `payment_online_status` = 'pending' or 'accepted'. This…
**Issue:** The account_online_payment module overrides `action_draft` to raise a UserError for sepa_ct payments belonging to a batch with a `payment_online_status` = 'pending' or 'accepted'. This blocks the bank statement unreconciliation process. When `delete_reconciled_line` is called, it tries to set payments to draft and re-post them, despite it being an internal process not a manual user modification. **Steps to reproduce:** - Setup a 'sepa_ct' payment method on a bank journal. - Create a bill with a vendor with a trusted bank account. - Create a payment for that bill with a 'sepa_ct' payment method. - Add the payment to a batch. - Manually set the `payment_online_status` = 'pending'. - Create a bank transaction and reconcile it with the batch. - Try to unreconcile the lines on the transaction - Result: UserError 'You cannot modify a payment that has already been sent to the bank.' **Fix:** Pass a context flag to `action_draft` during the unreconciliation flow so that the validation is skipped when the call originates from the internal unreconcile flow. OPW-6080464 Forward-Port-Of: odoo/enterprise#118206 Forward-Port-Of: odoo/enterprise#117921
This update resolves an issue where Live Chat users were unable to access chatbot messages due to restricted access controls. The fix adjusts permissions to allow users with the 'Live Chat / User' role to access the necessary data, ensuring proper functionality of the Live Chat feature. This change was triggered by a previous update.
Original PR description
**Steps to Reproduce** 1. Install the **Live Chat** module in version 18.4 or above. 2. Go to: **Settings → Users** * Open your user and change the access rights from **Live Chat / Administrator** to…
**Steps to Reproduce**
1. Install the **Live Chat** module in version 18.4 or above.
2. Go to: **Settings → Users**
* Open your user and change the access rights from **Live Chat / Administrator** to **Live Chat / User**.
* Alternatively, create a new user giving him rights of the **Live Chat / User** group.
3. Login using the Live Chat user.
4. Open the **Live Chat** application and navigate to: **Live Chat → Sessions**
5. Open any existing session. The session and its messages are accessible without any issue.
6. In the search bar, click: **Filters → Custom Filter**
7. Select the field `Chatbot Messages (chatbot_message_ids)`. You will face the below traceback.
**Issue Description:**
The issue happens because `discuss.channel` records are accessible to users having the `im_livechat_group_user` group through the Sessions menu: https://github.com/odoo/odoo/blob/459a775a066fe1465e53fc751045baed39f80118/addons/im_livechat/views/im_livechat_channel_views.xml#L310-L315
The field `chatbot_message_ids` is defined as:
https://github.com/odoo/odoo/blob/459a775a066fe1465e53fc751045baed39f80118/addons/im_livechat/models/discuss_channel.py#L165
This field points to the `chatbot.message` model, but access to that model is restricted to `im_livechat_group_manager` only:
https://github.com/odoo/odoo/blob/459a775a066fe1465e53fc751045baed39f80118/addons/im_livechat/security/ir.model.access.csv#L15
As a result, when a Live Chat user tries to use `chatbot_message_ids` in a custom filter, Odoo attempts to read `chatbot.message` records and raises an `AccessError`.
This issue started happening after the access rights changes introduced in pr : https://github.com/odoo/odoo/pull/201880
Specifically, the following ACL changes:
https://github.com/odoo/odoo/pull/201880/changes#diff-c1592d633a34db44a7cc2a527482cecc56127cbba72649e7318dcf63ccf477afR19-R20
**Solution:**
To fix this issue, added the group `im_livechat_group_manager` on the field `chatbot_message_ids` so only those user can access the field who belong to the group.
**Traceback:**
```.py
odoo.exceptions.AccessError: You are not allowed to access
'Chatbot Message' (chatbot.message) records.
This operation is allowed for the following groups:
- Live Chat/Administrator
Contact your administrator to request access if necessary.
```
opw - [6169395]
upg - [4274573]
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#264682This update resolves an issue where the 'Info & Tags' button was hidden in the mobile Documents app's kanban view. The fix adjusts CSS styling to ensure the chatter is always visible and accessible, improving usability for mobile users. This prevents a frustrating experience when accessing document details.
Original PR description
**Steps to reproduce:** - Go to Documents app in mobile - Go to the kanban view - Add some files and select one - Click on `Info & Tags` button in the control panel - Reload the page - Chatter is not…
**Steps to reproduce:** - Go to Documents app in mobile - Go to the kanban view - Add some files and select one - Click on `Info & Tags` button in the control panel - Reload the page - Chatter is not displayed but the button is still enabled - Switching to the list view properly shows it **Issue:** We have two conflicting css styling on mobile: - `overflow-hidden` was added for mobile to avoid multiple scroll bars - `min-height: 100%` which is due to the default `o_kanban_ungrouped` in the controller css This means that the element is present at the bottom of the page, but we can't get to it manually. When re-enabling the action we are properly moved to the existing chatter (but we can't go back to the top). Also the documents panel should have a single scrollbar to display all the records, but we still need a way to scroll the messages of the chatter. **Fix:** Set `min-height: 0;` for documents kanban to ensure the chatter is still visible and accessible on mobile by default. This makes the chatter take the full available height when displayed. original overflow fix: https://github.com/odoo/enterprise/commit/945b9e2b1c6752bd905695aa40b0babcf38c50cd opw-6061993 Forward-Port-Of: odoo/enterprise#118134 Forward-Port-Of: odoo/enterprise#113168
This update fixes a problem where users weren't notified when an expense's payment authorization status changed (e.g., cancelled). The fix ensures that users receive timely updates, improving the accuracy of expense tracking and reducing potential errors. This resolves an issue reported by internal teams.
Original PR description
## [FIX] hr_expense_stripe: Fix error messages coherence Fix the incoherent punctuation ## [FIX] hr_expense_stripe: Fix reversed and expired authorizations Before this, when receiving an `issuing_authorization.updated` event, the event would be ignored and the user would never know that the expense had been cancelled opw-6210055 Forward-Port-Of: odoo/enterprise#117257
20 changes
New functionality added to Odoo
This update introduces support for Indonesian tax returns within the Odoo Enterprise system. A new module, `l10n_id_reports`, has been created to manage these specific return types, allowing businesses operating in Indonesia to accurately report their tax obligations. This enhancement improves compliance and reporting capabilities for our Indonesian customers.
Original PR description
Create new module l10n_id_reports and add return type for Indonesia. task-6239169 Forward-Port-Of: odoo/enterprise#118304
Enhancements to existing features
This update introduces a new EC Sales list report specifically for Hungary, providing more detailed sales data. Instead of grouping solely by partner, it now analyzes transactions based on transaction type (B, C, K, R, V) and transaction state (U or T), offering a more accurate view of intra-community sales. This improves reporting capabilities for Hungarian businesses.
Original PR description
This commit implement the EC Sales list for Hungary This report is a bit different from the main EC Sales list, instead of just grouping the lines on partner_id, we need to group on specifics fields on account.move: - l10n_hu_transaction_type: B, C, K, R or V This field represente the type of Intra Community Transaction, it's a selection field with all the legal possible values. We leave the field blank for normal transactions. - l10n_hu_transaction_state: U or T Represent if the transaction is a new one (U) or a correction (T) The grouping of the report works like this: groupby partner_id, l10n_hu_transaction_type, l10n_hu_transaction_state This mean for a single partner, we can have up to 12 different lines. [task-4950959](https://www.odoo.com/odoo/project/967/tasks/4950959) Linked:https://github.com/odoo/enterprise/pull/110448
This update enhances the OBOX order process within Self Order and Point of Sale systems. It now includes a timeout feature, allowing orders to be tracked even when devices aren't on the same network as the OBOX. This improves reliability and order fulfillment for users with disconnected devices.
Original PR description
Is now possible to await OBOX jobs with a specific timeout in PoS ans Self Order. This is usefull when the user device isn't connected on the same network as the OBOX and others hardware. taskId: 6248159
This update enhances the way Odoo handles communication with OBOX devices in Self and Point of Sale environments. It now includes a timeout feature, allowing for reliable operation even when devices aren't on the same network, improving overall system stability and usability.
Original PR description
Is now possible to await OBOX jobs with a specific timeout in PoS ans Self Order. This is usefull when the user device isn't connected on the same network as the OBOX and others hardware. taskId: 6248159
Resolved issues and error corrections
This update fixes a problem where users weren't notified when an expense authorization status changed (e.g., cancelled). The system now correctly responds to authorization updates, ensuring users are informed about the status of their expenses. This improves transparency and accuracy in expense tracking.
Original PR description
## [FIX] hr_expense_stripe: Fix error messages coherence Fix the incoherent punctuation ## [FIX] hr_expense_stripe: Fix reversed and expired authorizations Before this, when receiving an `issuing_authorization.updated` event, the event would be ignored and the user would never know that the expense had been cancelled opw-6210055 Forward-Port-Of: odoo/enterprise#117257
This update fixes an issue where UBL imports with taxes set to 'price_include' were failing to correctly calculate and apply taxes, especially for invoices with multiple items. The fix ensures accurate tax calculations and adjustments, addressing a potential revenue discrepancy during UBL import processes. This improves the reliability of our accounting data.
Original PR description
**PROBLEMS** 1. On a company with taxes with price_include = True, we fail to retrieve a tax when importing a ubl. 2. The price_unit adjustement for when importing price-included taxes doesn't account for quantity. **STEP TO REPRODUCE** 1. Have a setup where the tax are only price_include. 2. Import a ubl, the taxes will not be retrieved. 3. Run odoo only with the fix for problem 1, and import the same ubl with some invoice quantity != 1 4. Notice the price unit are messed up for lines with quantity != 1 (odoo tries to correct the untaxed amount with a line, but this doesn't fixes the tax). opw-6159394 Forward-Port-Of: odoo/odoo#266107 Forward-Port-Of: odoo/odoo#262686
This update enhances the website's carousel functionality to be more accessible for all users, particularly those using keyboard navigation. The changes include making focus visible, pausing the carousel when focused, and supporting 'home' and 'end' keys for easy navigation. These improvements align with accessibility standards and provide a better user experience.
Original PR description
[FIX] website: improve carousel accessibility To improve keyboard accessibility on carousels, the indicators container is not focusable anymore, and the indicators themselves now only have one…
[FIX] website: improve carousel accessibility
To improve keyboard accessibility on carousels, the indicators container
is not focusable anymore, and the indicators themselves now only have
one focusable button at a time.
The tab order is thus: previous button > active indicator > next button.
(The previous and next button may both appear before.)
You can still navigate among indicators with the left and right arrows,
which also moves the focus to the newly targetted indicator.
Note that other accessibility improvements remain to be done on the
carousels (add a pause/play button on auto-sliding carousels, place the
buttons before the carousel slide in the tab order, add some aria
attributes (roledescription, live), adaptative labels...).
[FIX] website: make focus visible on carousel arrows
When focusing manually (with tab / shift+tab) the previous/next arrows
in carousels, it is hard to follow where the focus is, because there is
no outline and the contrast is too small.
This commit adds a specific outline if the button is `:focus-visible`
(with both black and white to work on any background).
[IMP] website: pause carousel on focus within
Carousels are paused on hover (or touchstart), but if the focus is
inside one, it won't pause. That can make it hard to navigate within
interactive carousels during the sliding interval (e.g. the dynamic
products, which by default has 4 different products with 3 different
focusable links/buttons).
This commit applies the same behavior on focusin as Bootstrap's default
on mouseover, and on focusout as on mouseout.
[IMP] website: support home/end keys on carousels
When the focus is in a carousel, pressing the "home" key displays the
first slide and pressing the "end" key displays the last slide.
task-5470023
Forward-Port-Of: odoo/odoo#266428
Forward-Port-Of: odoo/odoo#244939This update corrects a bug preventing employees administrators from seeing the attendance smart button for other employees. The issue stemmed from how the system determined button visibility based on group permissions, specifically relating to attendance management. The fix ensures the button appears correctly for users with the necessary 'Employee: Administrator' and 'Officer: Manage attendances' groups.
Original PR description
## Issue When logged in with a user who has the *Employee: Administrator* (`hr.group_hr_manager`) and the *User: Read his own attendances* (`hr_attendance.group_hr_attendance_own_reader`) groups, but…
## Issue
When logged in with a user who has the *Employee: Administrator* (`hr.group_hr_manager`) and the *User: Read his own attendances* (`hr_attendance.group_hr_attendance_own_reader`) groups, but not the *Officer: Manage attendances* (`hr_attendance.group_hr_attendance_officer`) group, the user won't be able to see their own attendance on their own employee's form view.
Additionally, a user without no Employee group but with the *Officer: Manage attendances* group could not see the attendance smart button on other employees form view.
## Steps to reproduce
1. Install *Attendances* (`hr_attendance`)
2. Set Marc Demo's groups:
- *Employees: Administrator*
- *Officer: Manage attendances*: unchecked
- *User: Read his own attendances*: checked (implied by Role / User)
3. Log in as Marc Demo and open his own form in Employees
4. **The attendance smart button is missing, even though Marc Demo has the group to see his own attendance.**
For the second issue:
1. Set Marc Demo's groups:
- *Employees: No*
- *Officer: Manage attendances*: checked
- *User: Read his own attendances*: checked (implied by Role / User)
2. Log in as Marc Demo and open another employee's form
3. **The attendance smart button is missing, even though Marc Demo has
the group to manage other employee's attendance.**
## Cause
There are two employee views defined in `hr_attendance`: `hr_employee_public_view_form` and `view_employee_form_inherit_hr_attendance`. The two views have different conditions under which the attendance smart button is displayed:
- In the public view, which is seen by users who do not have the *Employee: Administrator* group, the button is only displayed if the employee form is the one of the current user.
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr_attendance/views/hr_employee_public_views.xml#L9-L15
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr/models/hr_employee_public.py#L119-L123
**This means that a user without the _Employee: Administrator_ group cannot see the attendance button of other employees, even with the _Officer: Manage attendances_ group.** This view should take into account the *Attendance Manager* group.
- In the other view, which is displayed for users with the *Employee: Administrator* group, the button is only displayed for attendance officers.
https://github.com/odoo/odoo/blob/b13d831e4c3c27ec7756302270f78c15f576a296/addons/hr_attendance/views/hr_employee_view.xml#L24-L29
**This means that if a user is an Employee Administrator, but is not an Attendance Officer, they cannot see their own attendance, even with the "own attendance" group.** This second view should take into account the _User: Read his own attendances_ group.
opw-6167399
Forward-Port-Of: odoo/odoo#263826This update resolves an issue where the 'Info & Tags' button was hidden on the Documents mobile Kanban view. The fix adjusts CSS styling to ensure the chatter section is always visible and accessible, providing users with the necessary functionality on mobile devices. This improves the user experience for accessing document details.
Original PR description
**Steps to reproduce:** - Go to Documents app in mobile - Go to the kanban view - Add some files and select one - Click on `Info & Tags` button in the control panel - Reload the page - Chatter is not…
**Steps to reproduce:** - Go to Documents app in mobile - Go to the kanban view - Add some files and select one - Click on `Info & Tags` button in the control panel - Reload the page - Chatter is not displayed but the button is still enabled - Switching to the list view properly shows it **Issue:** We have two conflicting css styling on mobile: - `overflow-hidden` was added for mobile to avoid multiple scroll bars - `min-height: 100%` which is due to the default `o_kanban_ungrouped` in the controller css This means that the element is present at the bottom of the page, but we can't get to it manually. When re-enabling the action we are properly moved to the existing chatter (but we can't go back to the top). Also the documents panel should have a single scrollbar to display all the records, but we still need a way to scroll the messages of the chatter. **Fix:** Set `min-height: 0;` for documents kanban to ensure the chatter is still visible and accessible on mobile by default. This makes the chatter take the full available height when displayed. original overflow fix: https://github.com/odoo/enterprise/commit/945b9e2b1c6752bd905695aa40b0babcf38c50cd opw-6061993 Forward-Port-Of: odoo/enterprise#118134 Forward-Port-Of: odoo/enterprise#113168
This update ensures that all point-of-sale orders, including those that have been invoiced, are now accurately reflected in the periodic sales digest emails. Previously, only un-invoiced orders were counted, leading to an incomplete view of sales performance. This fix corrects this issue, providing a more reliable report.
Original PR description
Currently in the periodic digest sent by mail only the pos orders that are not invoiced are counted. Steps to reproduce: ------------------- * On empty db (no order previously) * Create a pos order of 10$, don't invoice it * Create a pos order of 10$, invoice it * Close session * Generate the periodic digest: * Go to settings * Under Emails, find "Digest Email" * Select "Configure digest emails" * Select "Your Odoo Periodic Digest" * Make sure "Pos Sales" is ticked * Select "Send Now" * In debug: * In the settings, under Technical, select Emails > Emails * Select the Periodic Digest > Observation: In the point of sale tab, it shows only 10$ Why the fix: ------------ Previously pos orders that were invoiced were not taken into account, now they are. opw-6111304 Forward-Port-Of: odoo/odoo#262561
This update strengthens the security of our Point of Sale system by ensuring that the correct access token is being used. The `PosCustomerDisplay` controller now validates incoming access tokens, preventing unauthorized access and improving overall system security. This change was implemented as part of a broader effort to enhance security protocols.
Original PR description
In this commit we adapt the `PosCustomerDisplay` controller such that it checks that the correct `pos.access_token` was sent. Task: 6144690 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#262287 Forward-Port-Of: odoo/odoo#261545
This update replaces the older PostgreSQL 12 version in the Windows installer with the more current PostgreSQL 16. This change addresses end-of-life support for the previous version and improves security. Additionally, the installer now uses a dedicated Odoo user for database connections, enhancing security and stability.
Original PR description
The Windows installer installs PostgreSQL 12. That version was chosen for its small size, but now in 2026 the size doesn't matter as much anymore. Also, version 12 is no longer supported, so it's time to bump to version 16. While at it, this commit adds an Odoo user for the PostgreSQL connection instead of using the superuser. Forward-Port-Of: odoo/odoo#266059 Forward-Port-Of: odoo/odoo#265134
This update resolves an issue where delivery orders could be completed without recording serial numbers for tracked products, leading to data inconsistencies. The fix ensures that the quantity and serial number information are correctly synchronized during delivery order creation, preventing errors and maintaining accurate inventory tracking.
Original PR description
Writing both `quantity` and `lot_ids` on a tracked move in the same form save leaves `move.quantity` stored at the user value while `_set_lot_ids` unlinks the remaining move line; the picking can then be validated to 'done' with no serial recorded. Force `_compute_quantity` at the end of `_set_lot_ids` so the stored value stays in sync with the move lines. Steps to reproduce: - Serial-tracked product, 6 in stock - Create a delivery order for 6 units of that product - In the delivery form, on the move row: type "1" in Quantity and remove all 6 lots from the Serial Numbers widget. - Save, Validate Before: picking goes to Done with quantity=1 and no serial. After: clear UserError, quantity stays in sync with mls. opw-6192841 Forward-Port-Of: odoo/odoo#266632 Forward-Port-Of: odoo/odoo#266394
This update fixes a potential issue where duplicate Addenda nodes were being created in CFDI invoices. This ensured compliance with Mexican tax regulations (SAT) and the CFDI 4.0 standard, preventing invoice rejection by recipient systems. The fix maintains a clean, valid XML structure even with multiple processing attempts.
Original PR description
Before this commit, if the `_l10n_mx_edi_cfdi_invoice_append_addendas` method was executed more than once on the same invoice, the resulting CFDI would contain multiple `<cfdi:Addenda>` nodes. This…
Before this commit, if the `_l10n_mx_edi_cfdi_invoice_append_addendas` method was executed more than once on the same invoice, the resulting CFDI would contain multiple `<cfdi:Addenda>` nodes.
This occurred because the method manually injects the new Addenda string at the end of the XML without checking if one was already present from a previous execution.
According to the SAT's Anexo 20 and the CFDI 4.0 XSD, the Addenda must be a single node and the last element of the Comprobante. Duplicating root-level nodes like `cfdi:Addenda` is a bad XML formation practice that can cause rejection by the recipient's automated systems.
This fix ensures the CFDI structure remains valid by:
1. Searching for an existing `{*}Addenda` node in the CFDI string.
2. Removing the old node before reconstructing the XML.
3. Preventing the string replacement logic from stacking multiple Addenda blocks.
This ensures that the CFDI remains clean and compliant with the official standard even if the process is triggered multiple times.
Forward-Port-Of: odoo/enterprise#109760This update resolves a performance issue in the HTML Builder where the shape selector panel was causing significant delays and UI freezes. By delaying the loading of panel content until it's needed, we've dramatically reduced the number of requests and improved the overall responsiveness of the builder. This ensures a smoother and faster experience for users.
Original PR description
The shape selector panel was eagerly compiling and rendering its slot content on builder startup, triggering 200+ concurrent SVG thumbnail requests before the user had opened the panel or selected an image. With browsers limiting parallel connections per domain, this flooded the request queue and caused the main UI to freeze for several seconds. Slot content is now deferred behind a `contentRendered` flag that is set the first time the panel is opened, so no compilation or network activity happens until the user actually needs it. task-5973702
This update resolves an issue where custom text attributes on products weren't correctly displayed when settling website orders through the POS system. Previously, the POS would show a placeholder instead of the customer's entered text. The fix ensures that custom attribute data is accurately transferred and displayed in the POS order lines.
Original PR description
When a sale order containing a product with a custom (free text) attribute was settled in POS, the order line displayed the placeholder attribute value name (e.g. "Custom") instead of the actual text…
When a sale order containing a product with a custom (free text) attribute was settled in POS, the order line displayed the placeholder attribute value name (e.g. "Custom") instead of the actual text entered by the customer. Steps to reproduce: ------------------- * Create a product with a free text attribute (create_variant='no_variant', is_custom=True) * Go to the website's shop (works best in a new private tab) * Fill the free text attribute and add the product to the cart * Click on checkout * In POS, open Quotation/Order and settle the order > Observation: the order line shows "Custom" instead of the text Why the fix: ------------ `SaleOrderLine._load_pos_data_fields` was not exposing `product_no_variant_attribute_value_ids` nor `product_custom_attribute_value_ids`, so the JS `settleSO` function received no attribute data on the `line` object. As a result, the new POS order line was created with empty `attribute_value_ids` and `custom_attribute_value_ids`, leaving `constructFullProductName` unable to find the custom text. The fix adds both fields to `_load_pos_data_fields` and updates `settleSO` to use them when building the new POS order line. The dynamic fetch path (`_getSaleOrder`) is also updated to explicitly read the `product.attribute.custom.value` records so the data is available for orders loaded at runtime. opw-5958678 Forward-Port-Of: odoo/odoo#265491 Forward-Port-Of: odoo/odoo#251993
This update fixes a crash that occurred when purchase matching attempted to convert vendor bills with only a description and UoM, without a linked product. The change ensures purchase matching is robust when importing bills based on description, maintaining consistency with existing UoM conversion rules. This improves the reliability of importing purchase invoices.
Original PR description
### Issue before this commit: Opening the Purchase Matching wizard would crash if the vendor bill contained lines with a description and a Unit of Measure (UoM), but no product selected. ### Steps to…
### Issue before this commit: Opening the Purchase Matching wizard would crash if the vendor bill contained lines with a description and a Unit of Measure (UoM), but no product selected. ### Steps to reproduce the issue: 1. Enable Units of Measure in Settings 2. Create and confirm a Vendor Bill setting a description and a UoM, but leave the Product field empty. 3. Click on "Purchase matching" smart button 4. The system throws a traceback with the error: "The unit of measure Unit defined on the order line doesn't belong to the same category as the unit of measure False defined on the product." ### Cause of the issue: In the purchase.bill.line.match model, the field product_uom_qty was computed by calling _compute_quantity using line.product_uom_id. Since product_uom_id is a related field on product_id.uom_id, it returns False when no product is set. The UoM conversion logic cannot handle a False destination category, leading to the crash. ### Reason to introduce the fix: Make purchase matching robust when imported vendor bills contain lines identified only by their description and not by a product. Note that for `purchase.bill.line.match` corresponding to an account.move.line but not related to any product, the `product_uom_qty` should match the quantity of the `aml_id` instead of attempting a UoM conversion based on a missing product UoM for the behavior to be consistent with the inverse method: https://github.com/odoo/odoo/blob/59d6232979b8499fde6cb700df1870e2e38d0d3e/addons/purchase/models/purchase_bill_line_match.py#L45-L54 opw-5911526 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#266269 Forward-Port-Of: odoo/odoo#257827
This update resolves an issue preventing Belgian employees on flexible work schedules from requesting multi-day leave. The fix ensures that the system correctly handles flexible schedules by skipping attendance checks, which was previously causing errors. This enhancement ensures accurate leave calculations and functionality for our Belgian clients.
Original PR description
## Steps to reproduce: - Install l10n_be_hr_payroll module - Create a flexible working schedule and set the company to the Belgian company - Create an employee and assign the created schedule to him - Try to take a multi-day leave for this employee - Notice number of days is 0 - Try to validate the leave - An exception is raised 'The following employees are not supposed to work during that period' ## Cause: When fetching the work intervals for a belgian flexible employee we first fetch the normal work intervals then we call the same method but to filter the time credit attendance and since for the flexible employee there are not specific attendances we return the same normal work intervals and it will subtract those from the main work intervals which will result in an empty intervals to be returned ## Fix: Check if the working schedule is flexible and if so we don't check the time credit attendances at all. opw-6237642 Forward-Port-Of: odoo/enterprise#118528
This update optimizes the account report sheet by streamlining CSS styling to reduce performance bottlenecks. By using CSS variables and direct selectors, the system avoids unnecessary DOM traversal, resulting in smoother and faster loading times, especially for large reports. This improves the user experience and reduces potential lag.
Original PR description
Forward-Port-Of: odoo/enterprise#118490
This update fixes an issue where expected working hours displayed in the Attendances Gantt view were inaccurate for employees with flexible schedules, particularly when viewed through browsers using local timezones. The change ensures accurate hour calculations based on the user's timezone, improving the reliability of attendance tracking.
Original PR description
Steps to reproduce: 1. Ensure your browser is in a non-UTC timezone (e.g. Europe/Zurich) 2. Set an employee to have a flexible working schedule 3. Enter the Attendances app 4. When hovering over the employee in the gantt view, the expected hours do not match their working schedule When we calculate the expected hours for the Gantt view in attendances, we calculate this based on an incorrect number of attendance intervals given from _attendance_intervals_batch(). To ensure that we recieve accurate intervals, we need to ensure that we calculate intervals based on the correct date range with respect to the browsers timezone, instead of the UTC date range. [opw-6175441](https://www.odoo.com/odoo/my-tasks/6175441?debug=assets) Forward-Port-Of: odoo/enterprise#116807
2 changes
Resolved issues and error corrections
This update resolves an issue where partner names with '&' characters were incorrectly formatted during SEPA export, leading to bank rejections. The fix ensures '&' is preserved in human-readable fields like partner names and addresses, aligning with banking standards and preventing export failures.
Original PR description
Problem: The previous fix (replacing '&' with '+' in _replace_characters_SEPA) was applied globally, affecting both reference/identifier fields and human-readable fields such as <Nm> (partner name)…
Problem:
The previous fix (replacing '&' with '+' in _replace_characters_SEPA) was applied globally, affecting both reference/identifier fields and human-readable fields such as <Nm> (partner name) and address lines.
As a result, a partner named "test & test GMBH" was exported as:
<Nm>test + test GMBH</Nm>
instead of the expected:
<Nm>test & test GMBH</Nm>
This caused bank file rejections because '&' is the correct XML encoding of '&' and is accepted by banks in human-readable fields.
Root cause:
ISO 20022 / EPC217-08 distinguishes two categories of data elements:
- Reference/identifier fields (InstrId, Ustrd, etc.): must use the restricted basic Latin character set — '&' is not allowed and must be replaced with '+'.
- Human-readable fields (Nm, AdrLine, etc.): may contain the extended Latin character set — '&' is valid and must be preserved so lxml can XML-escape it to '&' in the output.
Fix:
Revert the global '&' → '+' replacement in _replace_characters_SEPA so that '&' is preserved for name/address fields. The replacement of '&' with '+' for reference/identifier fields is already handled explicitly at the call sites in _get_CdtTrfTxInf (InstrId, Ustrd) via .replace('&', '+') before sanitize_communication is called.
ref commit : https://github.com/odoo/enterprise/pull/110809/changes/9e698e4ac9fdf66189ff6712f90a144560a1b484
documentation https://www.europeanpaymentscouncil.eu/sites/default/files/KB/files/EPC217-08%20Draft%20Best%20Practices%20SEPA%20Requirements%20for%20Character%20Set%20v1.1.pdf:
Forward-Port-Of: odoo/enterprise#118511
Forward-Port-Of: odoo/enterprise#115409This update fixes an issue where expected working hours displayed in the Attendances Gantt view were inaccurate for employees using non-UTC time zones. The fix ensures that hour calculations now correctly account for the user's local time, providing more reliable attendance reporting. This improves the accuracy of time tracking for flexible schedules.
Original PR description
Steps to reproduce: 1. Ensure your browser is in a non-UTC timezone (e.g. Europe/Zurich) 2. Set an employee to have a flexible working schedule 3. Enter the Attendances app 4. When hovering over the employee in the gantt view, the expected hours do not match their working schedule When we calculate the expected hours for the Gantt view in attendances, we calculate this based on an incorrect number of attendance intervals given from _attendance_intervals_batch(). To ensure that we recieve accurate intervals, we need to ensure that we calculate intervals based on the correct date range with respect to the browsers timezone, instead of the UTC date range. [opw-6175441](https://www.odoo.com/odoo/my-tasks/6175441?debug=assets) Forward-Port-Of: odoo/enterprise#116807
7 changes
Resolved issues and error corrections
This update resolves an issue where partner names with '&' characters were incorrectly formatted during SEPA export, leading to bank rejections. The fix ensures '&' is preserved in human-readable fields like partner names and addresses, aligning with banking standards and preventing export failures.
Original PR description
Problem: The previous fix (replacing '&' with '+' in _replace_characters_SEPA) was applied globally, affecting both reference/identifier fields and human-readable fields such as <Nm> (partner name)…
Problem:
The previous fix (replacing '&' with '+' in _replace_characters_SEPA) was applied globally, affecting both reference/identifier fields and human-readable fields such as <Nm> (partner name) and address lines.
As a result, a partner named "test & test GMBH" was exported as:
<Nm>test + test GMBH</Nm>
instead of the expected:
<Nm>test & test GMBH</Nm>
This caused bank file rejections because '&' is the correct XML encoding of '&' and is accepted by banks in human-readable fields.
Root cause:
ISO 20022 / EPC217-08 distinguishes two categories of data elements:
- Reference/identifier fields (InstrId, Ustrd, etc.): must use the restricted basic Latin character set — '&' is not allowed and must be replaced with '+'.
- Human-readable fields (Nm, AdrLine, etc.): may contain the extended Latin character set — '&' is valid and must be preserved so lxml can XML-escape it to '&' in the output.
Fix:
Revert the global '&' → '+' replacement in _replace_characters_SEPA so that '&' is preserved for name/address fields. The replacement of '&' with '+' for reference/identifier fields is already handled explicitly at the call sites in _get_CdtTrfTxInf (InstrId, Ustrd) via .replace('&', '+') before sanitize_communication is called.
ref commit : https://github.com/odoo/enterprise/pull/110809/changes/9e698e4ac9fdf66189ff6712f90a144560a1b484
documentation https://www.europeanpaymentscouncil.eu/sites/default/files/KB/files/EPC217-08%20Draft%20Best%20Practices%20SEPA%20Requirements%20for%20Character%20Set%20v1.1.pdf:
Forward-Port-Of: odoo/enterprise#118511
Forward-Port-Of: odoo/enterprise#115409This update resolves a previous issue where transaction details weren't consistently saved for Viva Wallet payments, regardless of whether they were processed via webhook or polling. The fix ensures that all relevant payment information, including card details, is now accurately recorded, improving the reliability of our point-of-sale reporting.
Original PR description
After odoo/odoo#236454, a bug was introduced where the transaction details would only be saved if the payment was resolved via webhook, not via polling. This commit fixes the issue by using the same field names in the webhook payload as is received from the polling endpoint. In addition, the card number and card brand fields are now saved too. opw-6244960 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#266629
This update fixes an issue where the expected hours displayed in the Attendances Gantt view didn't accurately reflect flexible work schedules, particularly when users' browsers were set to non-UTC timezones. The change ensures accurate hour calculations based on the user's local timezone, improving the reliability of attendance tracking.
Original PR description
Steps to reproduce: 1. Ensure your browser is in a non-UTC timezone (e.g. Europe/Zurich) 2. Set an employee to have a flexible working schedule 3. Enter the Attendances app 4. When hovering over the employee in the gantt view, the expected hours do not match their working schedule When we calculate the expected hours for the Gantt view in attendances, we calculate this based on an incorrect number of attendance intervals given from _attendance_intervals_batch(). To ensure that we recieve accurate intervals, we need to ensure that we calculate intervals based on the correct date range with respect to the browsers timezone, instead of the UTC date range. [opw-6175441](https://www.odoo.com/odoo/my-tasks/6175441?debug=assets) Forward-Port-Of: odoo/enterprise#116807
This update resolves a technical issue preventing Viva payments in the POS kiosk. The Viva payment system requires a unique identifier for the cash register, which was previously missing. This fix ensures the correct 'cashRegisterId' is sent, allowing Viva payments to process successfully and avoiding errors.
Original PR description
When validating a payment in POS Kiosk with Viva payment method we get a Viva.com error Viva’s card-terminal API validates the JSON body with Pydantic and requires a non-empty ``cashRegisterId``. Steps to reproduce: ------------------- * Open POS in kiosk * Make an order and pay with Viva > Observation: Viva returns a validation error: ``cashRegisterId`` is missing or required in the request body (Pydantic ``missing`` on ``body.cashRegisterId``). Why the fix: ------------ Compute ``cashRegisterId`` in the POS client as cashier name, then ``pos.config.name`` so the value is always a non-empty string sent to ``viva_wallet_send_payment_request``. opw-6091223 Forward-Port-Of: odoo/odoo#265817 Forward-Port-Of: odoo/odoo#258605
This update fixes an issue where the import process wasn't correctly reading invoice due dates from FatturaPA invoices. Now, the system accurately captures the due date for issued invoices, ensuring proper payment tracking. This resolves a previous error that defaulted due dates to today's date.
Original PR description
The import procedure stopped reading DataScadenzaPagamento (invoice date due) on `out_invoice`s and `in_refund`. As a side effect, invoice_date_due fell back to today() on those documents. This commit restores reading the invoice date due, and keeps the condiitonal logic only for the bank account and payment_reference logic incoming-only as it was before. Forward-Port-Of: odoo/odoo#264762 Forward-Port-Of: odoo/odoo#264573
This update ensures that the project associated with a sales order is automatically included in the generated Manufacturing Order, even with multi-step delivery routes (Pick + Deliver). Previously, this wasn't happening, causing issues with tracking projects in complex order flows. This change improves order management and reporting accuracy.
Original PR description
### Issue before this commit: When confirming a Sale Order with multi-step delivery routes (Pick + Deliver), the generated Manufacturing Order did not inherit the project_id from the Sale Order, even…
### Issue before this commit: When confirming a Sale Order with multi-step delivery routes (Pick + Deliver), the generated Manufacturing Order did not inherit the project_id from the Sale Order, even though the project was correctly set on the SO. ### Steps to reproduce the issue: 1. Download Inventory, Sales, PLM, Project 2. Enable multi-step routes in settings and unarchive MTO from routes 3. Go to Products and modify 1. Furniture Assembly inserting Project in "Create on Order" attribute and a test project template 2. Drawer selecting MTO and Manifacture in Inventory tab 4. Create a new quotation inserting 2 products: Furniture Assembly and Drawer and confirm it 5. Go to "Manufacturing" smart button 6. See in Miscellaneous tab the Project is setted as default 7. Go to warehouses, select the WH of your company and select Pick then Deliver (2 steps) as Outgoing Shipments 8. Go to Routes, select Deliver in two steps (pick + ship) and change "Destination location" of "Pull From" from Parteners/Customers into WH/output 9. Go to Rules: 1. "Pull From" (the one with Partener/Customers as destination location and MTO as route): change "Destination location" of from Parteners/Customers into WH/output 2. "Push To" (the one with Partener/Customers as destination location and with the deliver in 2 steps as route): change action from "Push To" to "Pull from" 10. Create a new quotation inserting 2 products: Furniture Assembly and Drawer and confirm it 5. Go to "Manufacturing" smart button 6. See in Miscellaneous tab the Project is not setted ### Cause of the issue: https://github.com/odoo/odoo/blob/d1955028bb95eff8d33c1c2b1c211d8520bb33a2/addons/sale_project_stock/models/stock_move.py#L71-L76 This function retrieves the project only based on the sale_line_id, which is correctly populated in a one-step delivery because the procurement is directly linked to the Sales Order (SO). However, the sale_line_id is not propagated to procurements that are not directly linked to the SO. In this scenario, with a two-step delivery, there are two stock moves: from Stock to WH/Output, and from WH/Output to the Customer. Only the second move (WH/Output > Customer) is linked to the SO, while this information is not propagated to the first move. As a result, the project_id information is lost. ### Reason to introduce the fix: Be sure that the project is automatically setted in the MO when a SO is confirmed whatever the intial delivery configuration is. opw-5913988 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#266808 Forward-Port-Of: odoo/odoo#261565
This update fixes an issue where the calculation of the gross total on invoices with both line and global discounts was incorrect. The change ensures that discounts are applied in the correct order, resulting in accurate gross total calculations for invoices, particularly when global discounts are involved. This improves the reliability of invoice totals.
Original PR description
Problem: When both line discounts and global discounts are applied on a product in an invoice, the method `_add_and_round_raw_gross_total_excluded_and_discount` does not return the exact…
Problem: When both line discounts and global discounts are applied on a product in an invoice, the method `_add_and_round_raw_gross_total_excluded_and_discount` does not return the exact raw_gross_total_excluded before the modification done by other AccountTax helper methods, such as dispatching and squashing global discount lines. Current Behavior: The calculation is done in the wrong order of operations. For example, there is an invoice for Product A valued at $100 with a discount of 10% and a global discount of $10. The raw_total_excluded will be $80 after the both discounts. The discount_factor is based on only the line discount of 10%. The formula of the current calculation for raw_gross_total_excluded is: (raw_total_excluded / (1 - (line_discount / 100))) - global_discount = (80 / 0.90) - (-10) = 98.889 This does not equal the expected outcome of $100. Expected Behavior: Based on the previous example, the formula for the calculation should be: (raw_total_excluded - global_discount) / (1 - (line_discount/100)) = (80 - (-10)) / 0.9 = 100 The global discount needs to be added back to the raw_total_excluded to get the line discounted amount in order to divide by the discount_factor to gain the expected raw_gross_total_excluded before taxes and discounts. Steps to reproduce the issue: - Bug was encountered when implementing a global discount solution for l10n_co_dian. - Create an invoice with a product line and in-line discount and another line for global discount - Setup the base lines for the invoice and attempt the following: - _dispatch_global_discount_lines - _squash_global_discount_lines - _add_and_round_raw_gross_total_excluded_and_discount opw-5412446 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#262137
3 changes
New functionality added to Odoo
This update expands the information sent to Pricer, including price before taxes, tax details, supplier product codes, and units of measure. These additions enable more accurate pricing calculations and address previously missing data required for key use cases. The update also improves code organization and ensures Pricer tags are automatically updated when related product information changes.
Original PR description
We are currently missing some fields which must be sent to Pricer for some basic use-case scenarios This PR adds - Price before taxes - Taxes name (ex: 21%) - Supplier product code - Supplier reference - Units of measure of the product The PR also triggers the update of the pricer tags when the models indirectly related to Pricer are modified (taxes name / supplier reference / supplier product code) + cleans up the code a bit task-4506260 Forward-Port-Of: odoo/enterprise#78009
Resolved issues and error corrections
This update fixes an issue where expected work hours displayed in the Attendances Gantt view were inaccurate for employees with flexible schedules, particularly when viewed through browsers using non-UTC time zones. The change ensures accurate hour calculations based on the user's local time, improving the reliability of attendance reporting.
Original PR description
Steps to reproduce: 1. Ensure your browser is in a non-UTC timezone (e.g. Europe/Zurich) 2. Set an employee to have a flexible working schedule 3. Enter the Attendances app 4. When hovering over the employee in the gantt view, the expected hours do not match their working schedule When we calculate the expected hours for the Gantt view in attendances, we calculate this based on an incorrect number of attendance intervals given from _attendance_intervals_batch(). To ensure that we recieve accurate intervals, we need to ensure that we calculate intervals based on the correct date range with respect to the browsers timezone, instead of the UTC date range. [opw-6175441](https://www.odoo.com/odoo/my-tasks/6175441?debug=assets) Forward-Port-Of: odoo/enterprise#116807
This update fixes an issue where intercompany sales and purchases with multiple identical products resulted in incorrect stock reservation during receipt picking. Specifically, the system was failing to properly reserve all units of a product when creating intercompany transactions with multiple lines. This ensures accurate stock tracking and fulfillment for intercompany business operations.
Original PR description
…lit for same-product lines When doing an intercompany Sale->Purchase with multiple lines having the same products, the receipt picking would be incorrectly assigned: - Enable Inter-Company…
…lit for same-product lines
When doing an intercompany Sale->Purchase with multiple lines having the same products, the receipt picking would be incorrectly assigned:
- Enable Inter-Company Transactions on both companies (Create and validate)
- Create SO in company A to company B with 2 lines having the same product P, Confirm. => Delivery in company A, Purchase and Receipts in company will be created => The SO/PO/Delivery/Receipt will all have 2 lines
- Validate delivery => On the receipt, the 2 units of P are reserved on the 1st move, and the 2nd move is not reserved.
https://github.com/user-attachments/assets/b4816051-120e-4226-9228-fd552649d5ef
---
### Test result without fix:
```
2026-04-23 13:16:44,577 48027 INFO oes_test_18.0 odoo.addons.sale_purchase_stock_inter_company_rules.tests.test_inter_company_so_to_po: Starting TestInterCompanySaleToPurchaseWithStock.test_02_inter_company_multiple_lines_with_same_product ...
2026-04-23 13:16:44,949 48027 INFO oes_test_18.0 odoo.addons.sale_purchase_stock_inter_company_rules.tests.test_inter_company_so_to_po: ======================================================================
2026-04-23 13:16:44,949 48027 ERROR oes_test_18.0 odoo.addons.sale_purchase_stock_inter_company_rules.tests.test_inter_company_so_to_po: FAIL: TestInterCompanySaleToPurchaseWithStock.test_02_inter_company_multiple_lines_with_same_product
Traceback (most recent call last):
File "/home/odoo/Odoo/src/18.0/enterprise/sale_purchase_stock_inter_company_rules/tests/test_inter_company_so_to_po.py", line 109, in test_02_inter_company_multiple_lines_with_same_product
self.assertRecordValues(purchase_from_a.picking_ids.move_ids, [
File "/home/odoo/Odoo/src/18.0/odoo/odoo/tests/common.py", line 709, in assertRecordValues
self.assertSequenceEqual(expected_reformatted, record_reformatted, seq_type=list)
AssertionError: Lists differ: [{'pr[18 chars]0, 'quantity': 1.0}, {'product_uom_qty': 1.0, 'quantity': 1.0}] != [{'pr[18 chars]0, 'quantity': 2.0}, {'product_uom_qty': 1.0, 'quantity': 0.0}]
First differing element 0:
{'product_uom_qty': 1.0, 'quantity': 1.0}
{'product_uom_qty': 1.0, 'quantity': 2.0}
- [{'product_uom_qty': 1.0, 'quantity': 1.0},
? ^
+ [{'product_uom_qty': 1.0, 'quantity': 2.0},
? ^
- {'product_uom_qty': 1.0, 'quantity': 1.0}]
? ^
+ {'product_uom_qty': 1.0, 'quantity': 0.0}]
? ^
```
OPW-6145683
Forward-Port-Of: odoo/enterprise#1148733 changes
Enhancements to existing features
This update enhances the quality control process within purchase orders by clearly identifying product variants when checking items, resolving a previous ambiguity. Additionally, the quality point search functionality now uses the title instead of the internal reference, providing a more intuitive and user-friendly experience.
Original PR description
1) Product Attributes in QC Wizard The quality check wizard within purchase orders does not display sufficient information when dealing with product variants. For example, if a company purchases tables in two colors -white and black- and needs to perform a quality check upon receipt, the wizard currently does not indicate which variant is being checked, as both products share the same name. This commit resolves this ambiguity by displaying the product's 'display_name' insted of just its name. 2) Quality Points: Search By Title Previously, when searching for a QP by title in the search view, the system relied on the 'reference' column internally. For improved clarity, this has been changed to a title filter. task: 4277084
This update streamlines Australian payroll by consolidating penalty rates into a single, global rate field. This eliminates confusion and ensures consistent overtime calculations in payslips. The change also simplifies the system by removing redundant fields and updating calculations for various work entry types.
Original PR description
Purpose: - The new global Rate field now provides a unified way to define pay rates for work entry types across all countries, making the AU-specific Penalty Rate redundant. - Remove duplicate rate…
Purpose:
- The new global Rate field now provides a unified way to define pay rates for work entry types across all countries, making the AU-specific Penalty Rate redundant.
- Remove duplicate rate definitions in AU payroll by merging Penalty Rate into the global Rate field, avoiding user confusion and ensuring consistent overtime computation in payslips.
- Ensure AU logic fully relies on the global Rate while preserving existing behavior for STP Code, casual loading, and leave loading.
This PR includes:
- Removed Penalty Rate field from model and views.
- Updated computation logic to rely on global Rate while preserving AU-specific behavior based on STP Code.
- Preserved STP-based logic and loading behaviors.
- Hidden the 'Add on Monthly Wage' checkbox for AU because its behavior is
already fully handled via STP code logic, making the field redundant/confusing.
- Added upgrade script to migrate existing Penalty Rate values into Rate to maintain backward compatibility.
- Converted Penalty Rate into Rate format during upgrade: Penalty Rate stores only the extra percentage (e.g., +50%), while Rate represents the full multiplier (100% base(Default) + extra), so where penalty rate is 50%, it becomes 150% (1.5) in Rate.
-------------------------------------------------------------------------------------------------------------------------------------------------------------
Note: Brief overview of AU payslip computation behavior.
Example: hourly wage = 10, Rate = 1.5, leave loading = 17.5%, casual loading = 0.25
1) For normal work entries, the global Rate value is combined with the employee
casual loading. In AU payroll, casual loading is additive and must be added
directly on top of the Rate multiplier instead of being multiplied separately.
- Example:
final calculation = 1.5 + 0.25 = 1.75
amount = 10 * hours * 1.75
2) For AU paid time off entries (AU.PT), the leave loading percentage must be applied
separately and the computation must stop after applying leave loading, meaning
casual loading must not be added on top of it.
- Example:
final calculation = 1.175
amount = 10 * hours * 1.175
3) For overtime work entries using STP code 'T', casual loading must also be
ignored. These entries should only use the Rate multiplier configured on the
work entry type.
- Example:
final calculation = 1.5
amount = 10 * hours * 1.5
- Related Upgrade PR: https://github.com/odoo/upgrade/pull/9557
task-5406660Resolved issues and error corrections
This update fixes an issue where users could order unlimited quantities of rental products through the website. The change ensures the system limits product availability based on rental schedules, preventing over-ordering and ensuring accurate resource allocation. This improves the reliability of rental orders.
Original PR description
It is possible to order as many products as we want of a rental product that synchronizes shifts depending on a specific service Steps to reproduce: 1. Install website_sale_renting_planning module 2.…
It is possible to order as many products as we want of a rental product that synchronizes shifts depending on a specific service Steps to reproduce: 1. Install website_sale_renting_planning module 2. Go to Rental > Products and create a new product "test" with Sales enabled, Product Type "Service", Plan Services enabled as "Developer", in the Sales tab, enable Is Published and in the Rental prices tab, create a pricing for Daily period 3. In the General Information tab, click on the internal link to "Developer" 4. Enable Sync Shifts and Rental Orders 5. Go to the eCommerce website and search for product "test" 6. You can add as many quantity of the product to your cart Issue: We don't limit the maximum quantity of the product Solution: Look through the renting availabilities of the product and set the maximum quantity to the minimum of the availabilities relevant to the renting dates selected opw-6009928 Forward-Port-Of: odoo/enterprise#118332 Forward-Port-Of: odoo/enterprise#111793
3 changes
Resolved issues and error corrections
This update improves the performance of account report sheets by streamlining CSS styling and reducing unnecessary DOM calculations. By utilizing CSS variables and simplified selectors, the changes minimize visual rendering impacts, particularly on large tables, resulting in smoother user experiences.
This update resolves an issue preventing Belgian employees on flexible work schedules from taking multi-day leave. The fix ensures that the system correctly handles flexible schedules, eliminating an error that previously prevented leave validation. This improves the functionality for employees utilizing flexible working arrangements.
Original PR description
## Steps to reproduce: - Install l10n_be_hr_payroll module - Create a flexible working schedule and set the company to the Belgian company - Create an employee and assign the created schedule to him - Try to take a multi-day leave for this employee - Notice number of days is 0 - Try to validate the leave - An exception is raised 'The following employees are not supposed to work during that period' ## Cause: When fetching the work intervals for a belgian flexible employee we first fetch the normal work intervals then we call the same method but to filter the time credit attendance and since for the flexible employee there are not specific attendances we return the same normal work intervals and it will subtract those from the main work intervals which will result in an empty intervals to be returned ## Fix: Check if the working schedule is flexible and if so we don't check the time credit attendances at all. opw-6237642
This update fixes an issue where expected working hours displayed in the Attendances Gantt view were inaccurate for employees with flexible schedules, particularly when browsers were set to non-UTC timezones. The change ensures accurate hour calculations based on the user's local timezone, leading to more reliable attendance reporting.
Original PR description
Steps to reproduce: 1. Ensure your browser is in a non-UTC timezone (e.g. Europe/Zurich) 2. Set an employee to have a flexible working schedule 3. Enter the Attendances app 4. When hovering over the employee in the gantt view, the expected hours do not match their working schedule When we calculate the expected hours for the Gantt view in attendances, we calculate this based on an incorrect number of attendance intervals given from _attendance_intervals_batch(). To ensure that we recieve accurate intervals, we need to ensure that we calculate intervals based on the correct date range with respect to the browsers timezone, instead of the UTC date range. [opw-6175441](https://www.odoo.com/odoo/my-tasks/6175441?debug=assets) Forward-Port-Of: odoo/enterprise#116807
9 changes
Enhancements to existing features
This update enables Odoo to fully receive Peppol invoices, including optional fields created in Studio. Previously, Odoo only supported sending these extra fields, preventing users from receiving fully compliant invoices. This enhancement ensures invoices meet industry standards and improves data accuracy.
Original PR description
Currently, Odoo allows sending invoices with additional Peppol fields, but didn't support the receiving. This limitation prevents users from receiving fully compliant invoices. After this commit, users will be able to receive these extra fields if they already created them using Studio. task-6033667 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update enhances the Point of Sale experience by ensuring that when a product is scanned with a barcode, the product configuration automatically preselects the variant details (like color) that match the scan. This mirrors the behavior of searching for a product by barcode, creating a more consistent and user-friendly experience for sales staff.
Original PR description
When a barcode scan matches a specific product variant, the product configurator now behaves the same as when the user searches by barcode: - The `always`-mode attribute (e.g. Color) is preselected from the matched variant instead of being hidden or left blank. - The `no_variant`-mode attributes (e.g. Size) are shown for user input. opw-6220883 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Resolved issues and error corrections
This update resolves an issue where installing point-of-sale demo data with localization modules (like India) caused a UserError due to a missing bank journal. The fix ensures the journal is created earlier in the loading process, preventing the error and allowing demo data to install correctly.
Original PR description
## Problem When creating a database with a country selected (e.g. India, or any country with a localization module), installing point_of_sale with demo data enabled raises a UserError about a missing…
## Problem
When creating a database with a country selected (e.g. India, or any
country with a localization module), installing point_of_sale with demo
data enabled raises a UserError about a missing bank journal, causing
the entire demo data installation to fail with this warning:
Module point_of_sale demo data failed to install, installed without demo data
The issue does NOT occur when no country is selected during database
creation, because Odoo falls back to generic_coa which sets up all
journals before POS demo data loads.
## Root Cause
Module loading follows this sequence:
data -> demo -> state='installed' -> commit
When a localization module (e.g. l10n_in) reaches the installed state,
the IrModule.write override detects the missing chart template on the
main company and stores try_loading on registry._auto_install_template.
However, this deferred loading is only executed in _register_hook, which
runs after ALL modules have finished loading.
When point_of_sale loads after l10n_in but before _register_hook fires,
its demo data calls load_onboarding_furniture_scenario() which calls
_create_journal_and_payment_methods(). At this point the bank journal
from the localization has not been created yet, causing the crash.
Debug proof:
With India selected at DB creation:
Chart Template: False
Journals available: Cash Furn. Shop (cash), Point of Sale (general)
Bank journal found: False <- causes UserError
With no country selected:
Chart Template: generic_coa
Journals available: Bank (bank), Cash (cash), Customer Invoices (sale), ...
Bank journal found: True <- works fine
## Fix
Add a cr.precommit call in IrModule.write to execute
_auto_install_template. This ensures the chart template and its journals
get loaded at the end of the localization module's loading cycle (at its
commit), making the bank journal available for subsequent modules like
point_of_sale during their loading phase.
The _register_hook fallback is kept as a safety measure and now simply
acts as a no-op if the precommit already handled the installation.
## Steps to Reproduce
1. Create a new database from /web/database/manager
2. Enable Load Demo Data
3. Select any country (e.g. India)
4. Login and install point_of_sale
5. Observe warning: Module point_of_sale demo data failed to install
## Expected Result
point_of_sale demo data installs successfully regardless of which
country/localization is selected at database creation.This update fixes an issue where group holiday accruals were incorrectly showing as zero when the allocation start date was in the past. The change ensures that accrual calculations are properly computed and applied, resolving a discrepancy in holiday allocation amounts. This improves the accuracy of holiday tracking for employees.
Original PR description
Problem ------------------ When creating group allocations, when the allocation type is accrual and the start date is set in the past, the newly created allocations have the accrual amounts at 0. To…
Problem ------------------ When creating group allocations, when the allocation type is accrual and the start date is set in the past, the newly created allocations have the accrual amounts at 0. To reproduce: 1. Create an accrual plan with an easily measurable milestone (e.g. 1 day every day) 2. From the allocations view -> New Group Allocation 3. Enter the following values: Grant -> By Employee Employees -> select your employee Time Off Type -> Paid Time Off (doesn't matter too much) Allocation Type -> Based on Accrual Plan Validity Period -> any date a few days in the past (Personally I tested with 1/1/2025 and no end date) Allocation -> Keep at 0 Allocate Time Off 4. Go to the newly created allocation The allocation amount is 0. Reason ---------------------- When creating group allocations, the `hr.leave.allocation.generate.multi.wizard` calls the `_process_accrual_plans()` method to compute the accruals, but when the allocations are created, the nextcall and lastcall fields are set, so the accruals are not computed and the scheduled action also does nothing until the nextcall date. The onchange method manually sets the nextcall date to False so the accruals are processed. Solution ------------------ Created a method to get the fields that need to be set to calculate the initial accrual amounts from the start date, which is called both in the onchange and to batch write in the wizard before accrual plans are processed. The wizard checks the duration values before overwriting the number_of_days field, since user manually setting the amount should overwrite the calculations. task-4938695 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves a validation error that occurred during production recording when a subcontractor deleted and recreated a move line. The original code incorrectly invalidated the cache, leading to missing product UOM information. The fix maintains the existing logic while avoiding cache invalidation, ensuring accurate production recording.
Original PR description
**Issue** In subcontracting, deleting a raw move line and adding a new one in the same editing flow can lead to a validation error during production recording. **Steps to reproduce** - Create a…
**Issue** In subcontracting, deleting a raw move line and adding a new one in the same editing flow can lead to a validation error during production recording. **Steps to reproduce** - Create a subcontracting product with a comp A - Create and confirm a purchase order of that product (with the subcontracting partner) - Open the associated delivery - Open the move details (hamburger button) - Delete the move line linked to the comp A - Create a new move line for a comp B with a quantity of 1 - Record the production -> A validation error occurs: the mandatory field `product_uom_id` is not set. **Cause** The regression comes from this commit: https://github.com/odoo/odoo/commit/54f10b56f577ad9ed5575bd396dba7d20d22fc2e While assigning `move_raw_ids`, the inverse method is triggered: https://github.com/odoo/odoo/blob/9267b2d1a9b2d2d6a33eceab07d572406c68c723/addons/mrp_subcontracting/models/mrp_production.py#L34 At this stage, newly added lines are still virtual records (`line`): https://github.com/odoo/odoo/blob/9267b2d1a9b2d2d6a33eceab07d572406c68c723/addons/mrp_subcontracting/models/mrp_production.py#L38 The previous implementation directly unlinked removed move lines (see commit https://github.com/odoo/odoo/commit/54f10b56f577ad9ed5575bd396dba7d20d22fc2e): https://github.com/odoo/odoo/blob/9267b2d1a9b2d2d6a33eceab07d572406c68c723/addons/mrp_subcontracting/models/mrp_production.py#L40-L43 Which will eventually flush and invalidate all the cache: https://github.com/odoo/odoo/blob/0e78b4fd2ab904f2e12107cb6ff7cc11d512259f/odoo/models.py#L4666 And since `line` is a virtual record (not in db), its associated values will be reset, among those, `product_uom_id`. Later, when the move line is reassigned: https://github.com/odoo/odoo/blob/0e78b4fd2ab904f2e12107cb6ff7cc11d512259f/addons/mrp_subcontracting/models/mrp_production.py#L49 https://github.com/odoo/odoo/blob/0e78b4fd2ab904f2e12107cb6ff7cc11d512259f/odoo/models.py#L5223-L5228 the validation fails because the virtual line no longer contains the required values. **Additional note** An alternative could have been using Command but since this line: https://github.com/odoo/odoo/blob/0e78b4fd2ab904f2e12107cb6ff7cc11d512259f/addons/mrp_subcontracting/models/mrp_production.py#L42 can not be converted to: `Command.set([line.id for line in lines])` because `lines` may also contain virtual records. This causes an invalid quantity for the move. Indeed, even if the command operator would update the quantity on the `move_line` correctly, it won't for the quantity of the `move` because of its associated compute method: https://github.com/odoo/odoo/blob/26ba95ac1c5bbb24975efb1a6f53c1ab47b61532/addons/stock/models/stock_move.py#L399-L400 that relies on `.ids`, which is `[]` on virtual records. Therefore, keep the change minimal. opw-6133281
This update fixes an issue where Peppol/UBL XML files with embedded PDFs weren't automatically attached to vendor bills. The fix ensures that the PDF is correctly extracted and included as an attachment when receiving these XML files via email, improving the completeness of vendor bill data. This resolves a previous problem impacting invoice processing.
Original PR description
When receiving a Peppol/UBL XML file containing an embedded PDF via an email alias, the PDF is not extracted and attached to the resulting vendor bill. Steps to reproduce: - Set up a BE Company - Configure an incoming mail server - Set up an email alias for the Vendor Bill journal - Receive a Peppol XML with embedded PDF via alias - Check the created Bill Issue: PDF has not been extracted from the xml This occurs because the received xml is set as main attachment for the record and in this case we skip extraction opw-6075250 Forward-Port-Of: odoo/odoo#262047
This update fixes an issue where manually added analytic distributions on purchase orders were lost when the line's account was changed. Now, when a purchase order line's account is modified, the associated analytic distribution remains intact, ensuring accurate tracking of costs. This prevents data inconsistencies and simplifies reporting for users managing analytic accounting.
Original PR description
__ ## Short functional explanation of the error When confirming a Purchase Order holding lines with an analytic distribution that has been manually added, and creating a vendor bill out of this PO…
__ ## Short functional explanation of the error When confirming a Purchase Order holding lines with an analytic distribution that has been manually added, and creating a vendor bill out of this PO using the Auto-Complete field. When we change the account of that line, the line loses the manually added Analytic Distribution. ## Reproduction Steps 1. Go to Accounting. Click on the tab Configuration; under the Analytic Accounting section, click on Analytic Distribution Models. 2. Create an Analytic Distribution Model for a product. 3. Go to Purchase. Create a new PO, set a Vendor and select the product you created the Analytic Distribution Model for. On the right side of the form, click on the view menu and check Analytic Distribution to make it appear. 4. Click on the Analytic Distribution of the product and add a new one; for example, select Administrative in the Departments section. 5. Confirm order. 6. Go to Accounting and click on the Vendors tab > Bills. Create a new bill, and in the field Auto-Complete, select the PO you just created. 7. Change the account of the line. ### Expected behavior Only the account should be changed on the line. ### Unexpected behavior The manually added Analytic Distribution has disappeared. ## Origin of the issue When we change the `account_id` field, the compute method `_compute_analytic_distribution` is triggered. This method retrieves the related distributions of the line: https://github.com/odoo/odoo/blob/af32885ec5f07d492f3b8e8fff1785996a739f72/addons/account/models/account_move_line.py#L1154 which, in the context of Purchase, calls this method: https://github.com/odoo/odoo/blob/af32885ec5f07d492f3b8e8fff1785996a739f72/addons/purchase/models/account_invoice.py#L540-L545 We retrieve the distribution of the related line using `self.purchase_line_id.analytic_distribution`. However, this code isn't triggered when the move line has an analytic distribution, even though the related line `purchase_line_id` might have one! Therefore, we need to execute that code whether or not our move line has an analytic distribution. Note: the same behavior is to avoid when creating invoices for quotations. __ opw-6062466
This update resolves an issue where the PL VAT reporting XML (FA3) was incorrectly omitting a key date field. The fix ensures the system accurately compares the invoice issue date with the delivery date, aligning with Polish tax regulations. This prevents errors in VAT reporting and ensures compliance.
Original PR description
**Steps to reproduce** 1. Create a customer invoice with Invoice Date `2025-05-27` and accounting Date `2026-05-04`. 2. On the *Other Info* tab, set the Delivery Date to `2026-05-04` and post the…
**Steps to reproduce** 1. Create a customer invoice with Invoice Date `2025-05-27` and accounting Date `2026-05-04`. 2. On the *Other Info* tab, set the Delivery Date to `2026-05-04` and post the invoice. 3. Generate the FA(3) XML. **Issue** `P_6` is omitted from the payload even though the delivery date differs from the invoice issue date. The FA(3) information sheet (Warsaw, September 2025, binding from 1 February 2026) defines `P_6` as *"the date of delivery [...] if such date is specified and differs from the date of issue of the invoice"*, where the date of issue is `P_1` (Art. 106e sec. 1 item 1 of the VAT Act). In Odoo `P_1` maps to `invoice_date`, but the template at https://github.com/odoo/odoo/blob/4890b8021af2a5c025944220043d295bb7bbbb9b/addons/l10n_pl_edi/data/fa3_template.xml#L132 compares `delivery_date` against `invoice.date`, the accounting/entry date. When the invoice is posted on the delivery day the accounting date equals the delivery date, the guard evaluates to false, and `P_6` is wrongly dropped. Comparing against `invoice.invoice_date` aligns the guard with `P_1` as the spec requires. Ticket [link](https://www.odoo.com/odoo/project.task/6211119) opw-6211119
This update resolves an issue where Odoo failed to import simplified Italian electronic invoices (TD08) when a line item consisted entirely of taxes. The fix prevents a division-by-zero error, ensuring that valid tax-only invoices submitted by the Italian tax authority (Agenzia delle Entrate) can now be successfully imported. This improves the reliability of invoice processing for Italian businesses.
Original PR description
### Issue before this commit: Importing a simplified Italian electronic invoice or credit note (e.g., TD08) fails with a float division by 0 traceback if a document line consists entirely of taxes…
### Issue before this commit: Importing a simplified Italian electronic invoice or credit note (e.g., TD08) fails with a float division by 0 traceback if a document line consists entirely of taxes (where the total line amount equals the tax amount). ### Steps to reproduce the issue: 1. Download Accounting and l10n_it 2. Switch to IT company 3. Go to Vendors > Refunds 4. Try to import the xml from the ticket ### Cause of the issue: The XML parser attempts to dynamically calculate the tax percentage using the formula tax_amount / (amount - tax_amount). When a line is purely a tax adjustment, the taxable base (amount - tax_amount) evaluates to exactly zero, triggering the critical division by zero crash. https://github.com/odoo/odoo/blob/e3b0ca11d99b2ef819cdad68b169112cd73668b6/addons/l10n_it_edi/models/account_move.py#L1863-L1867 ### Reason to introduce the fix: To ensure Odoo successfully imports valid, tax-only EDI documents already accepted by the Agenzia delle Entrate. Ticket [link](https://www.odoo.com/odoo/project.task/6217373) opw-6217373 Forward-Port-Of: odoo/odoo#266374
10 changes
Resolved issues and error corrections
This update fixes an issue where upsell order lines weren't correctly calculating their invoiced quantity after a subscription was billed. The fix ensures that upsell quantities are accurately reflected in the sale order, resolving a discrepancy between order and invoice data. This improves the accuracy of subscription billing and reporting.
Original PR description
## **Issue:** When creating an upsell after a subscription is invoiced, the qty_invoiced field on the sale order line was showing 0.0, even though related invoice lines existed. ## **Steps to…
## **Issue:** When creating an upsell after a subscription is invoiced, the qty_invoiced field on the sale order line was showing 0.0, even though related invoice lines existed. ## **Steps to reproduce:** - Create and confirm a subscription. - Update the subscription `next_invoice_date` to a future date. - Generate an invoice for the subscription. - Create an upsell order from the subscription. - Confirm and invoice the upsell order. - Open the upsell sale order and check qty_invoiced. ## **Before Fix:** In _compute_qty_invoiced(), upsell lines have recurring_invoice=True and order_id.state='sale', so they are processed by _get_subscription_qty_invoiced(). The deferred date filter excludes their AMLs because of this condition, https://github.com/odoo/enterprise/blob/2ed34cc902d148fba7a88c159cd5c67a62112865/sale_subscription/models/sale_order_line.py#L189 returning 0.0 in the result dict. Since recurring_invoice=True, upsell lines never reach other_lines and super()._compute_qty_invoiced() is never called, causing qty_invoiced to fallback to its default value 0.0. After Fix 1 routes upsell lines to super()._compute_qty_invoiced(), a second issue is revealed. The _get_invoice_lines() overridden and applies a line.date > last_invoice_date filter. Since this condition fails and returns an empty recordset, leaving qty_invoiced at 0.0. ## **After Fix:** 1. In _compute_qty_invoiced(), upsell lines are routed to other_lines to bypass _get_subscription_qty_invoiced() and delegate to super()._compute_qty_invoiced(). 2. In _get_invoice_lines(), upsell lines are excluded from the date-based filtering and letting upsell lines use the base _get_invoice_lines method. OPW - 6213551 Steps to reproduce : [Video](https://drive.google.com/file/d/1px4J2oZJUtfBwIA_syQfdgXfRRg_6EBg/view?usp=drive_link) OPW - 6213551
This update fixes an issue where currency differences were incorrectly aggregated in hierarchical financial reports. Previously, the system was combining figures from different currencies, leading to inaccurate totals. This change ensures that reports accurately reflect the value of transactions in their original currency, improving the reliability of financial data.
Original PR description
opw-6015098
This update fixes an issue where returned sales orders with invoices were incorrectly marked as 'Nothing to Invoice'. The change ensures that sales orders with created invoices are accurately identified as 'Fully Invoiced', streamlining invoice processing and preventing reporting discrepancies. This improves data accuracy related to sales order invoicing.
Original PR description
A sale order with a product that has an invoice policy on delivered quantities is marked as "Nothing to Invoice" regardless of the potential invoices related to it Steps to reproduce: 1. Install Sales, Inventory and Invoicing 2. Go to Sales, create a new quotation for customer Acme Corporation with product Acoustic Bloc Screens and confirm it 3. Go to the delivery and validate it with quantity 1 4. Go back to the SO, create an invoice and confirm it 5. Open the delivery, return it and validate it 6. Go back to the SO, create an invoice and confirm it 7. Go to Sales > Orders > Orders 8. The SO has "Nothing to Invoice" as invoice status Issue: This PR https://github.com/odoo/odoo/pull/254871 changed the behavior to mark a SOL with delivered quantity as "Nothing to Invoice" but it can actually be "Fully Invoiced" if invoices have been created for the related SO Solution: Also mark sale orders that have invoices as "Fully Invoiced" opw-6159512
This update optimizes how Odoo determines putaway locations, significantly speeding up the process. Previously, the system repeatedly calculated weights for each location, leading to slow performance. The fix now batches these calculations, resulting in a much faster and more efficient system, especially when handling multiple products.
Original PR description
The _get_putaway_location() method tries to determine a location in which a product can be stored:…
The _get_putaway_location() method tries to determine a location in which a product can be stored: https://github.com/odoo/odoo/blob/441a6d1b928a44b9a760f926180a925159edff3e/addons/stock/models/product_strategy.py#L175-L181 When no location can be used, the loop iterates over the whole list to call _get_weight() method on each one. We propose to batch the call to _get_weight() method for all locations that will be used and store the result in a dictionnary passed in the context to avoid computing them several times during the same delivery preparation. Benchmarks -------------- For one product with no possible location: | No locations | Before PR | After PR | |------------|--------|-------| | 780 | 9 s | < 1 s | For 98 products that can be placed in various locations: | No locations | Before PR | After PR | |------------|--------|-------| | 6000 | 20 s | 8 s | For one product that could be placed in any of the indicated locations, we will compute the weights for every location while only the first one would have been computed without the fix: | No locations | Before PR | After PR | |--------------|-----------|----------| | 500 | 41 ms | 524 ms | | 2000 | 97 ms | 2.02 s | | 10000 | 513 ms | 10.83 s | opw-5949370 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves an issue where importing Peppol XML invoices through newly created purchase journals (using only the Invoicing app) fails due to a missing default account. The fix automatically assigns a default expense or income account, mirroring the behavior for bank/cash journals, ensuring successful invoice imports.
Original PR description
When a user installs only the Invoicing app and creates a new purchase journal, no default_account_id is set on the journal. The Invoicing app does not expose account configuration, so the user cannot fix this manually. As a result, importing a Peppol XML invoice through that journal fails with a database constraint error because the generated account.move.line has a null account_id. https://github.com/odoo/odoo/blob/16245530f0e3e9be21c8b96baaecd3a679420cac/addons/account/models/account_journal.py#L776-L805 This already auto-creates accounts for bank/cash journals, but does nothing for sale/purchase journals. Steps to reproduce: - Install the Invoicing app (no full Accounting) - Create a new purchase journal with type 'purchase' - Go to Vendors -> Bills and Upload a Peppol XML file - Error importing attachment as invoice (decoder=_import_invoice_ubl_cii) Ticket [link](https://www.odoo.com/odoo/action-4043/6014363) opw-6014363
This update resolves an issue in the Italian annual tax report where incorrect values (VL3/VL4 and VL32/VL33) were displayed simultaneously. The fix ensures that only the positive balance for each pair is shown, aligning with tax reporting logic and improving report accuracy.
Original PR description
### Issue In the Italian annual tax report, both VL3/VL4 and VL32/VL33 values could be displayed at the same time However, according to the report logic, only the positive balance should be shown for…
### Issue In the Italian annual tax report, both VL3/VL4 and VL32/VL33 values could be displayed at the same time However, according to the report logic, only the positive balance should be shown for each pair: - VL3 (Tax Due) or VL4 (Tax Credit) - VL32 (Tax Due) or VL33 (Tax Credit) The other one should stay 0 If the global balance is null, both can be 0 ### Cause The lines VL3, VL4, VL32, and VL33 were using the shortcut field `aggregation_formula` directly on the `account.report.line` record This shortcut format does not evaluate or support conditional subformulas like `if_above(EUR(0))` As a result, the report computed and displayed both lines of each pair without filtering out the negative or unwanted values ### Steps to reproduce - Install `l10n_it` and `accountant` and switch to IT Company - Create a balanced Journal Entry for any account - Add the Tax Grid v20 on one of the lines to impact the annual report - Open the `Annual Tax Report (IT)` - Go to the `VL` section - Check the value of VL3/VL4 and VL32/VL33 After the fix, only one value can be positive and the other 0 Ticket [link](https://www.odoo.com/odoo/project.task/6212694) opw-6212694
This update fixes an issue where the pension fund tax was incorrectly applied to all invoice lines with the same VAT rate, leading to inaccurate accounting. The fix now correctly identifies the tax exemption reason from the bill data, ensuring the pension fund tax is applied accurately to the first invoice line. This improves tax compliance and financial reporting.
Original PR description
In `l10n_it_edi` vendor bill import, the pension fund tax was incorrectly applied to all invoice lines sharing the same VAT rate, even though they have different `l10n_it_tax_exemption_reason`s, resulting in wrong entries and document total. We now extract the Tax Exemption reason from the `DatiCassaPrevidenziale` node, and use it to search the correct tax. Steps to reproduce: 1. Install `account` and `l10n_edi_it` 2. In the `4% INPS` tax, set `TC22` in pension fund type and `N2.2` in exoneration 3. Import bill from the ticket 4. See the pension fund tax is applied to all the lines. It should only be applied only to the first one. Ticket [link](https://www.odoo.com/odoo/project.task/6212975) opw-6212975
This update resolves an issue where Android 14 users couldn't access their device's camera when using file input fields. The fix adds support for taking photos directly through the image input type, ensuring consistent functionality across Android devices. This improves the user experience for mobile users.
Original PR description
Since Android 14 we don't have option to take a photo on clicking on file input in Chrome.
This for example will allow only images but no option "Camera"
```html
<input type="file" accept="image/*/>
```
A workaround is to use a dummy mimetype (`*/*`), example `dummy/allowAndroidCamera` The fix will be applied on image widget in addition to the original `acceptedFileExtensions` to not override the existing `accept` attribute
Linked url
- https://blog.addpipe.com/html-file-input-accept-video-camera-option-is-missing-android-14-15/
- https://stackoverflow.com/questions/77876374/html-input-type-file-not-working-to-pull-up-camera-for-pixel-android-14-comb/79163998#79163998
- https://issues.chromium.org/issues/40937303
opw-6040375
backport of https://github.com/odoo/odoo/pull/265750This update resolves an issue where Odoo failed to import Italian electronic invoices (TD08) consisting entirely of taxes, causing a crash. The fix prevents a division-by-zero error when calculating tax percentages, ensuring that valid tax-only EDI documents from the Agenzia delle Entrate can now be imported successfully. This improves the reliability of invoice processing for Italian businesses.
Original PR description
### Issue before this commit: Importing a simplified Italian electronic invoice or credit note (e.g., TD08) fails with a float division by 0 traceback if a document line consists entirely of taxes…
### Issue before this commit: Importing a simplified Italian electronic invoice or credit note (e.g., TD08) fails with a float division by 0 traceback if a document line consists entirely of taxes (where the total line amount equals the tax amount). ### Steps to reproduce the issue: 1. Download Accounting and l10n_it 2. Switch to IT company 3. Go to Vendors > Refunds 4. Try to import the xml from the ticket ### Cause of the issue: The XML parser attempts to dynamically calculate the tax percentage using the formula tax_amount / (amount - tax_amount). When a line is purely a tax adjustment, the taxable base (amount - tax_amount) evaluates to exactly zero, triggering the critical division by zero crash. https://github.com/odoo/odoo/blob/e3b0ca11d99b2ef819cdad68b169112cd73668b6/addons/l10n_it_edi/models/account_move.py#L1863-L1867 ### Reason to introduce the fix: To ensure Odoo successfully imports valid, tax-only EDI documents already accepted by the Agenzia delle Entrate. Ticket [link](https://www.odoo.com/odoo/project.task/6217373) opw-6217373
This update ensures that if a Stripe terminal payment capture fails, the payment status is correctly set to 'retry' instead of being marked as 'done' silently. This prevents incorrect payment statuses and ensures that POS users are immediately aware of payment issues, improving accuracy and preventing lost sales.
Original PR description
Before this commit, a Stripe terminal payment could still be marked as `done` even if the capture step failed. This happens when the card authorization succeeds, `processPayment` returns a payment…
Before this commit, a Stripe terminal payment could still be marked as `done` even if the capture step failed.
This happens when the card authorization succeeds, `processPayment` returns a payment intent, but the subsequent `stripe_capture_payment` RPC fails and `capturePaymentStripe()` returns `false`. The capture flow did not guard that return value and still fell through to `line.set_payment_status("done")`.
In practice, this can happen for example if the Odoo server cannot resolve `api.stripe.com` while capturing the payment intent. Stripe then keeps the payment in `requires_capture`, while the POS line is still synced as paid.
Guard the failed capture path and stop the flow before marking the line as done. In that case, the payment line is put back to `retry` so the failure is visible in the POS instead of silently creating a paid, uncaptured payment.
opw-6075384
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Backport of: https://github.com/odoo/odoo/pull/261521