Daily updates from Odoo
Wednesday, August 27, 2025
71 changes · saas-18.4
Resolved issues and error corrections
Point of Sale now runs the normal post-payment steps even when working offline, so automatic receipt printing is not skipped. This helps stores continue checkout operations smoothly during internet outages when the local receipt printer is still available.
Original PR description
Steps to reproduce: 1. Configure a POS to use a receipt printer with automatic receipt printing. 2. Confirm that the receipt is printed automatically after a order is made as expected. 3. Disconnect from the internet so that POS continues in Offline mode (but ensure you still have access to the receipt printer on the local network). 4. Make an order in offline mode. EXPECTED: The receipt is printed automatically as before ACTUAL: The receipt is not printed. The fix is to still run the `afterOrderValidation` method in offline mode, as previously it was being bypassed and the receipt screen being shown directly. task-4946305 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#224211 Forward-Port-Of: odoo/odoo#224021
The Point of Sale now reuses an existing empty order when staff start a new order from the receipt screen. This prevents clutter from unnecessary blank orders and keeps the checkout workflow cleaner.
Original PR description
- When clicking `New order` on the receipt screen, we now want to reuse an empty order (not finalized and no order lines) before creating a new one. This avoids creating many useless empty orders. task-id: 5003010 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#222891 Forward-Port-Of: odoo/odoo#222276
Odoo now avoids reusing archived supplier bank accounts when importing vendor bills with embedded bank details. This prevents duplicate bank account errors that could block electronic invoice processing and helps vendor bills import reliably.
Original PR description
### Issue When receiving vendor bills that include bank details, if the partner has archived bank accounts, Odoo may attempt to update them. This leads to a duplicate key violation on…
### Issue
When receiving vendor bills that include bank details, if the partner has archived bank accounts, Odoo may attempt to update them. This leads to a duplicate key violation on `res_partner_bank` when the same account number already exists for the partner.
#### Affected versions
16.0 and later
#### Error example
```bash
2025-07-08 13:36:52,942 204 INFO server-dummy odoo.addons.mail.models.mail_thread: Routing mail from "Client Name" <erp@odoo.com> to "M7- Odoo V17" <purchases@test.odoo.com>,purchases@test.odoo.com with Message-Id <*****.****.*****-****-*****-****.****@******>: direct alias match: ('account.move', 0, {'company_id': 1, 'move_type': 'in_invoice', 'journal_id': 10}, 1, mail.alias(6,))
2025-07-08 13:36:52,946 204 INFO server-dummy odoo.addons.mail.models.mail_thread: Primary email missing on account.move
2025-07-08 13:36:53,576 204 ERROR server-dummy odoo.sql_db: bad query: UPDATE "res_partner_bank" SET "acc_holder_name" = 'M7 GROUP INC.', "company_id" = NULL, "has_iban_warning" = false, "has_money_transfer_warning" = false, "sanitized_acc_number" = '1234567', "write_date" = '2025-07-08T13:36:52.897826'::timestamp, "write_uid" = 1 WHERE id IN (63)
ERROR: duplicate key value violates unique constraint "res_partner_bank_unique_number"
DETAIL: Key (sanitized_acc_number, partner_id)=(1234567, 3524) already exists.
2025-07-08 13:36:53,576 204 ERROR server-dummy odoo.addons.account.models.account_move: Error importing attachment 'factur-x.xml' as invoice (decoder=_import_invoice_ubl_cii)
Traceback (most recent call last):
File "/home/odoo/src/odoo/addons/account/models/account_move.py", line 3219, in _extend_with_attachments
with self.env.cr.savepoint():
File "/home/odoo/src/odoo/odoo/sql_db.py", line 85, in __exit__
self.close(rollback=exc_type is not None)
File "/home/odoo/src/odoo/odoo/sql_db.py", line 89, in close
self._close(rollback)
File "/home/odoo/src/odoo/odoo/sql_db.py", line 113, in _close
self._cr.flush()
File "/home/odoo/src/odoo/odoo/sql_db.py", line 137, in flush
self.transaction.flush()
File "/home/odoo/src/odoo/odoo/api.py", line 879, in flush
env_to_flush.flush_all()
File "/home/odoo/src/odoo/odoo/api.py", line 739, in flush_all
self[model_name].flush_model()
File "/home/odoo/src/odoo/odoo/models.py", line 6362, in flush_model
self._flush(fnames)
File "/home/odoo/src/odoo/odoo/models.py", line 6464, in _flush
model.browse(ids)._write(vals)
File "/home/odoo/src/odoo/odoo/models.py", line 4548, in _write
cr.execute(SQL(
File "/home/odoo/src/odoo/odoo/sql_db.py", line 332, in execute
res = self._obj.execute(query, params)
psycopg2.errors.UniqueViolation: duplicate key value violates unique constraint "res_partner_bank_unique_number"
DETAIL: Key (sanitized_acc_number, partner_id)=(1234567, 3524) already exists.
```
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#224248
Forward-Port-Of: odoo/odoo#223873This fixes a subcontracting receipt issue where changing the received quantity for products using lot-tracked components could leave users unable to validate the receipt. Users are now guided to adjust quantities through the proper component recording flow, and can access related production records when needed.
Original PR description
Issue ----- The problem is when a subcontracted product has a component tracked by lots. Creating a receipt for the subcontractor, marking it as Todo then changing the quantity leads to the reception…
Issue
-----
The problem is when a subcontracted product has a component tracked by lots. Creating a receipt for the subcontractor, marking it as Todo then changing the quantity leads to the reception being impossible to validate because the lots for the components cannot be set from the move.
Steps to reproduce
-----
- Create a product (Comp1)
- Tracked by lots
- Create a product (Prod1)
- Add a BoM - Subcontracted - Flexible consumption - Set Comp1 as consumable
- Create a receipt for 2 Prod1
- Mark as Todo
- Set Quantity to 3
- Save
- Try to validate the receipt
Situation
-----
Before changing the quantity, the user has 2 buttons ("Record components" and the move's hamburger) which open the "Subcontract" wizard. This wizard is where they can set a lot/serial for the products.
When they change the quantity of the move, the inverse method of quantity is called
https://github.com/odoo/odoo/blob/74a8334558bf86c07c0d68090a9126911867ef42/addons/stock/models/stock_move.py#L170-L171
This method is overridden in the mrp_subcontracting module
https://github.com/odoo/odoo/blob/74a8334558bf86c07c0d68090a9126911867ef42/addons/mrp_subcontracting/models/stock_move.py#L75
The part that's important to our use case is
https://github.com/odoo/odoo/blob/74a8334558bf86c07c0d68090a9126911867ef42/addons/mrp_subcontracting/models/stock_move.py#L81-L82
Recording components leads us to create a backorder production
https://github.com/odoo/odoo/blob/74a8334558bf86c07c0d68090a9126911867ef42/addons/mrp_subcontracting/models/mrp_production.py#L90-L91
In our specific use case, this is problematic because the subcontract wizard loads the form of the last production
https://github.com/odoo/odoo/blob/74a8334558bf86c07c0d68090a9126911867ef42/addons/mrp_subcontracting/models/stock_move.py#L245
The user has no way to access the previous production which lacks lot/serial (other than opening the MO itself). Obviously, we don't want to mess with this flow, but there are 2 things we can do:
1. Avoiding weird cases such as this one by forcing the user to change the quantity through the appropriate wizard
2. Providing a link to the mrp.production once some production has been recorded
For the first point, the stock.move model already has a field we can use
https://github.com/odoo/odoo/blob/8c8449f51d5e327ccd2e4bb7c3c4868d51c6d619/addons/stock/models/stock_move.py#L180
We can just override the compute to fit our use case.
For the second point, there is already a button for this. The problem is that its display condition was changed in 9ca1064 to only show once the move is picked. This fix was a bit of an over correction because we also want to show the button for unpicked moves for which a production has been recorded.
-----
Ticket:
opw-4751896
Forward-Port-Of: odoo/odoo#219268Expanding a meeting form from a pop-up now keeps the information already provided, such as the meeting name linked to a task. This prevents users from losing context when switching to the full form view and makes scheduling activities more reliable.
Original PR description
### Steps to reproduce: - Go to any task in project module - Create a new meeting activity - Open Calendar and drag to create a slot - Notice the name of the meeting in the pop-up is the same as the…
### Steps to reproduce: - Go to any task in project module - Create a new meeting activity - Open Calendar and drag to create a slot - Notice the name of the meeting in the pop-up is the same as the task - Click on the expand button top-right of the dialog - Notice the calendar.event form opened but without a name ### Cause: When expanding the view using 'More options' button we are keeping the context in the new request. https://github.com/odoo/odoo/blob/d9c63a85955c2321bae1a705cc09b2554155f826/addons/calendar/static/src/views/attendee_calendar/attendee_calendar_controller.js#L45-L49 But when doing the same through the expand button we don't pass the current context so it will be lost. https://github.com/odoo/odoo/blob/3dde420665257c63885e891f1ec366568df5007b/addons/web/static/src/views/view_dialogs/form_view_dialog.js#L106-L116 ### Fix: Backporting the commit https://github.com/odoo/odoo/commit/4f71fbbd26b428e57943d974e8441bef295cdef1 to pass the context while expanding the form view opw-4966486 Forward-Port-Of: odoo/odoo#221422
Duplicated journal entries no longer keep the original partner at the entry level when users change the partner on the journal items. This prevents list views from showing an outdated partner name and keeps accounting records consistent with the user's edits.
Original PR description
When changing `partner_id` on the `account.move.line`s of a duplicated journal entry if this journal entry already had a partner_id, it will stay the same (possible to see from list view) but the…
When changing `partner_id` on the `account.move.line`s of a duplicated journal entry if this journal entry already had a partner_id, it will stay the same (possible to see from list view) but the move line will be correctly changed. Step to reproduce: - Select a journal entry of type PBNK - Duplicate the journal entry - Change the partner on the journal items and save - Go back to the list view, the partner name displayed is from the original journal entry When clicking on duplicate it will call the function copy and super.copy() will call copy_data from account_move; This line allow to copy the partner_id (which is needed since invoices revert goes through copy) Since there is no condition on the type of entry, it will also copy the partner_id in our case: https://github.com/odoo/odoo/blob/22c333d0ed7eba1165f6462e668998d37fcabb73/addons/account/models/account_move.py#L2424-L2426 The introduction of this change introduced our issue, It allow for all duplication to copy the partner_id. Original fix : https://github.com/odoo/odoo/commit/e1d18960b57b36b8bf69bc787ef6078dcba8c855 opw-4907648 Forward-Port-Of: odoo/odoo#223959 Forward-Port-Of: odoo/odoo#217755
Corrects an invalid ending command in stock product label templates used for ZPL printers. This helps ensure barcode labels print reliably without printer command errors.
Original PR description
In the ZPL, the `^XZ` command indicates the end of a label. For an unknown reason (a typo ?), the PR [1] replaces some of them by `^XZj` which is not a valid ZPL command. [1]: https://github.com/odoo/odoo/pull/187225 Forward-Port-Of: odoo/odoo#220518
Point of Sale now correctly adds sales order lines even when the related order was not confirmed and no stock movements were created. This prevents tracked products from being skipped during settlement, helping staff complete affected PoS sales reliably.
Original PR description
Before this commit, if an order was not confirmed and stock moves were not created, if products are tracked, the order lines would not be added to the PoS. opw-5026892 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#223833 Forward-Port-Of: odoo/odoo#223591
This fix removes extra invoice data that caused Nilvera to reject Turkish E-Archive invoices when no tax office was set. It also corrects the Türkiye label in the electronic invoicing format, improving consistency for Turkish localization users.
Original PR description
### Description of the issue/feature this PR addresses: Nilvera rejects E-Archive invoices if extra fields are present under `PartyTaxScheme` when no tax office is set. In addition, the…
### Description of the issue/feature this PR addresses:
Nilvera rejects E-Archive invoices if extra fields are present under
`PartyTaxScheme` when no tax office is set. In addition, the
`invoice_edi_format` selection name for TR was incorrect.
### Current behavior before PR:
When generating E-Archive invoices, Odoo includes extra nodes such as
`registration_address_vals`, `registration_name`, and `company_id`
under the `PartyTaxScheme` element. Nilvera’s validation fails if
these nodes are present while no tax office is configured. At the same
time, the TR value for `invoice_edi_format` was using the wrong name,
which caused inconsistencies. These issues result in blocking
validation errors on Nilvera’s side and prevent the invoices from
being accepted.
### Desired behavior after PR is merged:
After this fix, the `PartyTaxScheme` is cleaned up only to include the
expected XML structure:
```xml
<cac:PartyTaxScheme>
<cac:TaxScheme>
<cbc:Name>TAX OFFICE NAME</cbc:Name>
</cac:TaxScheme>
</cac:PartyTaxScheme>
```
And the invoice_edi_format selection name for TR will be corrected
to display Türkiye rather than Turkyie.
task-5017223
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#223770This update fixes an internal test for employee time off accruals by making it use a fixed date. It helps ensure the test remains reliable over time and avoids false failures in future test runs, without changing user-facing behavior.
Original PR description
The test is failing when run one year in the future as it depends on the date but we don't freeze the time. runbot-error-230721 Forward-Port-Of: odoo/odoo#224240
Customers using mobile self-ordering will now see their order screen update correctly after payment is completed, even if they close the payment page before confirmation finishes. This prevents confusion after payment and helps staff and customers rely on accurate order status.
Original PR description
Before this commit, if a user closed the payment page on mobile after finalizing the payment but before the payment was confirmed, the self order UI would not update once the payment was confirmed. After this commit, the self-order UI is correctly updated after the payment process, even if the payment page was closed. opw-4911434 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#223813 Forward-Port-Of: odoo/odoo#222954
This fix prevents a CRM interface test from failing when the system runs tests with simulated dates. It improves test reliability without changing the CRM experience for users.
Original PR description
When using the faketime mode for testing, the crm_rainbowman tour fails because the underlying SQL query is using `CURRENT_DATE`. Unfortunately, this SQL keyword cannot be replaced globally by a function easyly (like it was done for the NOW function in faketime mode). ~~With this commit, the SQL query is adapted to use the SQL NOW function instead.~~ With this commit, the tour will be skipped in faketime mode Forward-Port-Of: odoo/odoo#223909
This fix keeps mobile website pages from scrolling sideways when animated content briefly moves outside the visible page area. It improves the browsing experience by ensuring pages stay within the expected screen width during scroll animations.
Original PR description
Scenario: - add a 2 columns content widget - set the right column text to "On Scroll" animation with "Slide" effect and "From Right" direction so the content may be out of the page - save and reload…
Scenario: - add a 2 columns content widget - set the right column text to "On Scroll" animation with "Slide" effect and "From Right" direction so the content may be out of the page - save and reload the page on mobile - scroll down get in middle of animation with some content out of page - try to scroll to the right Result: we can scroll to the right and see the overflowing animated content outside of the expected page limit. History: During an animation, a fix prevent the horizontal scrollbar by setting "overflow-x: hidden" (or crop depending on version) on a given element: - in odoo/design-themes@51abb093c77993363b170b12be134c95b3009895 (14.0: 2021) it was added to $().getScrollingElement() - in 189a7c96e6e26825dc05c0c6466576fe63aa091e (18.0: 2022) the main page scroll was moved from #wrapwrap to html - in fece9cb85761e6cb3fe3642f947661464402363b (18.0: 2024) the "overflow-x: hidden" was moved to the body element Cause: the "overflow-x: hidden" is ignored by mobile browser on html and body tags ([example of report]), so in 18.0 and over the possible horizontal scrollbar caused by an animation is not hidden. Fix: apply the "overflow-x: clip/hidden" on #wrapwrap element. [example of report]: https://stackoverflow.com/questions/14270084 opw-4575726 Forward-Port-Of: odoo/odoo#213802
This fix prevents duplicate zoom windows from opening on product pages when a recently sold products carousel is present. Customers can now use keyboard controls such as arrow keys and Escape normally when viewing enlarged product images, improving the shopping experience.
Original PR description
Versions -------- - saas-18.2+ Steps ----- 1. Have a product with extra eCommerce images; 2. enable zoom-on-click on the product page; 3. add a recently-sold product carousel to the page; 4. click on…
Versions -------- - saas-18.2+ Steps ----- 1. Have a product with extra eCommerce images; 2. enable zoom-on-click on the product page; 3. add a recently-sold product carousel to the page; 4. click on an image to zoom in; 5. attempt to use arrow keys to navigate or using esc to exit zoom. Issue ----- Keys don't appear to do anything. Cause ----- Commit b8d0ab4275b24 set `oe_website_sale` as `snippet_classes` on the `s_dynamic_snippet_products` snippet, in order to enable the `websiteSaleTracking` widget, which uses this class as `selector`. Issue is this class also gets used as the selector by the `WebsiteSale` widget which adds zoom-on-click event listeners. As there are two elements with the `oe_website_sale` class now, this widget gets called twice, and because the query selector selects all image elements on the sale page, images get duplicate event listeners assigned to them. Consequently, clicking on an image opens two lightboxes, and the keys only impact the one hidden behind the other, making it appear as if key presses aren't doing anything. Solution -------- Instead of querying all images on the sale page in each call of the widget, only query for images in `this.el`. opw-4908881 Forward-Port-Of: odoo/odoo#223231
Sales order line prices now update properly when a quantity change triggers a different pricelist rule. This prevents customers from seeing or being charged an outdated unit price on quotes and sales orders, especially for volume-based pricing.
Original PR description
> [!Note] > This PR unreverts fc6b9ed22728 with a minor modification to ensure one `res.currency` record to compare amounts. **Steps to reproduce**: 1. Install the `sale` module. 2. Enable…
> [!Note] > This PR unreverts fc6b9ed22728 with a minor modification to ensure one `res.currency` record to compare amounts. **Steps to reproduce**: 1. Install the `sale` module. 2. Enable `Pricelists` under `Settings > Sales > Pricing > Pricelists`. 3. Create two pricelists: - Pricelist A with two fixed-price rules: - 0.75 for quantity ≥ 0 - 0.50 for quantity ≥ 1000 - Pricelist B with a -10% discount applied to Pricelist A. 4. Create a Sales Order using Pricelist B. 5. Add a product to the order line. 6. Increase the quantity to 1000. **Observed behavior**: - The unit price does not update according to the pricelist rule for quantity ≥ 1000. - If you switch the pricelist to another and then back again, the `Update prices` button appears and correctly updates the price. **Root cause**: - The price is not recomputed when the quantity changes because the `price_unit` is not updated because it does not match the `technical_price_unit`. - Since e1b22257a714, `price_unit` is rounded (2 decimals), but `technical_price_unit` is not. This causes a mismatch in comparison logic due to rounding differences. **Solution**: - Replace direct float comparison with `currency_id.compare_amounts()` to ensure proper comparison with rounding precision. opw-4944644 Forward-Port-Of: odoo/odoo#223548
Website editors can once again change the thickness of a website header border from the header options. This restores expected visual customization control and prevents confusion when styling site headers.
Original PR description
Since [1], the header border width option no longer had any effect. This commit restores the ability to change the border width from the header options. Steps to reproduce: - Go to Website in edit mode - Select the header to display its options - Change the border width (e.g., set to `10px`) - Bug: no visible change [1]: https://github.com/odoo/odoo/commit/d0daf3990079477ef7552d769b944b55d9be4366
The privacy lookup test was updated so it no longer fails when optional localization modules add extra partner references. This is an internal test-only fix and does not change how the product works for users.
Original PR description
The test `test_wizard_indirect_reference` failed when modules like `l10n_gt_edi` were installed. This was due to additional Many2one fields (e.g., `l10n_gt_edi_consignatory_partner` on `account.move`) referencing `res.partner`, which were picked up by the privacy lookup wizard. This commit updates the test to avoid assuming a fixed number of reference lines and instead asserts the presence of the expected ones (the partner and the company). No change in functional behavior. RB-[230449](https://runbot.odoo.com/odoo/error/230449) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#222105
Users can now duplicate multiple appointment bookings at the same time without triggering an error. This makes managing repeated or copied bookings smoother and avoids interruptions in appointment workflows.
Original PR description
This error occurs when users attempt to duplicate multiple bookings within an appointment. Steps to reproduce: --- - Install `appointment` module - Select an appointment (ie. Dental Care) - Click on New and make 2 new bookings - Go to list view > Select both records > Duplicate Traceback: --- `ValueError: Expected singleton: calendar.event(5, 8)` This occurred because we called `default_get` with a non-empty recordset at the beginning of the `create` method. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#224188
Fixes the Job Position form so Recruiter and Interviewers fields are populated even when no company is selected. This helps hiring teams assign the right people without needing to set a company first, while still respecting company-specific user lists when a company is chosen.
Original PR description
In the Job Position form, the 'Recruiter' and 'Interviewers' fields were empty when no company was selected. This was due to the static domain using 'company_id' directly without taking into consideration that company_id can be False. This fix introduces computed domain fields (, ) that dynamically adapt based on the selected company. If a company is set, users belonging to that company are shown. If not, only internal users are listed regardless their companies. Related task: 4926154. 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#224114 Forward-Port-Of: odoo/odoo#217884
When users turn formatted text into a button in the HTML editor, the button now keeps the original font size. This prevents unexpected visual changes and helps website content look as intended after editing.
Original PR description
### Steps to reproduce: - Type some text and apply a large font-size. - Select the text and apply the button style. - Notice that the font-size is not reflected on the button. ### Description of the…
### Steps to reproduce: - Type some text and apply a large font-size. - Select the text and apply the button style. - Notice that the font-size is not reflected on the button. ### Description of the issue/feature this PR addresses: - The `<a class=btn>` element was placed inside a font-size `<span>`. - However, the `.btn` class defined its own font-size, causing the original styling to be overridden. ### Desired behavior after PR is merged: - Improved the splitAroundUntil utility to correctly handle cases where the target node has no previous or next sibling. In such edge cases, the function now recursively splits up the inline ancestry until the specified limitAncestor, ensuring that the target node is fully isolated. - The font-size `<span>` is moved inside `<a>` tag when applying a button style. - This ensures the original font-size is preserved and correctly displayed. task-4731416 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#223640 Forward-Port-Of: odoo/odoo#216300
This fix prevents the website editor from crashing when users paste multiple content blocks inside inline text areas. It improves editing reliability and also corrects an issue where empty inline content could be filled twice, avoiding unwanted extra spacing or line breaks.
Original PR description
Problem: When pasting two blocks inside an inline element, a traceback occurs. Cause: During `insert`, when `insertBefore` is `true` and `isEmptyBlock(right)` after `splitElement`, `currentNode` is set to `right`. But `right` may already have been deleted, leading to an invalid reference. Solution: Delete `right` if empty, but do not set `currentNode` to `right` in that case. Steps to reproduce: It is tricky to reproduce manually (you must copy two blocks and paste them in an inline element). A test has been added to cover the case. opw-4972695 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#224029 Forward-Port-Of: odoo/odoo#223229
This fix restores the intended rule for showing QR codes on Saudi Arabia invoices after it was missed during a forward port. It helps ensure compliant invoice reports display the QR code when expected.
Original PR description
In this commit: https://github.com/odoo/odoo/commit/fdb37c9aa3d2c6002b42e87ebd14afd280ebd03f We changed the condition to display the qr code, but the change was lost in the forward port task-5039596 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#224051
This fix ensures the Threads social media icon displays correctly when used in email marketing snippets. Recipients will now see the intended icon in delivered emails, improving the consistency of branded marketing content.
Original PR description
Problem: When adding the Threads icon to an email marketing snippet and sending the email, the icon does not appear in the received email. Solution: Add support for the newly added icons from commit 21db1065aee9b403a316389f306c865cc47354ed (same fix as commit 7e9466e27d61fa8ece43d2238e1570dc3e65337a). Steps to reproduce: - Add the Threads icon to an email marketing snippet. - Send a test email. - Observe that the icon is not visible in the received email. opw-5024970 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#224189
Creating a child menu on a website now keeps it under the menu chosen by the user instead of moving it to the main website menu. This prevents confusing website navigation changes and helps administrators manage menu structures reliably.
Original PR description
Steps to reproduce: - Have a database with only the website module installed --> Turn on the developer mode. - Go to Configuration ---> Menus - Create a Menu (Parent) and a child menu (Child) in that. - Upon saving, the following behaviour is observed: the child menu is converted to the main menu. Issue: Before this commit, when we create a child menu for single website then it takes the website.menu_id.id as the parent_id. Which is wrong because it gives the parent_id of the websites' top menu. Solution: With this commit, we have passed the correct parent_id from vals to solve this issue. task-4231974 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#222615
This update improves how Odoo handles cases where an automated browser test unexpectedly loses its connection. Instead of waiting for timeouts or reporting a misleading cleanup error, the system now fails the test promptly and records the real connection issue for investigation.
Original PR description
As far as I can tell this can occur if the ws connection gets closed while we're in a `recv`: in that case `recv` will mark the connection as closed (`connected=False` and `sock=None`) and raise…
As far as I can tell this can occur if the ws connection gets closed while we're in a `recv`: in that case `recv` will mark the connection as closed (`connected=False` and `sock=None`) and raise `WebSocketConnectionClosedException`, then any attempt to `send` will fail with `WebSocketConnectionClosedException`. Here this likely is an issue because in `_receive` `WebSocketConnectionClosedException` goes through the generic exception handler, which sees that: - it's not a `ConnectionResetError` - the result is not set - and the ws is not connected So `_receive` just cancels the result and `return`s, and when whatever's waiting on a future finally times out it tries to cleanly shut down and hits a connection that's already closed. Handle a connection closed in that context more properly: - unset `ws` so we don't try to clean it up, as we know it's closed - set the result as being in error - cancel every future in order to immediately go to the tour failure step rather than wait for timeouts Note that this will not really *fix* any error per se, because every time this happens it means the browser abruptly closed the WS connection (possibly straight up died), so this should mostly properly attribute the error so we can investigate it. https://runbot.odoo.com/odoo/error/229793 Forward-Port-Of: odoo/odoo#224023
The list view now shows a plus sign when a selection may include more records than the displayed limit, such as "10,000+". This helps users understand when bulk actions could affect additional records and reduces the risk of applying actions to an unexpected number of items.
Original PR description
Previously, when selection was made in domain mode, the system used the global `web.active_ids_limit` config parameter instead of the actual number of records selected (based on session limit). This caused unintended behavior. For example: - Open a list view of a model with 25,000 records. - The pager limit is initially set to 10,000. - When selecting all 10,000 visible records and performing an action (e.g., archive), the system would incorrectly apply the action to 20,000 records (based on the default value of `web.active_ids_limit`), not the selected 10,000. Forward-Port-Of: odoo/odoo#219639 Forward-Port-Of: odoo/odoo#217094
This fixes an issue where standard Employee and Department views could disappear after enabling a Calendar view through Studio. Users can now customize HR screens while keeping the usual view options such as activity, kanban, and pivot available.
Original PR description
**Steps to reproduce:** - Install `hr` and `web_studio`. - Go to Employees → click Studio icon. - Views → activate Calendar view. **Observation:** - Existing views (activity, kanban, pivot, etc.) disappear from the view types. **Issue:** - After commit https://github.com/odoo/odoo/pull/160280/commits/e67ed24320c555c0cc63d59aa4921267e10a472d, view_mode in actions was removed, so only default (list, form) and Studio-added views remain. **Solution:** - Add view_mode to the action to preserve standard views after customisation. opw-4967654 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#222485
This fix ensures Canary Islands withholding taxes are classified under the proper Spanish tax type instead of the default taxable category. It improves accuracy in tax reporting and grouping for businesses using Spanish localization.
Original PR description
Steps to reproduce: - Install `l10n_es' - Go to accounting -> settings and load any package for the Canary Islands - Go to Accounting → Configuration → Taxes - Group by “Tax Type (Spain)” Observation: - 'Withholding' taxes should have type 'retencion' instead of 'Sujeto' Issue: - After this commit, https://github.com/odoo-dev/odoo/commit/643496b337c2edc9c56c76f72aec12021358f631 withholding taxes brings back but not set a l10n_es_type(Tax Type(Spain)), so it's default type to 'Sujeto' Solution: - Add `l10n_es_type` column in the data file and assign 'retencion' to withholding taxes. opw-5000677 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#223546
The New Zealand tax report now counts zero-rated sales only once in the Total Sales and Income section. This prevents overstated sales totals when invoices use a 0% tax rate, improving the accuracy of GST reporting.
Original PR description
**Steps to reproduce:** - Install Accounting and l10n_nz - Switch to a New Zeland company (e.g. NZ Company) - Create an invoice with a 0% tax - Go to "Accounting / Reporting / Statement Reports / Tax Report" - Select "Tax Report (NZ)" and the period of the invoice **Issue:** The amount of the invoice with the 0% tax is included twice in `Total Sales and Income` section. Cause: The formula for `Total Sales and Income` is `BOX5 + BOX6 + BOX9`. However, the value of BOX6 is already included in BOX5 as seen in its description `[BOX 6] Zero-rated supplies in Box 5`. opw-3883198 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#224095 Forward-Port-Of: odoo/odoo#171595
Removing a bank account from a customer or partner record no longer triggers an unexpected error. This helps accounting users manage customer banking details smoothly and avoids disruption during routine data cleanup.
Original PR description
Currently an error occurs when we try to remove bank accounts from a partner. **Steps to reproduce:** - Install `accountant` (with demo), Go to customers and create a new one with random name. -…
Currently an error occurs when we try to remove bank accounts from a partner.
**Steps to reproduce:**
- Install `accountant` (with demo), Go to customers and create a new one with random name.
- Under accounting tab add a new bank account with an acc number, bank and save.
- Now remove the bank account record.
**Error:**
`AttributeError: 'NoneType' object has no attribute 'origin'`
**Cause:**
- The error occurs because of the SQL query [1] returning None values in the `id2duplicates` dict, somewhat like `{1: [None]}`, this caused the browse [2] to assign `None` to the `duplicate_bank_partner_ids`.
- While recording snapshots for diff checking in onchange system the none value will be stored like`None: {display_name:{}}` and when the line [3] tries to access `id_.origin` where `id_` is None and causes the error.
**Solution:**
- Added a condition which makes sure null values are not accounted. (The Join is added to makes sure that the correct `partner_id` is fetched.)
[1]: https://github.com/odoo/odoo/blob/04ba4e4a51843701dd42a3f0243add50b3ac0c79/addons/account/models/res_partner_bank.py#L71-L85
[2]: https://github.com/odoo/odoo/blob/04ba4e4a51843701dd42a3f0243add50b3ac0c79/addons/account/models/res_partner_bank.py#L88
[3]: https://github.com/odoo/odoo/blob/04ba4e4a51843701dd42a3f0243add50b3ac0c79/addons/web/models/models.py#L1173
sentry-6748249363
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#224111
Forward-Port-Of: odoo/odoo#219455The website blog shortcut for creating a new blog post now loads correctly when the blog app is installed. This prevents users from seeing behavior that incorrectly suggests the blog feature is unavailable.
Original PR description
Sometimes, that button behaves as if the website_blog was not installed. This is because the patch made by the app to enable the button is done too late... as [1] moved the file in a lazy loaded bundle for no reason (unlike all other similar patches for new content buttons whose files it did not touch). This commit restores the file to have a similar name and location as other "new content" patches. [1]: https://github.com/odoo/odoo/commit/9fe45e2b7ddbbfd0445ffe25a859e67a316d02b2 Needed for task-2941442 runbot-226540
The website editor no longer records the temporary background grid in undo history. This prevents errors when users edit links and resize or move grid-based banner content at the same time, making page editing more reliable.
Original PR description
The background grid of the grid layout is recorded by the history. Because of this if some feature modifies the history while a grid resize or drag'n'drop is in progress, it might generate an error. This commit excludes the background grid from the history to avoid accidental history manipulations from impacting it. Steps to reproduce: - Drop a "Banner" block - Select a word - Press Ctrl+K to open the link popover - Resize the block that contains the word from the bottom => An error was produced because the grid was removed by the link popver which reverts to the history state it observed when it was opened. task-4367641
After an employee signs a contract and is assigned as the future driver of a company car or bike, the vehicle is no longer incorrectly shown as available. This helps HR and fleet teams avoid double-booking vehicles and keeps availability records accurate.
Original PR description
Issue: When a contract was signed and a future driver was assigned to a vehicle, the car still remained marked as available. Fix: Once the first signature is completed and the future driver is assigned, the vehicle is correctly marked with plan_to_change_car = False (same for the bike). Related task: 4926335. 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#218809
The project portal now sends users back to the project that actually contains the task they were editing. This avoids confusion when teams work with multiple shared projects and ensures users return to the right task list.
Original PR description
Steps to Reproduce: ------------- 1. Install project and create two projects and tasks. 2. Share both projects with edit access. 3. Edit a task from the portal view (Back to edit mode) then click the (back to tasks) button. 4. Instead of the correct project the page redirects to the another project kanban view. Issue: -------------- - When redirecting to a task from project sharing (edit mode – task form view) it redirects to a different project’s kanban view instead of the actual project. Cause: ------------- - In the portal view the URL is hardcoded with `id=1` instead of dynamically using the correct project ID. Fix: --------------- - pass the correct `project_id` in the URL instead of using a hardcoded value. The issue occurred from this PR-https://github.com/odoo/odoo/pull/174648 task-5031632 Forward-Port-Of: odoo/odoo#224092 Forward-Port-Of: odoo/odoo#224005
Applying an inventory adjustment with an accounting date could fail instead of saving the updated stock quantity. This fix restores the adjustment flow so users can update inventory quantities while keeping the correct accounting date and audit information.
Original PR description
When a user tries to apply an inventory adjustment with an accounting date, the system raises error. **Steps to produce:-** - Install the `Inventory` and `Accounting modules` with demo data. -…
When a user tries to apply an inventory adjustment with an accounting date, the system raises error. **Steps to produce:-** - Install the `Inventory` and `Accounting modules` with demo data. - `Navigate to Inventory > Reporting > Stock`. - Click the pencil icon next to a product that already has an on-hand quantity. - Set an `Accounting Date` (any date)(if not showing accounting date then add from the column dropdown). - `Modify the Quantity` and click `Apply`. **Error:-** `KeyError: 'name'` **Root cause:-** - The `_get_inventory_move_values` method in the `stock_account` module overrides the corresponding method from the base stock module. It attempts to modify the name. - However, the parent method in the stock module was changed in [commit](https://github.com/odoo/enterprise/commit/d0c1e7845feeee1c2e85a21b5d40570d051458d3), and it no longer returns a 'name' key in its result dictionary. **Solution:-** - This fix adjusts the logic in `_get_inventory_move_values` to properly set `inventory_name` with the accounted date and user information. **sentry-6791413899** --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Portal users with edit access now see the shared project's actual name and the expected back navigation in the project sharing view. This fixes a confusing header issue that made the page look generic and harder to navigate.
Original PR description
**Steps to reproduce** - Share a project with a portal user with "Edit" access rights. - With portal user, navigate to the portal project view: back arrow is missing and "Project Sharing" appears instead of project name. <img width="1450" height="894" alt="image" src="https://github.com/user-attachments/assets/05dc16fd-2255-4f90-be3e-b2e870958a6d" /> **1st issue (project name)** Caused by 1b86bd7ecf4d8751015b5056e9d48e49d68d195c removing the `params` key from context. **2nd issue (back arrow)** 939ad768b78d3b705df2589312608e9227604776 introduced a new ProjectTaskControlPanel component. opw-5036315
The website builder now correctly shows the text animation tool as active when animated text is selected, even if that text also has a highlight effect. This removes confusion for editors by making the toolbar reflect the current styling more reliably.
Original PR description
The commit e80a2a20d4ba49b51f31f8ed06a5a0d3d1fa2e6d added the text animation in the toolbar as part of the website builder refactor The tool in the toolbar was shown as active when the animated node was fully selected (or selection collapsed). But if the text inside is highlighted, extra nodes with no text are added with the highlight's svg, and these are not selected. With this commit, the comparison checks if the text content of the selection is the same as the text content of the animated span, thus empty dom nodes are ignored. Steps to reproduce: - Open website builder - Select some text (for example in the footer) - Add an animation - Add an highlight - Select the same text again - Bug: the animate text tool is not shown as active task-4367641
This fix makes an automated two-factor authentication test wait until the web client is fully ready before continuing. It reduces false test failures in validation runs, helping keep releases stable without changing customer-facing behavior.
Original PR description
Code and issue at hand are very similar to odoo/odoo#212102 so implement the same "fix" to synchronise the tour on the web client being ready, though technically the first two calls are just "wait a bit" then "wait a bit more" (wait until DOMContentLoaded, then until next frame, then until next event loop). At which point we wait until the event bus has fully connected to the server before moving on to interact with the client for real. It does seem to reliably wait sufficiently long for the issue to go away so works for me... Backport of #224066 https://runbot.odoo.com/odoo/error/181862 Forward-Port-Of: odoo/odoo#224161
Credit notes with zero-priced lines and negative quantities now export valid electronic invoice values instead of a negative zero amount. This prevents UBL files, including Romanian CIUS-RO exports, from being rejected by EDI validators.
Original PR description
**Issue description:** When creating a UBL credit note, a line with a zero unit price and a negative quantity would have its gross unit price calculated as `0.0 / <negative_qty>`. This results in a…
**Issue description:** When creating a UBL credit note, a line with a zero unit price and a negative quantity would have its gross unit price calculated as `0.0 / <negative_qty>`. This results in a negative zero `-0.0`, which is considered an invalid negative net price by some EDI validators (e.g., Romanian CIUS-RO), causing the file to be rejected. **Steps to reproduce:** 1. Create a Sales Order with two lines: one product for €100 and a second (e.g., a delivery service) for €0. 2. Create and pay a downpayment invoice for a fixed amount greater than the order total, e.g., €200. 3. Go back to the Sales Order and create a "Regular Invoice". This will generate a credit note with negative quantities on the lines. 4. Ensure the journal is configured for UBL export (e.g., CIUS-RO). 5. Post, then send the credit note and inspect the generated XML file. The zero-priced line will show `cbc:PriceAmount = '-0.0'`. opw-5000314 Forward-Port-Of: odoo/odoo#223643 Forward-Port-Of: odoo/odoo#223074
This fix makes the automated website menu editing checks more stable by ensuring pages are fully ready before test actions run. It reduces false failures in internal validation, helping teams trust release testing results without changing customer-facing behavior.
Original PR description
The `edit_menus` tour was occasionally failing on runbot due to race conditions affecting certain steps. Issue: 1. Following the [PR [1]](https://github.com/odoo/odoo/pull/198596), the tour system…
The `edit_menus` tour was occasionally failing on runbot due to race conditions affecting certain steps. Issue: 1. Following the [PR [1]](https://github.com/odoo/odoo/pull/198596), the tour system has a safeguard where steps wait for iframe readiness, determined by the `is-ready="true"` attribute on the iframe body. However, the `parentFrameIsReady` function had a bug: when called before the `is-ready` attribute was set, it defaulted to `true` instead of waiting. This caused tour steps to execute prematurely while the iframe was still loading, creating race conditions. 2. Entering edit mode causes the builder sidebar to open, triggering multiple iframe resize events. Each resize rebuilds (i.e., removes and recreates) the extra menu items dropdown (see auto_hide_menu.js [2]). The tour tried to open a link popover inside this dropdown immediately after entering edit mode. This caused a race condition where, if the step ran before all resize events had completed, the dropdown could be rebuilt mid-process, and our target element could be lost, causing the step to fail to open the popover. Fix: 1. Set `is-ready="false"` as the initial value on iframe body load. This ensures the readiness check waits for the attribute to be explicitly set to "true" when publicRoot is ready, eliminating false positives. 2. After the builder sidebar fully opens, we now wait briefly before interacting with the link in the extra menu items dropdown. This delay ensures all recalculations (triggered by iframe resizes) are complete before proceeding, avoiding race conditions. [1] - https://github.com/odoo/odoo/pull/198596 [2] - [website/static/src/js/content/auto_hide_menu.js#L92](https://github.com/odoo/odoo/blob/saas-18.4/addons/website/static/src/js/content/auto_hide_menu.js#L92) [runbot-226308](https://runbot.odoo.com/odoo/error/226308) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Incoming email fetching now avoids a timing conflict that could cause the process to fail while saving progress. This helps keep automated email retrieval running smoothly and reduces interruptions for users relying on mail synchronization.
Original PR description
The process of fetching run in a transaction t1 and for each message we do it in a transaction tm. tm commits and updates the progress for each message found on the server. t1 was started before tm and since tm changed the progress, t1 may result in a serialization error. By adding the commit, t1 commits all changes and starts a new transaction to update the progress (at that point tm is committed). --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The website builder highlight picker now previews the selected color and thickness instead of always showing a black default style. Highlights also default to the primary theme color, making the editing experience more consistent and easier for users.
Original PR description
The hightlight picker is always shown with default black color and default thickness. This commit adapts the preview to use the currently set color and thickness. It also defaults the color to primary. task-4367641
The Point of Sale app now starts correctly when the default sales preset requires a customer to be selected. This prevents cashiers from being blocked by an initialization error and helps stores open sessions more reliably.
Original PR description
Before this commit, if the POS default preset required a partner, an error would occur during initialization. opw-5023987 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#223355
The website builder's theme settings panel now opens faster by avoiding unnecessary background rendering for collapsed sections. This reduces waiting time for users customizing websites, with an estimated performance gain of about 20%.
Original PR description
The purpose of this commit is to reduce the rendering time of the theme tab. Currently, when we have a BuilderRow that contains a collapse slot, we always render it in order to know whether it contains content or not, so that we can display the collapse arrow. The collapse feature is widely used in the theme tab. This results in a lot of unnecessary calculations, because the only case that requires dynamic calculation of the collapse arrow is the BuilderOption for visibility. So we will therefore add the “observeCollapseContent” props to enable or disable the rendering of the slot in order to dynamically display the collapse arrow. This change saves approximately 20% of time. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes an automated test for home working presence status so it remains reliable across different Odoo editions. It reduces false test failures caused by visual styling differences, helping maintain confidence in HR homeworking functionality.
Original PR description
The test `Home Location (away)` was failing because the text-danger value is not the same when enterprise is installed. To avoid this kinf of erros, we will check the classes instead of the style 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
Employee skill records can now keep extra information, such as appraisal justifications, when a skill is copied or updated. This prevents important context from being lost during skill level changes.
Original PR description
Allow models that inherit the hr_individual_skill mixin to specify additional fields to be included/preserved/carried-over when writing/creating new skill records. This was already an issue in the `hr_appraisal_skill` module where the `Justification` field was not included when copying/creating new skills. As a result, the field was "erased" on every skill level change task-4984689 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The media dialog now disables the Add button while selected media is being saved. This prevents users from accidentally triggering duplicate save actions and reduces the chance of repeated media entries or unnecessary processing.
Original PR description
Problem: `this.props.save` is awaited, which might take a while to process. During that time, the user can click "Add" multiple times. Cause: Multiple clicks trigger multiple calls to the same RPC, leading to duplicate saves. Solution: Disable the "Add" button while saving to prevent multiple calls. Steps to reproduce: - Open website/shop. - Open a product page. - Add extra media to the product to open the media dialog. - Select multiple images and click "Add" multiple times. - The save is called multiple times, triggering the same RPC several times. opw-4937004 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Products used as loyalty rewards can no longer be hidden from the Point of Sale. This helps ensure loyalty programs work reliably at checkout and prevents missing reward items during sales.
Original PR description
Before this commit, a product used as a loyalty reward could be hidden in the PoS. opw-5005934 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#222451
This fix prevents login failures for databases upgraded from older versions when notification mute settings contain an older date value. It restores the proper handling of that date so user session data can load correctly.
Original PR description
[this]( https://github.com/odoo/odoo/commit/a9532d64c3f9c541f602979225a319ec89af5194#diff-f0beb94587c1e74a64245761f99c97af110a898c0da1b3b9f195b971ee284588L42-L43) commit remove the ``mute_until_dt``…
[this](
https://github.com/odoo/odoo/commit/a9532d64c3f9c541f602979225a319ec89af5194#diff-f0beb94587c1e74a64245761f99c97af110a898c0da1b3b9f195b971ee284588L42-L43) commit remove the ``mute_until_dt`` formatting from from_settings which cause json serialzation issue and not letting login in database while dumping ``session_info`` as value can still exist database are coming from older version. For handling that adding back condtion to solve the issue and handle the ``mute_until_dt`` field formatting
**Note**: This issue won't reproduce on ``18.4`` instance but if database is coming from older version ``mute_until_dt`` will have the value that will break
```py
Traceback (most recent call last):
File "<193>", line 199, in template_web_webclient_bootstrap_193
File "<193>", line 181, in template_web_webclient_bootstrap_193_content
File "<193>", line 149, in template_web_webclient_bootstrap_193_t_call_0
File "<193>", line 24, in template_web_webclient_bootstrap_193_t_set_2
File "/home/odoo/py_env/src/odoo/18.0/odoo/tools/json.py", line 57, in dumps
return _ScriptSafe(json_.dumps(*args, **kwargs))
File "/usr/lib/python3.10/json/__init__.py", line 231, in dumps
return _default_encoder.encode(obj)
File "/usr/lib/python3.10/json/encoder.py", line 199, in encode
chunks = self.iterencode(o, _one_shot=True)
File "/usr/lib/python3.10/json/encoder.py", line 257, in iterencode
return _iterencode(o, 0)
File "/usr/lib/python3.10/json/encoder.py", line 179, in default
raise TypeError(f'Object of type {o.__class__.__name__} '
TypeError: Object of type datetime is not JSON serializable
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/odoo/py_env/src/odoo/18.0/odoo/http.py", line 2666, in __call__
response = request._serve_db()
File "/home/odoo/py_env/src/odoo/18.0/odoo/http.py", line 2169, in _serve_db
return self._transactioning(
File "/home/odoo/py_env/src/odoo/18.0/odoo/http.py", line 2233, in _transactioning
return service_model.retrying(func, env=self.env)
File "/home/odoo/py_env/src/odoo/18.0/odoo/service/model.py", line 176, in retrying
result = func()
File "/home/odoo/py_env/src/odoo/18.0/odoo/http.py", line 2200, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "/home/odoo/py_env/src/odoo/18.0/odoo/http.py", line 2369, in dispatch
return self.request.registry['ir.http']._dispatch(endpoint)
File "/home/odoo/py_env/src/odoo/18.0/odoo/addons/base/models/ir_http.py", line 356, in _dispatch
result.flatten()
File "/home/odoo/py_env/src/odoo/18.0/odoo/tools/facade.py", line 83, in wrap_func
func(self._wrapped__, *args, **kwargs)
File "/home/odoo/py_env/src/odoo/18.0/odoo/http.py", line 1472, in flatten
self.response.append(self.render())
File "/home/odoo/py_env/src/odoo/18.0/odoo/http.py", line 1464, in render
return request.env["ir.ui.view"]._render_template(self.template, self.qcontext)
File "/home/odoo/py_env/src/odoo/18.0/odoo/addons/base/models/ir_ui_view.py", line 2463, in _render_template
return self.env['ir.qweb']._render(template, values)
File "/home/odoo/py_env/src/odoo/18.0/odoo/addons/base/models/ir_qweb.py", line 623, in _render
result = ''.join(rendering)
File "<193>", line 207, in template_web_webclient_bootstrap_193
odoo.addons.base.models.ir_qweb.QWebException: Error while render the template
TypeError: Object of type datetime is not JSON serializable
Template: web.webclient_bootstrap
Path: /t/t/t[1]/script/t
Node: <t t-out="json.dumps(session_info)"/>
```
opw - 5016301
upg - 3095362
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prDutch e-invoices now use the expected discount reason text instead of a reason code on invoice lines. This prevents validation warnings under Dutch NLCIUS rules and helps invoices process more smoothly.
Original PR description
NLCIUS rule BR-NL-32 triggers a warning if the AllowanceChargeReasonCode rather than the AllowanceChargeReason is present on an invoice line AllowanceCharge. We don't handle this correctly at the moment for discounts, because in that case the UBL 2.0 builder adds an reason code but not a reason. This commit ensures that the reason rather than the reason code is specified in NLCIUS in the case of a discount. opw-4997704 Forward-Port-Of: odoo/odoo#223072
This change updates an automated Point of Sale test so it handles page unloads consistently. It helps reduce unpredictable test failures, supporting more reliable releases without changing the user-facing Point of Sale experience.
Original PR description
Use expectUnloadPage key in tour to fix undeterministic behavior. 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#224176
This update brings Odoo Spreadsheet to the latest 18.4 version and fixes several user-facing issues. Users should see more reliable Excel copy-paste behavior, correct chart exports, and cleaner menu alignment in the spreadsheet interface.
Original PR description
### Contains the following commits: https://github.com/odoo/o-spreadsheet/commit/746217ad6 [REL] 18.4.8 [Task: 0](https://www.odoo.com/odoo/2328/tasks/0)…
### Contains the following commits: https://github.com/odoo/o-spreadsheet/commit/746217ad6 [REL] 18.4.8 [Task: 0](https://www.odoo.com/odoo/2328/tasks/0) https://github.com/odoo/o-spreadsheet/commit/eaa43f6de [FIX] xlsx: correctly export aggregated charts [Task: 4954426](https://www.odoo.com/odoo/2328/tasks/4954426) https://github.com/odoo/o-spreadsheet/commit/dd5bb2738 [FIX] Clipboard: clear useless function argument [](https://www.odoo.com/odoo/2328/tasks/) https://github.com/odoo/o-spreadsheet/commit/5a7c6fbd7 [FIX] clipboard: fix copy-paste from Excel [Task: 4730469](https://www.odoo.com/odoo/2328/tasks/4730469) https://github.com/odoo/o-spreadsheet/commit/157d55c76 [FIX] menu: Fix menu item alignment [Task: 5028721](https://www.odoo.com/odoo/2328/tasks/5028721) https://github.com/odoo/o-spreadsheet/commit/87e875b60 [FIX] Figure: icon of the menu item is not vertically aligned [Task: 4992687](https://www.odoo.com/odoo/2328/tasks/4992687) Co-authored-by: Anthony Hendrickx (anhe) <anhe@odoo.com> Co-authored-by: Alexis Lacroix (laa) <laa@odoo.com> Co-authored-by: Lucas Lefèvre (lul) <lul@odoo.com> Co-authored-by: Dhrutik Patel (dhrp) <dhrp@odoo.com> Co-authored-by: Adrien Minne (adrm) <adrm@odoo.com> Co-authored-by: Ronak Mukeshbhai Bharadiya <rmbh@odoo.com> Co-authored-by: Florian Damhaut (flda) <flda@odoo.com> Co-authored-by: Rémi Rahir (rar) <rar@odoo.com> Co-authored-by: Pierre Rousseau (pro) <pro@odoo.com> Co-authored-by: Vincent Schippefilt (vsc) <vsc@odoo.com>
This fix makes an automated Point of Sale test wait until menu buttons are ready before selecting them. It reduces false build failures caused by timing issues, helping keep development and release checks stable.
Original PR description
steps to reproduce: 1. in multi enterprise 2. run the tour `test_02_others` added a wait step for the menu buttons before clicking the menu button in the `chrome_util.js` file. build_error-229618 Forward-Port-Of: odoo/odoo#217939
Point of Sale now handles product searches correctly when the system is offline. Instead of showing an unexpected crash, users see the expected connection error, making offline behavior clearer and more stable.
Original PR description
- Fix issue that was causing a traceback when searching for products in offline mode. Now when we search a product in offline mode, we get the `ConnectionLostError` as before instead of a traceback. task-id: 5008058 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#222761
This update fixes an internal website test that could fail after a system component refresh during module upgrades. It helps keep automated checks reliable, reducing false failures during development and release validation.
Original PR description
Since [1] the `test_02_copy_ids_views_unlink_on_module_update` standalone test fails because it cannot find the `is_seo_optimized` field. This happens because the `env`'s registry is changed when `button_immediate_upgrade` is called: the types of the used records do not belong to the correct registry after the first call. This commit re-obtains the records used in the second part of the test to avoid this issue. [1]: https://github.com/odoo/odoo/commit/7f36a94a548f728aa89feb1a4facd59c91fc47bf task-4422810 runbot-227670
The Belgian payroll SD Worx export now works with the updated employee version model in saas-18.4. This prevents an error when generating the export file, helping payroll teams complete their reporting workflow reliably.
Original PR description
#### Steps to Reproduce Payroll -> Reporting -> Export Work Entries to SDWorx -> Generate Export File #### Issue In saas-18.4, contracts have been merged into employee versions (`hr.version`) and the contract states (open/close) were removed ([REF] hr_contract: Merge contracts into versioned employee model). The method `_get_versions_with_contract_overlap_with_period` no longer supports the `states` keyword. Passing it caused a traceback when generating the SD Worx export. #### Fix This commit removes the argument to ensure compatibility with the new versioned model. task-5022173
This update adds test coverage to ensure bank statement reconciliation keeps working when no payment account is configured. It helps prevent regressions in accounting workflows that could disrupt finance teams reconciling bank statements.
Original PR description
Add a test to previous fix: https://github.com/odoo/enterprise/commit/582e3ee22cba404ff38782534e76569bc93a44ef opw-5039931 opw-5039807 Forward-Port-Of: odoo/enterprise#93182
This fix prevents an error when refunding Point of Sale orders that include a global discount line under the Mexican localization. Businesses can now process these refunds from the back end without interruption, improving reliability for store operations.
Original PR description
**Steps to reproduce:** ``` - Install PoS mexican localization - Activate PoS setting Global Discounts - Navigate to PoS and create an order with a discount line - Go to back end and try to refund this order - Notice an error pops-up ``` **Cause:** Bad fw-port In the original commit `json.lines` is an array and accessing index "2" of the array was not a problem (https://github.com/odoo/enterprise/pull/84331/files#diff-63a117ed6751a8aae4fcb11d867177f5d0feb78cc1e2f3461f425babc10b5016R15) From 18.0 we are accessing the record `currentOrder` itself and `currentOrder.lines` is an PosOrderline object which doesn't have a property named "2". **Fix:** Remove index access `[2]` opw-4899501 Forward-Port-Of: odoo/enterprise#93042 Forward-Port-Of: odoo/enterprise#90410
This fix prevents the Point of Sale from showing an error when an order is unavailable or has not been loaded. It helps keep payment settlement workflows stable and avoids disruptions for staff using POS.
Original PR description
Before this commit, accessing the order amount caused an error if the order was not defined. opw-5027426 Forward-Port-Of: odoo/enterprise#92928 Forward-Port-Of: odoo/enterprise#92736
This fix ensures negative Swiss payroll lines are posted to the correct opposite accounts. It helps keep payroll accounting entries accurate, reducing manual corrections and improving financial reporting reliability.
Original PR description
…r 2050 Invert accounts for negative payslip line Forward-Port-Of: odoo/enterprise#93074
The Belgian POS Blackbox integration now shows clearer messages when the device cable is faulty or the Blackbox sends an invalid response. This helps store staff understand connection problems faster and supports better issue logging for troubleshooting.
Original PR description
This PR adds some explicit messages to invalid responsed from the Blackbox. We will now log and inform the user when the cable is malfunctioning or the blackbox isn't responding with a valid message Forward-Port-Of: odoo/enterprise#90570 Forward-Port-Of: odoo/enterprise#90436
This update fixes an automated guided tour used in the Field Service reporting area so it waits for the correct button before continuing. This helps keep quality checks reliable and reduces false failures during testing, with no expected impact on day-to-day users.
Original PR description
In this commit, we fix the tour industry_fsm_tour by removing "body:not(.modal-open) nav.o_main_navbar" (this trigger is always true) from trigger to let only button[name="action_generate_new_template"]. Forward-Port-Of: odoo/enterprise#93169 Forward-Port-Of: odoo/enterprise#91771
When an employee signs a salary contract and is assigned as a future driver, the related car or bike is no longer incorrectly shown as available. This helps HR and fleet teams avoid double-booking vehicles and keeps fleet planning accurate.
Original PR description
Issue: When a contract was signed and a future driver was assigned to a vehicle, the car still remained marked as available. Fix: Once the first signature is completed and the future driver is assigned, the vehicle is correctly marked with plan_to_change_car = False (the same applies to the bike). Related task: 4926335. Forward-Port-Of: odoo/enterprise#89774
This fix prevents appointment video call links from failing when several calendar events are processed at once. It helps ensure users are redirected correctly to their video appointments without interruption.
Original PR description
When computing `videocall_redirection`, the method `get_base_url()` was called directly on a recordset containing multiple `calendar.event` records. Since `get_base_url()` expects a singleton, this raised the error: Traceback: --- `ValueError: Expected singleton or no record: calendar.event(4, 6, 1, 5)` This commit ensures the computation is done per record, avoiding the singleton issue and allowing correct videocall redirection values to be set on multiple events. Reference review: https://github.com/odoo/enterprise/pull/53569#discussion_r1543135425 sentry-6819406171 Forward-Port-Of: odoo/enterprise#92717
Employee appraisal skill records now keep extra information, such as justification notes, when a skill level is updated or copied. This prevents important context from being accidentally erased during normal appraisal updates.
Original PR description
Allow models that inherit the hr_individual_skill mixin to specify additional fields to be included/preserved/carried-over when writing/creating new skill records. This was already an issue in the `hr_appraisal_skill` module where the `Justification` field was not included when copying/creating new skills. As a result, the field was "erased" on every skill level change task-4984689
This fixes an issue where changing a product image layout in the website editor could stop the Add to cart button from working for rental and subscription products. The checkout form is now found correctly even when the page layout places the button outside its usual position, helping shoppers complete purchases without interruption.
Original PR description
## Version saas-18.4+ ## Steps to reproduce - Open the shop; - Select any product; - Open the Editor: - Select the product's main image; - Change the image width to either `100 percent` or `None`,…
## Version
saas-18.4+
## Steps to reproduce
- Open the shop;
- Select any product;
- Open the Editor:
- Select the product's main image;
- Change the image width to either `100 percent` or `None`, then save;
- Click on `Add to cart`.
## Issue
Commit eac892a4ad7373d18f954afbbcd2f1213ac5f281 introduced a UI update that reorganizes the layout of the product configurator, placing the `Add to cart` button next to the form rather than below it.
Although the button remains inside the form in the original template, using the Editor to adjust the layout can result in the button being saved outside the `<form>` element in the final DOM.
This breaks the logic that relies on `closest('form')` to locate the surrounding form, since the button is no longer a descendant of the form element.
## Solution
Find the first product form relative to the button, since it may be a sibling rather than an ancestor in the DOM.
opw-4942986
See also:
- https://github.com/odoo/odoo/pull/218902A missing setup field was added to Point of Sale enterprise tests so they run correctly when the module is installed. This helps keep automated checks reliable and prevents false build failures without changing customer-facing behavior.
Original PR description
steps to reproduce: 1. install pos_enterprise 2. run the test `test_should_not_affect_other_pos_config` or `test_is_header_or_footer_to_false` this commit adds the missing_field `account_tax_return_journal_id` to the test build_error-230301 Forward-Port-Of: odoo/enterprise#90995
Document link previews now open the correct video when users preview multiple YouTube links. This prevents confusion by ensuring each saved link shows its own preview rather than reusing the most recently added one.
Original PR description
**Steps to reproduce:** 1. Go to Documents > Click ⬇ beside Upload > Add a Link 2. Add two different YouTube video URLs with above steps 3. Preview the first link, then the second **Issue:** Previewing individual YouTube links always displays the preview of the *last* added video, regardless of which one was clicked. **Cause:** When a document has no `attachment_id`, the preview fallback logic defaults incorrectly, causing all documents to share the same preview source. **Solution:** Updated `getRecordAttachment` to prioritize `attachment_id` but gracefully fallback to `rec.resId` and `rec.data.name` when missing. This ensures document preview works even when the record has no linked attachment. opw-4906808 Forward-Port-Of: odoo/enterprise#92491 Forward-Port-Of: odoo/enterprise#90388
This fixes a checkout issue where changing a product image layout in the website editor could make the Add to Cart and wishlist buttons stop working. The storefront now finds the correct product form even when the page layout places the button outside its usual position, helping customers complete purchases reliably.
Original PR description
## Version saas-18.4+ ## Steps to reproduce - Open the shop; - Select any product; - Open the Editor: - Select the product's main image; - Change the image width to either `100 percent` or `None`,…
## Version
saas-18.4+
## Steps to reproduce
- Open the shop;
- Select any product;
- Open the Editor:
- Select the product's main image;
- Change the image width to either `100 percent` or `None`, then save;
- Click on `Add to cart`.
## Issue
Commit bbb2d98d9ab97ce729d59b9858b63daccf5434e2 introduced a UI update that reorganizes the layout of the product configurator, placing the `Add to cart` button next to the form rather than below it.
Although the button remains inside the form in the original template, using the Editor to adjust the layout can result in the button being saved outside the `<form>` element in the final DOM.
This breaks the logic that relies on `closest('form')` to locate the surrounding form, since the button is no longer a descendant of the form element.
## Solution
Find the first product form relative to the button, since it may be a sibling rather than an ancestor in the DOM.
opw-4942986
See also:
- https://github.com/odoo/enterprise/pull/90631This fix prevents certain IoT-connected printers from disappearing when their connection method briefly changes during availability checks. Businesses can keep printing reliably because the system recognizes the printer by its IP address and preserves the existing print queue entry.
Original PR description
Some printers (`lpd...PASSTHRU`s for example) tend to disappear when checking available printers list. They are often switching between one time `lpd...PASSTHRU` and the second time `socket...` protocols. As we get ip addresses for printers, we now check if the new protocol still correspond to the same printer, and if so, we keep the old one. As the printer will still be in the cups queue list, it will still be able to print through it.
This fix prevents users from seeing an error when they complete a scheduled activity linked to an approval rule that has since been deleted. It keeps the activity workflow stable in Web Studio by safely handling cases where no approval rules remain.
Original PR description
An error occurs when a user attempts to mark a scheduled activity as done after the associated approval rule has been deleted. **Steps to Reproduce:** 1) Install Sales and Web Studio modules. 2) Log…
An error occurs when a user attempts to mark a scheduled activity as done after the associated approval rule has been deleted. **Steps to Reproduce:** 1) Install Sales and Web Studio modules. 2) Log in as Admin and use Studio to add an approval rule to the Sale Order’s Preview button. >- Set Allowed Group to Access Rights. >- Set Responsible User to Mitchell Admin. 3) In the Incognito Tab, login as Demo, open the same sale order and click on preview to create activity in chatter. 4) Delete the Approval Rule in the original tab. 5) Switch back to Demo and click Mark Done under Planned Activity in chatter. **Error:** `SyntaxError: syntax error at or near ')'` `LINE 1: SELECT id FROM studio_approval_rule WHERE id IN () FOR UPDAT. ^` **Root Cause:** The error occurs because the SQL query at [1] includes an empty tuple of rule IDs `(all_rule_ids)`. An empty `IN ()` clause in SQL results in a syntax error. [1]- https://github.com/odoo/enterprise/blob/7ea45724e7689a0df11d20ace9c562788f5d19e3/web_studio/models/studio_approval.py#L366 **Solution:** This commit avoids the error by ensuring that the SQL query only runs when `all_rule_ids` is not empty. sentry-6306636466 Forward-Port-Of: odoo/enterprise#86982