Daily updates from Odoo
Wednesday, April 1, 2026
54 changes · 19.0
Enhancements to existing features
This update improves how users can manage Point of Sale transactions in Jordan's electronic invoicing system. Previously, users could get stuck with demo transactions that couldn't be modified or deleted. Now, the system is more flexible—users can change transaction states and either delete demo transactions or move them to production, giving them better control over their POS operations.
Original PR description
Before this commit:
- The fields `l10n_jo_edi_pos_{state, return_reason}` were readonly when
`l10n_jo_edi_pos_qr` was set. However, we did not take into account the fact
that `pos.order` cannot be reset once `done/paid/invoiced`; thereby blocking
the user with a demo transaction forever without any alternative.
After this commit:
- The fields `l10n_jo_edi_pos_{state, return_reason}` are readonly when
`l10n_jo_edi_pos_qr and l10n_jo_edi_state == 'sent'`. Additionally, an
onchange is introduced on `l10n_jo_edi_pos_state` to clear
`l10n_jo_edi_pos_qr`. This gives back flexibility to the user to either delete
the demo mode transaction or sync them to the production endpoint.
task-5958427
Forward-Port-Of: odoo/odoo#250808This update improves how charges are handled when importing UBL invoices. Previously, charges on invoice lines were creating separate line items, which cluttered invoices. Now charges are automatically combined into the unit price of the original line, resulting in cleaner, more consolidated invoices that are easier to read and process.
Original PR description
Before this commit: A charge in an InvoiceLine was creating a new invoice line with the amount of the charge. After this commit: The charge is added in the price unit of the original line --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#255189 Forward-Port-Of: odoo/odoo#254111
This update enhances the product import feature to automatically group product variants under a single template based on matching product names in your import file. You can now import and manage both product templates and their variants from a single Excel file, with automatic creation of product attributes and values. This streamlines bulk product management and reduces manual data entry.
Original PR description
Backport: - https://github.com/odoo/odoo/pull/236489 - https://github.com/odoo/odoo/pull/249086 - https://github.com/odoo/odoo/pull/255497 Task: 6041826 Implemented a new product import system that…
Backport: - https://github.com/odoo/odoo/pull/236489 - https://github.com/odoo/odoo/pull/249086 - https://github.com/odoo/odoo/pull/255497 Task: 6041826 Implemented a new product import system that supports grouping product variants under a single product template based on the product name. This new feature allows the creation and update of product templates and their variants from a single Excel file. Grouping Logic: - Variants are grouped onto a product template if they share the same product name in the import file. Attribute Value Handling: - Attribute values are provided in a structured format: `attribute name:value name`, separated by commas (e.g., Color:Red, Size:M). - Attributes and their values are automatically created if they do not already exist in the system. External ID Handling: - If a product/variant has attribute values, the external ID is expected to be a `product.product` External ID. - Otherwise (if it's a simple product or the template record), the external ID is expected to be a `product.template` External ID. Example (.csv): External ID;Internal Reference;Name;Product Type;Barcode;Sales Price;Weight;Sales Description;Attribute values product_template_1;;T-shirt Big Bang;Goods;;110;;T-shirt with Big Bang Theme; product_product_1;T-SHIRT-BB-1;T-shirt Big Bang;;code-b-1;;0,12;;Color:Red,Size:S product_product_2;T-SHIRT-BB-2;T-shirt Big Bang;;code-b-2;;0,13;;Color:Red,Size:M product_product_3;T-SHIRT-BB-3;T-shirt Big Bang;;;115;0,14;;Color:Blue,Size:L product_product_4;T-SHIRT-BB-4;T-shirt Big Bang;;;125;0,15;;Size:M,Color:Red product_product_5;T-SHIRT-SW-RS;T-shirt Stars Wars;Goods;code-1;100;0,12;T-shirt with Stars Wars Theme;Color:Red,Size:S product_product_6;T-SHIRT-SW-RM;T-shirt Stars Wars;Goods;code-2;100;0,13;T-shirt with Stars Wars Theme;Color:Red,Size:M product_product_7;T-SHIRT-SW-RL;T-shirt Stars Wars;Goods;code-3;100;0,14;T-shirt with Stars Wars Theme;Color:Red,Size:L product_product_8;T-SHIRT-SW-BS;T-shirt Stars Wars;Goods;code-5;110;0,12;T-shirt with Stars Wars Theme;Color:Blue,Size:S product_product_9;T-SHIRT-SW-BM;T-shirt Stars Wars;Goods;code-6;110;0,13;T-shirt with Stars Wars Theme;Color:Blue,Size:M product_product_10;T-SHIRT-SW-BL;T-shirt Stars Wars;Goods;code-7;110;0,14;T-shirt with Stars Wars Theme;Color:Blue,Size:L
Resolved issues and error corrections
This update corrects a bug where payroll-related planned actions (Dimona and Part Time registrations) were being triggered for all new employees regardless of their country. The fix ensures these actions now only apply to employees with Belgian contracts, preventing unnecessary processing for non-Belgian staff.
Original PR description
Previously, planned actions (Dimona/Part Time) were triggered for all new employees with a contract start date, regardless of country. Now, the trigger is filtered to only apply to Belgian contracts. task-5942339 Forward-Port-Of: odoo/enterprise#111788
This update fixes an issue with how tax closing journals are configured in the accounting system. The fix ensures that tax closing journals are properly set up when creating or updating company chart templates, which helps prevent errors during tax period closing processes.
Fixed an issue preventing Field Service users from adding customers to tasks. When users attempted to assign a customer to a task, the system was blocking the action due to insufficient permissions. The fix allows Field Service users to complete this common workflow while maintaining proper security controls through permission-based restrictions.
Original PR description
Steps to Reproduce: - 1. Log in with a user having only "Field Service > User" access. 2. Create a new task in an field service project. 3. Add a customer on the task. 4. Access error is raised. Issue: - - Field service users could not create a task with a customer. - An access error appeared during task creation. Cause: - - When a customer was added to the task, the partner_phone inverse method was triggered. - This method attempted to write on the partner record. Solution: - - Used sudo() in the inverse method to update the partner phone securely, bypassing restricted access. task-5039657 Forward-Port-Of: odoo/enterprise#112549 Forward-Port-Of: odoo/enterprise#93969
This fix resolves an issue where the "Load more" line in financial reports was being incorrectly hidden when the "Hide lines at 0" option was enabled. The update ensures that "Load more" lines remain visible even when zero-value lines are hidden, allowing users to access additional data as needed.
Original PR description
When activating the 'Hide if 0' option, the 'Load more' line is hidden. Fix: Filtering out the lines with empty columns (Load more lines) from the zero lines. Steps: - Open GL (occurs with other reports as well), and open configuration for this report - Set Load more limit to 1, and hide if zero to optional - Go back to GL report and select the 'Hide lines at 0' option -> Load more lines are hidden as long as the zero lines opw-5953725 Forward-Port-Of: odoo/enterprise#109380
Demo Stripe accounts were staying in a restricted state and couldn't be automatically verified due to a document requirement issue. This fix enables users to test the Stripe payment feature in demo mode by adjusting how account verification requirements are handled, allowing the feature to be properly tested before the permanent solution is implemented.
Original PR description
Step to reproduce: - Click on Connect (demo) - The accounts stay Restricted (even after 5m) This is due to the requirement `company.verification.document` which is present as a pending_verification even when no document is given. Giving it a document such as `file_identity_document_success` which should "marks that document requirement as satisfied" also doesn't work. A work-around is to set the business type to individual since they dont have this requirement. This is a temporary fix, as we want to keep a flow similar to what would have been done in reality. But this is preventing users from testing the feature in 19.0 up to master.
This fix resolves an error that occurred when users tried to undo a rescheduled calendar event in the Resource Booking feature. The system was attempting to save invalid data to the database, causing the undo operation to fail. With this fix, users can now successfully undo calendar event changes without encountering errors.
Original PR description
Currently, an error occurs when user tries to undo a calendar event. Steps to replicate: - Install `appointment` with demo data. - Navigate to `Appointments > Schedule > Resource Booking`. - Drag to…
Currently, an error occurs when user tries to undo a calendar event. Steps to replicate: - Install `appointment` with demo data. - Navigate to `Appointments > Schedule > Resource Booking`. - Drag to create a calendar event. - Reschedule the event to a later time (drag and drop forward). - Click Undo on the notification that appears. Error: `ValueError: Invalid field 'originId' in 'calendar.event'` `KeyError: 'originId'` Cause: - The key `originId` was patched in the `getschedule()` [1] and later when user tried to undo the calendar event, the [fallbackschedule] included the key `originId` and made an [orm] call with it. - The [line] tries to write the data into the database where `originId` field doesnt exist and causes the error to occur. Solution: - Remove the `originId` key from `fallbackdata` before the orm call. [1]: https://github.com/odoo/enterprise/blob/e61eef059983bb0cdec4f156fb9283198b379863/appointment/static/src/views/gantt/gantt_renderer.js#L110-L116 [fallbackschedule]: https://github.com/odoo/enterprise/blob/e61eef059983bb0cdec4f156fb9283198b379863/web_gantt/static/src/gantt_renderer.js#L1425 [orm]: https://github.com/odoo/enterprise/blob/e61eef059983bb0cdec4f156fb9283198b379863/web_gantt/static/src/gantt_renderer.js#L1473-L1477 [line]: https://github.com/odoo/enterprise/blob/e61eef059983bb0cdec4f156fb9283198b379863/web_gantt/models/models.py#L248 sentry-7020359653 Forward-Port-Of: odoo/enterprise#100570
The barcode scanning app was crashing when users tried to confirm quantities for archived products. This fix ensures archived products are included in search results, allowing users to successfully add and confirm quantities without errors, maintaining consistent behavior across the app.
Original PR description
Currently, when a user confirms the quantity of an archived product using the product selector in the barcode app, a traceback error occurs. ## Steps to replicate: - Install Inventory - Go to…
Currently, when a user confirms the quantity of an archived product using the product selector in the barcode app, a traceback error occurs. ## Steps to replicate: - Install Inventory - Go to Settings and enable Multi-Step Routes > Set Warehouse Routes. - Configure 2 steps for outgoing shipments. - Go to Inventory and create a new delivery with - **Source Location:** WH/Stock - **Product:** [E-COM10] Pedal Bin with demand 1 - Mark as Todo then Archive the Pedal Bin product. - Open that delivery in barcode app - Pencil icon > +1 > Confirm ## Observed behavior: TypeError: Cannot read properties of undefined (reading 'qty_available') ## Root cause: After this [commit], an override was added to the product selector. As a result, when [2] calls the `search_read` method, it only retrieves non-archived products Consequently, if the result is an empty array, attempting to access `qty_available` causes the type error mentioned above. ## Solution: Adding` active_test = false `to the context ensures that archived products are included in search results. This prevents empty results and avoids the error. It also allows quantities to be added and confirmed,maintaining the same behavior as when using the increment button followed by validation, ensuring consistency. [commit]: https://github.com/odoo/enterprise/commit/6aa814f59f8641d7b57af160e38b50d5bdfc8a97 [2]- https://github.com/odoo/enterprise/blob/e13b44b353e734a6533f7d627ed69b6e7b033ee2/stock_barcode/static/src/js/stock_barcode_sml_form.js#L40-L45 opw-5980428 Forward-Port-Of: odoo/enterprise#112495 Forward-Port-Of: odoo/enterprise#109204
This fix corrects how shifts are split when using the daily view in the planning schedule. Previously, splitting a shift within a single day would incorrectly snap the resulting shifts to standard working hours (8am-5pm), creating duplicate time entries outside the original shift. Now, shifts split within a day are correctly divided at the exact requested time without adding extra hours.
Original PR description
Since odoo/enterprise#69963, splitting a shift in Gantt view snaps the resulting shifts to the standard working hours (e.g., 08:00 to 17:00). This behavior makes sense when splitting a multi-day shift across a day off, where we want to generate a full working day for the day off as well. However, when splitting a shift within a single day (day scale), this behavior is not wanted, otherwise creating two shifts as follows: 1. A shift from [Original Start] to 5pm 2. A shift from 8am to [Original End] Clearly, the shift is duplicated with the wrong timeframes and adding time outside the original shift's hours. This commits ensures that, when splitting a shift in hours (i.e., when using `day` view scale), the shift is appropriately split at the time requested. For instance: 1. A shift from [Original Start] to [Split Time] 2. A shift from [Split Time] to [Original End] task-5387243 Forward-Port-Of: odoo/enterprise#105991
This fix resolves an issue where uploading empty XML files would cause the system to crash with an error. Users can now upload empty XML files without encountering errors, and the system will gracefully skip PDF extraction when file content is missing. This improves the reliability of the document upload process.
Original PR description
Currently an error is generated and the file is not generated when the user uploads an empty XML file (e.g., ref file [1]). Error: `AttributeError: 'bool' object has no attribute 'decode'` This error occurs because the uploaded file contains no raw data. As a result, the system fails to retrieve the file content during PDF extraction from the XML at line [2]. This commit fixes the issue by skipping PDF extraction from the XML when the document has no raw data. The process now returns False early if the document contains no raw content. [1]: https://drive.google.com/file/d/1hRbgEsTL-iWhiAO245z_10HRH6nh3rUQ/view?usp=sharing [2]: https://github.com/odoo/enterprise/blob/00e2e658312eda2d3dae04eb966fd538972e5243/documents_account/models/documents_document.py#L52 sentry-7173452999 Forward-Port-Of: odoo/enterprise#103801
This fix resolves a system error that occurred when creating employee contracts with work schedules that have zero working hours. Previously, the system would crash when trying to calculate hourly wages in these cases. Now the system handles this scenario gracefully, allowing users to create and manage contracts without interruption.
Original PR description
When a working schedule has 0 working hours, creating a contract raises a traceback during hourly wage computation. Steps to reproduce the error: - Install ``l10n_au_hr_payroll`` module - Switch to ``My Australian Company`` - Create a working schedule without any working hours - Create an employee and assign this working schedule > Save - Click on Contracts smart button Traceback: ```py ZeroDivisionError: float division by zero ``` https://github.com/odoo/enterprise/blob/bd746aa43f549c4f7813a849e00447b55e084f21/l10n_au_hr_payroll/models/hr_contract.py#L113-L115 The hourly wage is computed using the working schedule’s hours per day. When this value is 0, it results in the above traceback. sentry-7355577930 Forward-Port-Of: odoo/enterprise#112450 Forward-Port-Of: odoo/enterprise#111629
Fixed an issue where scanning a barcode with a different serial number than the reserved one would incorrectly use the original reserved serial number instead of creating a new lot. Now when processing batches in barcode mode, if a scanned serial number doesn't match the reserved one, the system correctly creates a new lot as configured, ensuring accurate inventory tracking.
Original PR description
Issue ----- When processing batches in barcode, scanning a BC with a different SN than the reserved one does not lead to creating a new lot in stock. The reserved one is still the one getting taken…
Issue
-----
When processing batches in barcode, scanning a BC with a different SN than the reserved one does not lead to creating a new lot in stock. The reserved one is still the one getting taken regardless of setting.
Steps to reproduce
-----
- Enable GS1 nomenclature, lots & batches
- Go to Inventory > Configuration > Operation Types > Delivery Orders
- Enable Lots/Serial Numbers > Create New
- Create a product
- Barcode 23456789012344
- Tracked by SN
- 1 in stock (SN 1234)
- Create a delivery for the product and add it to a batch
- Open the batch in barcode
- Scan 012345678901234410BATCHSN1
- Confirm the delviery
- Go back to the picking and see the lines' details
> The line used the reserved SN
Cause
-----
The existing line gets matched in `_findLine`
https://github.com/odoo/enterprise/blob/45d3a537c3b2eaccee425d959e89d26229e376cd/stock_barcode/static/src/models/barcode_model.js#L1085
because none of the conditions before
https://github.com/odoo/enterprise/blob/45d3a537c3b2eaccee425d959e89d26229e376cd/stock_barcode/static/src/models/barcode_model.js#L1402
get matched. This is unexpected but necessary for batches, as it ensures barcode correctly swaps to the correct picking in the batch. If the line was not matched we would be creating a new line in the same picking than the last scanned line, regardless of which picking the reservation is made in.
Because a line is matched, we have to force its' `lot_id` to `false` so that the new one gets created (`lot_name` is used for display but `lot_id` takes precedence).
-----
Ticket:
opw-5216921
Forward-Port-Of: odoo/enterprise#112210
Forward-Port-Of: odoo/enterprise#109671This fix resolves an issue where shifts in the Planning module remained in draft status even after a rental order was created and confirmed. The shift status now correctly updates to published immediately when a new rental order is created, ensuring the Planning view accurately reflects the current state of shifts and maintaining consistency with other order creation methods.
Original PR description
**Issue 1** **Steps to Reproduce:** Create a shift in Planning. Click New Order. Save and confirm the rental order. Check the shift in Planning it is still in draft. **Issue:** The shift stays in draft even after the rental order is confirmed. **Cause** When creating a rental order from a shift, the shift is not marked as planned. It only gets linked to the order after saving, so it never updates its status. **Fix:** Mark the shift as published when confirming a new rental order. This makes the shift show the correct status right away and keeps it consistent with the “Add to Last Order” button. task-5075839 Forward-Port-Of: odoo/enterprise#99642
This update corrects how the Spanish tax report (Form 347) calculates and displays partner transaction amounts. Previously, negative amounts were incorrectly hidden from the report, and insurance operations were only partially tracked. Now the report correctly shows all partners with significant transactions regardless of whether amounts are positive or negative, and properly separates insurance sales and purchases into distinct sections.
Original PR description
Before this PR: - Partners were only shown if their total was positive and above 3,005.06 €. Negative totals were hidden, even if they were lower than -3,005.06 €. - Insurance operations only took Purchase journal amounts into account. Amounts from Sales journals were ignored, and there was no distinction between the two types of operations. After this PR: - The report now uses the absolute value of the total. Partners with amounts exceeding 3,005.06 €, whether positive or negative, are now shown correctly. - Insurance operations are now divided into two distinct sections: Sales and Purchases. Amounts from both Sales and Purchase journals are now correctly taken into account and reported in their respective sections. task-5214023 Forward-Port-Of: odoo/enterprise#112136 Forward-Port-Of: odoo/enterprise#100413
This fix corrects how payment installments are ordered in Peru's electronic invoicing system (EDI). Previously, when invoices had multiple payment installments with different due dates, they could appear in the wrong order in the electronic document if they weren't created in chronological sequence. Now installments are automatically sorted by their due date, ensuring the correct payment schedule is always transmitted to tax authorities.
Original PR description
**Steps to reproduce:**
* Install `l10n_pe_edi`.
* Set SUNAT as the signature provider.
* Create a customer invoice.
* Select a payment term with multiple installments (e.g. 50% (15 days) / 30% (10 days) / 20% (5 days)).
* Confirm the invoice and generate the EDI standard UBL document.
**Observed behavior:**
* The XML `<cac:PaymentTerms>` instalment nodes (Cuota001, Cuota002, etc.) are ordered according to the database insertion order of the receivable lines.
* If the payment term lines are created in a non-chronological order, the installments in the XML mix up the `Cuota` ID, amount, and `PaymentDueDate`.
**Cause:**
* `_add_invoice_payment_terms_nodes` iterates over `invoice.line_ids` to generate the installments, but does not sort the receivable account lines by their `date_maturity`.
**Fix:**
* Explicitly call `.sorted('date_maturity')` on the receivable lines before generating the `invoice_date_due_vals_list`.
opw-6035589This fix ensures that when you change the salesperson assigned to a subscription, the update automatically applies to all contact records associated with that company, not just the main company record. This keeps customer information consistent across the system and eliminates the need for manual updates to individual contacts.
Original PR description
Before this commit, changing the salesperson on a subscription only updated the company partner, leaving child contacts with outdated salesperson info. After this commit, updating the subscription's salesperson also updates all child contacts of the company, ensuring consistency across the portal and reducing manual work. An unit test was added to ensure this behavior. task-5917271 Forward-Port-Of: odoo/enterprise#111499 Forward-Port-Of: odoo/enterprise#108339
Subscription products with zero price on the product form but priced through pricelists can now be added to the cart when the "Prevent Sale of Zero Priced Product" setting is enabled. The fix ensures the system correctly checks pricing information from subscription plans when validating whether a product can be purchased.
Original PR description
A subscription product that has a price of zero on the product form and the price is set on the pricelist instead cannot be added to the cart when the `Prevent Sale of Zero Priced Product` setting is…
A subscription product that has a price of zero on the product form and the price is set on the pricelist instead cannot be added to the cart when the `Prevent Sale of Zero Priced Product` setting is enabled Steps to reproduce: 1. Install eCommerce and Subscriptions 2. Go to Settings and enable `Prevent Sale of Zero Priced Product` 3. Go to Subscriptions > Products and create a new product "subscription" with Sales Price $0.00 and publish it to the website 4. Go to Subscriptions > Pricelists and edit pricelist "Benelux" 5. In the Recurring Prices tab, create a new entry for product "subscription" with a Fixed Price of $20.00 and a monthly Recurring Plan 6. Log in as portal user, go to the shop and look for "subscription" (pricelist "Benelux" should be selected) 7. Try to add it to the cart 8. Nothing happens and an error is displayed in the log Issue: When we check if a product can be added to the cart https://github.com/odoo/odoo/blob/b1f4647313eb2dbdbbe98b51649604b4e650a8aa/addons/website_sale/controllers/cart.py#L116-L120 we do not use the plan_id specified in kwargs We reach this code https://github.com/odoo/odoo/blob/b1f4647313eb2dbdbbe98b51649604b4e650a8aa/addons/website_sale/models/product_product.py#L146-L147 which will prevent the addition of a product in the cart if the option `prevent_zero_price_sale` is enabled and if `_get_contextual_price` returns zero Calling `_get_contextual_price` tries to find a `product.pricelist.item` by building a domain in `_get_applicable_rules_domain` but calling this method without a plan_id eventually reaches https://github.com/odoo/enterprise/blob/252c5ab78b51d0d2f06178cf92f0489b4a46958f/sale_subscription/models/product_pricelist.py#L69-L72 which restricts the domain to pricelists that are not subscription plans Therefore, we cannot find any pricelist that applies to the product and we consider that the product cannot be added to the cart Solution: We need to use the plan_id selected by the customer in order to correctly check if a product can be added to the cart. Use the plan_id in kwargs to update the request context so we can check if a product can be added to the cart according to the plan_id the user has selected. Use this plan_id in `_get_applicable_rules` in order to correctly select the applicable `product.pricelist.item`. opw-5993614
This fix resolves two issues when setting up recurring prices for subscription products in a multi-company environment. Users can now successfully add recurring price lines without encountering company inconsistency errors, and recurring plans with specific company assignments now appear correctly in the selection list.
Original PR description
## Issues When adding a line in the *Recurring prices* tab (`product.pricelist.item`) of a product with a `company_id`, a "company inconsistencies" error appears. Also, recurring plans with their…
## Issues When adding a line in the *Recurring prices* tab (`product.pricelist.item`) of a product with a `company_id`, a "company inconsistencies" error appears. Also, recurring plans with their *Company* field set do not appear in the list of recurring plans when adding a line in the *Recurring prices* tab. ## Steps to reproduce 1. Install *Subscription* (`sale_subscription`) 2. Create a second company 3. Create a subscription product and set a company in the *Company* field (`company_id`). 4. In the *Recurring prices* tab, add a line (any recurring plan, any price) 5. **An _Invalid Operation_ error appears: _"Uh-oh! You’ve got some company inconsistencies here"_** For the second issue, after the same 3 first steps: 1. Create a *Recurring Plan* RP with its *Company* field set to the current company 2. On the *Recurring prices* tab of the subscription product, try to add a line with the Recurring plan RP 3. **The Recurring plan RP is missing from the list of available plans.** ## Cause When adding a line to the *Recurring prices* tab, a new `product.pricelist.item` is created, with no `pricelist_id`. The `ProductPricelistItem._compute_company_id` from `sale_subscription` filters out the items that don't have a `pricelist_id`, which is the case for the line we create. Also, the (potentially new) plan has no `company_id` in most cases. https://github.com/odoo/enterprise/blob/ccab0c261040ed995d12dca891caae9596bbe1eb/sale_subscription/models/product_pricelist_item.py#L18-L26 By filtering the items with no `pricelist_id`, nothing is passed to the `super()._compute_company_id`, even though it would also handle cases where the item has a `product_tmpl_id`: https://github.com/odoo/odoo/blob/9c8112d794af1ba84ade8af124967495c2ff8995/addons/product/models/product_pricelist_item.py#L170-L173 opw-5981629 opw-6051978
This fix prevents the system from unnecessarily recalculating product costs (COGS) when an invoice is reset or cancelled. Previously, resetting an invoice would trigger a full cost recomputation, which could cause performance issues and incorrect cost calculations. This change ensures costs are only recalculated when actually needed.
Original PR description
test et commit msg à faire
Users encountered an access rights error when creating private tasks with no project or assigned users. This fix automatically assigns the task creator as a user when creating a private task, ensuring they have proper access to their own tasks. This resolves the frustrating error that prevented users from creating standalone private tasks.
Original PR description
When users would follow the following step as they are makeing a private task, they would be hit by an incorrect access error. Steps to reproduce: 1.Open the form view to create a new task. 2.Clear…
When users would follow the following step as they are makeing a private task, they would be hit by an incorrect access error. Steps to reproduce: 1.Open the form view to create a new task. 2.Clear the Project field. When empty, it should display the Private placeholder. 3.Ensure no user is assigned to the task. 4.Create the private task. 5.An access rights error occurs, stating that the user does not have permission to create the record. ⚠️ Note: This access rights error only occurs when the task is created directly as private. If a task is created normally and then its project_id and user_ids are removed afterward, no access rights error occurs. Root cause: When a task is created without a project_id and without assigned users, Odoo checks access rights on creation. Since no project members or assigned users exist, no user has access to the record, including the creator. This results in an access rights error during creation. This issue does not occur when modifying an existing task because, after creation, the creator is automatically added as a follower. As a follower, the creator retains access to the task even if it has no project and no assigned users. Fix (implemented): Tasks that have no assigned users and are not linked to any project (private tasks) did not make sense, as they were effectively assigned to nothing. To address this, we now require at least one user to be assigned to a task when it is not attached to a project. This change was made inside of the "project_task_view.xml" file in the "view_task_form_2" record Versions : 17.0 -> master Task [5403926](https://www.odoo.com/odoo/project/4105/tasks/5403926) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#242216
This fix prevents the system from automatically changing document dates when the tax supply date is modified on already-posted accounting entries. Previously, the system would automatically align dates for all documents, but this created issues with Czech tax regulations that allow late tax deductions where dates should not be automatically synchronized. Users can now manually adjust dates when needed.
Original PR description
Description of the issue/feature this PR addresses: This automatic date alignment make sense in case of new document, but when you work on document that was posted. User should change it manually. In Czech republic we have something like late tax deduction and in this case there is not alignment of dates. Current behavior before PR: When you change taxable_supply_date it automatically change date Desired behavior after PR is merged: Disable this calculation od moves that hase been posted. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Project users encountered an error when trying to add a customer to a task. This fix resolves the access issue by improving how the system handles customer information updates, ensuring project users can now successfully create and manage tasks with customers assigned.
Original PR description
Steps to Reproduce: - 1. Log in with a user having only Project > User access. 2. Create a new task in project. 3. Add a customer on the task. 4. Access error is raised. Issue: - - Project users could not create a task with a customer. - An access error appeared during task creation. Cause: - - When a customer was added to the task, the partner_phone inverse method was triggered. - This method attempted to write on the partner record. Solution: - - Added a check before writing to avoid unnecessary writes. - Used sudo() to update the partner phone securely. - Added view-level restriction using base.group_partner_manager to control who can edit the phone number. task-5039657 Forward-Port-Of: odoo/odoo#256755 Forward-Port-Of: odoo/odoo#252406
This update fixes an issue where the virtual keyboard would automatically open when users interact with dialog windows on touch devices like tablets and phones. The fix keeps the dialog's focus protection active while preventing the keyboard from appearing, improving the user experience on mobile devices.
Original PR description
Commit 1 addressed an issue where the virtual keyboard would pop up unexpectedly when navigating on touch devices. However, due to commit 2, opening a dialog traps the focus in the dialog and automatically focuses on the first element. On touch screens, this behavior triggers the virtual keyboard. This commit changes the behavior so that, on touch devices, the focus is on the main part of the dialog instead of the first input field. This prevents the virtual keyboard from opening while ensuring the focus trap remains active. opw-5970020 1: https://github.com/odoo/odoo/commit/9d8f9d90743490c37a89fa71be087d38924164e7 2: https://github.com/odoo/odoo/commit/cd624c891f356c0527f5bb75cdfe1e05b7b79a21
Users can now successfully search for archived accounts by their account code. Previously, when filtering for inactive accounts and searching by code, the system would not display the archived account even though it matched the search criteria. This fix ensures that account code searches work correctly regardless of whether an account is active or archived.
Original PR description
# How to reproduce - Go to the chart of account - Archive any record (e.g. Code 101401) - Search with the filters : - Inactive Accounts - Account: 101401 (the code of the record) # The problem The…
# How to reproduce
- Go to the chart of account
- Archive any record (e.g. Code 101401)
- Search with the filters :
- Inactive Accounts
- Account: 101401 (the code of the record)
# The problem
The record that we searched for is not shown
# Cause
The domain for the "Account" filter is the following : https://github.com/odoo/odoo/blob/87c5f562e32ffb58359cf068124e03ead1a5859c/addons/account/views/account_account_views.xml#L147
And this is the domain for "Inactive Accounts":
https://github.com/odoo/odoo/blob/87c5f562e32ffb58359cf068124e03ead1a5859c/addons/account/views/account_account_views.xml#L159
This is correct and the search should return what we wanted, but the code's search is overriden by:
https://github.com/odoo/odoo/blob/87c5f562e32ffb58359cf068124e03ead1a5859c/addons/account/models/account_account.py#L383-L384
And the search with the `code_store` domain only explicitely looks for accounts that are active, so our "[('active', '=', False)]" is essentialy ignored
This is fixed in 19.1 because this commit (https://github.com/odoo/odoo/commit/de959adf7c806e09864b52fec78d981e66804280) replaced the custom search by a `compute_sql`
# Proposed solution
We change the search with the `code_store` to look for records that are both active and inactive, since the active value will be handled by the parent search
opw-6059404
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#256060This fix resolves a critical bug in the purchase order system where an outdated field reference was causing purchase orders to fail during confirmation. A previous system update renamed a field but left behind an old reference, which has now been corrected to ensure purchase orders can be confirmed without errors.
Original PR description
A big refactor of UOM in saas-18.1 (https://github.com/odoo/odoo/pull/184131) accidentally left a reference to the `product_uom` field on `purchase.order.line`. But that field was renamed to `product_uom_id` in https://github.com/odoo/odoo/pull/186250. In rare edge-cases, if we it `supplierinfo['product_uom_id'] = line.product_uom.id` while confirming a purchase order, it will block it because of a traceback: ``` supplierinfo['product_uom_id'] = line.product_uom.id ^^^^^^^^^^^^^^^^ AttributeError: 'purchase.order.line' object has no attribute 'product_uom'. Did you mean: 'product_id'? ``` This PR fixes the issues by accounting for the field rename. OPW-6068125 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#256768 Forward-Port-Of: odoo/odoo#256416
This update fixes how URLs are processed and displayed in email messages. Previously, URLs could appear differently to users due to encoding and decoding issues. The fix uses a more reliable method to handle URL formatting, ensuring that the URL a user sends is exactly what appears in the message.
Original PR description
Before this commit, the URL was fully encoded using encodeUrl. This commit replaces this approach with the more modern [URL api](https://developer.mozilla.org/en-US/docs/Web/API/URL), which [handles encoding](https://url.spec.whatwg.org/#dom-url-href) properly. This commit also removes decodeUrl. It was possible for a user to send a URL and have a different one displayed in the UI due to decoding. Task-6041689 Forward-Port-Of: odoo/odoo#256650 Forward-Port-Of: odoo/odoo#254383
This fix resolves an issue where popup modals on websites could not be closed by pressing the Escape key when they contained no clickable elements like links or buttons. The fix ensures the keyboard event is properly detected by the popup system, allowing users to close popups using the Escape key in all cases.
Original PR description
Steps to reproduce: =================== - Add a Popup snippet to a page - Remove all links/buttons inside the popup - Save and wait for the popup to appear - Press ESC -> Nothing happens. Cause:…
Steps to reproduce:
===================
- Add a Popup snippet to a page
- Remove all links/buttons inside the popup
- Save and wait for the popup to appear
- Press ESC
-> Nothing happens.
Cause:
======
https://github.com/odoo/odoo/blob/a922c31fa7ccd1107b31287ab1f75697fae874f8/addons/website/static/src/snippets/s_popup/000.js#L219-L226 when the popup contains no tabbable elements, `this.el.focus()` was called. `this.el` refers to the `.s_popup` div, not the `.modal` element that Bootstrap monitors for keyboard events. As a result, the ESC keydown event never reached Bootstrap's handler and the modal stayed open.
When focusable elements (links, buttons) were present, `tabableEls[0].focus()` correctly focused an element inside `.modal`, so ESC worked fine in that case.
Solution:
=========
Replace `this.el.focus()` with `this.el.querySelector(".modal").focus()` so focus lands on the `.modal` element allowing Bootstrap's built-in ESC handler to fire correctly in all cases
opw-5891054
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#254284
Forward-Port-Of: odoo/odoo#250050This update corrects a configuration issue where branch companies using their parent company's VAT for Peppol registration were incorrectly shown a participation role setting. Since branches can only send documents (not receive), this setting is now hidden from the user interface to prevent confusion and ensure proper system behavior.
Original PR description
In v19.0 -> master, if a branch company used the VAT of the parent company to register for peppol, the peppol participation role would be shown in the configuration settings, with a default value being "Sending and receiving", And since branches in this case should be able to ONLY send, the setting shouldnt be visibile to the user. task-none
This fix restores proper handling of PDF file types that include optional parameters in their MIME type specification. Previously, the system was too strict in validating PDF file types, rejecting valid PDFs that contained additional parameters. This change allows the system to correctly recognize and process all valid PDF files.
Original PR description
The structure of a MIME type commonly consists of just two parts: a type and a subtype, separated by a slash (`/`), but optionally it can also contains parameters to provide additional details (`type/subtype;parameter=value`). This commit restores this nuance in the PDF mimetype check that was made stricter in the commit odoo/odoo@b048078971f4f12307740a8b382b762a35983059. Reference: - https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/MIME_types runbot-241165
Mozambique users were seeing the incorrect Brazilian tax ID label "CPF/CNPJ" on their sales orders and invoices instead of the correct Mozambican label "NUIT". This fix adds the proper tax ID label for Mozambique so users now see the correct terminology on their business documents.
Original PR description
Currently the "Tax ID" title used e.g. on sales orders, invoices, etc. was translated as "CPF/CNPJ" in Portuguese, which is the tax ID used in Brazil. However, in Mozambique, the tax ID is called "NUIT", and there is no language variant for Portuguese in Mozambique. This caused Mozambique users to see "CPF/CNPJ" instead of "NUIT" on their documents, which was wrong. This commit adds a `vat_label` field for Mozambique to display the correct tax ID label. Issue reported by functional support. Forward-Port-Of: odoo/odoo#256603
This fix resolves an issue where replacing the contact form on the /contactus page would cause submission errors. The problem occurred because the system was using email settings from the old form configuration even after the form was deleted and recreated. The fix ensures that email settings are only applied when the original form is still present, preventing mismatches when users create new forms.
Original PR description
Problem: There is a data-for span in the /contactus page that sets specific values on the page's form. If this form is deleted and a new form is added, an error will occur when trying to submit the new form. This is because the value set for website_form_signature will use the email set in the data-for, which will not match with the new form. Purpose: Modify the code that sets the website_form_signature value to ensure that the original form is present as well if using the data-for values. Steps to Reproduce in Runbot: 1. Use the Website Editor to delete the form on the /contactus page and create a new one. 2. Attempt to submit the new form. opw-5956030 Forward-Port-Of: odoo/odoo#253410
This update fixes a validation issue in the payment demo module to ensure provider configurations are properly checked. The fix prevents potential errors when processing payments by validating that the payment provider is correctly configured before use.
Original PR description
opw-3097856 Forward-Port-Of: odoo/odoo#256362
This fix corrects an issue where vendor codes and names were not updating properly in purchase order line descriptions when changing vendors. The system now consistently validates that the correct vendor information appears in product descriptions, preventing confusion when managing multiple vendors for the same product.
Original PR description
How to reproduce : - Create a product - Create an attribute with a value set to "free text" - Add 2 different vendors to the purchase tab of the product with different Vendor Code and/or Vendor Name…
How to reproduce : - Create a product - Create an attribute with a value set to "free text" - Add 2 different vendors to the purchase tab of the product with different Vendor Code and/or Vendor Name - Put Dropship as the route for the product to create a PO on a SO confirmation - Create a SO with that product - Confirm the SO and go to the PO - Change the vendor in the SO The problem : The Vendor Code and/or Vendor Name does not change correctly in the product description Why : The way the description generation for a change in a purchase order line works as follows : Create a collection of default descriptions based on the product and the different vendors. If the collection contains the current description, it means the description was not changed by the user and it can be modified. This is done to prevent resetting a custom description made by an user. This logic is pretty broken because the code that generate the description when going from a PO to a SO and the code that generate the description when changing the PO partner are different. This makes it so the current description is almost never found in the list of default descriptions. It looks tempting to try to "resynchronize" those part of the code so the description generation is the same in both cases. This would be done by overriding the _get_product_purchase_description method in the purchase_stock module and using the product_description_variants field. Sadly, this does not work because it conflicts with the purchase_product_matrix module and its own override of that method. The fix that I implemented checks that the Vendor Code and Name are the right one every time the description is computed following a change. opw-5888233 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#255552 Forward-Port-Of: odoo/odoo#247330
This fix improves the performance of the website's product category filtering by optimizing how the system checks if categories have published products. Previously, the system was making too many database queries when filtering categories, which slowed down page loading. The update reduces unnecessary queries and makes the website faster, especially when there are many product categories.
Original PR description
`has_published_products` was previously computed recursively. For recursive fields, the ORM disables prefetch optimizations. In 3ffca1961cb1671e7028dd4dceca82d2e74a2e21, the computation switched to…
`has_published_products` was previously computed recursively. For recursive fields, the ORM disables prefetch optimizations.
In 3ffca1961cb1671e7028dd4dceca82d2e74a2e21, the computation switched to `_read_group` to avoid loading all published products into cache and prevent memory issues. However, this introduced an N+1 pattern when evaluating:
```python
categories.filtered(lambda categ: categ.has_published_products)
```
As a result, query count became dependent on the number of active categories, which broke SQL performance tests when demo data were installed.
This commit updates the computation again to avoid recursion and restore ORM prefetch optimizations, making the number of queries independent of the number of active categories.
This commit also removes redundant checks already enforced by ORM `ir.rule`. For example, the following pattern evaluates `has_published_products` three times: once in the user domain, once in the access rule domain added by `search`, and once in the filter.
```python
domain = [("has_published_products", "=", True)]
categs = self.env["product.public.category"].search(domain)
categs.filtered("has_published_products")
```
runbot-234948
Forward-Port-Of: odoo/odoo#256415This fix resolves an issue where the system was not checking archived accounts when creating unaffected earnings accounts, causing validation errors during upgrades. The change ensures that archived accounts with duplicate codes are properly recognized, preventing upgrade failures for companies using the Saudi Arabia localization module.
Original PR description
Archived accounts are also searched when looking for duplicate codes since https://github.com/odoo/odoo/commit/cd8d9718427e48aaa79be21f9a08e89b79b573f9 We need to check archived accounts as well when creating the unaffected earnings account, to avoid triggering the validation if an archived account has the same code. This is failing on upgrades with `l10n_sa` installed where the account `sa_account_999999` has been archived. Forward-Port-Of: odoo/odoo#256112
This update fixes a mislabeled VAT tax in the Swedish localization module. A tax for services sold outside the EU was incorrectly named "0% EU RS" when it should be "0% EX RS" (EX for external/outside EU), and it was assigned to the wrong tax grid. This correction ensures proper tax classification and reporting for international service sales.
Original PR description
Currently, the tax for "VAT Sale of service outside EU 0%" has the 0% EU RS name and is associated with the se_39 grid. Since it is for outside the EU, it's name should be 0% EX RS and the grid should be se_40 opw-5798152 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#256402 Forward-Port-Of: odoo/odoo#251750
This fix corrects an issue where revision dates displayed in the document history dialog were showing incorrect times due to timezone conversion errors. The system was interpreting UTC timestamps in the user's local timezone, causing dates to shift by several hours. After this fix, revision dates will display correctly regardless of the user's location.
Original PR description
Description of the issue/feature this PR addresses: The record's `create_date` from `orm.read` is a naive datetime string in UTC, but `DateTime.fromFormat` without a zone option interprets it in the browser's local timezone. This causes the initial revision's date to be shifted by the user's UTC offset in the history dialog. Current behavior before PR: 1) Create a task 2) Change/Add description in it 3) Check the version history 4) the task is having wrong date/date & time in the 1st revision (in my case -5:30 hours) <img width="749" height="515" alt="image" src="https://github.com/user-attachments/assets/e9480570-7458-4e0a-9bba-6514d6b1aacf" /> Desired behavior after PR is merged: <img width="751" height="483" alt="image" src="https://github.com/user-attachments/assets/ff9d1c95-fc8e-40bb-8cf8-bab39c9cd59b" /> --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fix resolves an issue where colored links in the website editor would revert to their default color after saving and closing the editor. The solution ensures that the styling rule for colored links is permanently applied to the website, regardless of whether the editor is currently open or closed.
Original PR description
Problem: Colored links revert to the default link color after saving and closing the website editor. Cause: The rule forcing links to inherit color from their parent `<font>` element is defined in the `html_editor` module, whose stylesheet is unloaded when the editor is closed, so the rule no longer applies on the frontend. Solution: Add the rule to `html_editor.common.scss` so it applies on the frontend regardless of whether the editor is loaded. Steps to reproduce: 1. Open the website editor. 2. Apply Color to selection. 3. Apply link to the subset of the selection. 4. Save and close the editor. 5. Observe the link reverts to its default color. task-5980854 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#253301
This fix resolves an issue where automated invoice delivery notifications (webhooks) were being blocked with access errors. When one user sent an invoice to another registered user, the system was incorrectly denying permission to process the notification. The fix restores proper access permissions so invoice delivery notifications work as intended.
Original PR description
- Register your user (on a db that allows webhook). - On another registered account, send an invoice to the first one. => A webhook call has been made, resulting into a 403 Forbidden. Following some changes on access rights checks, the webhook don't work. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Fixed an issue where chatbot conversations that restart and create new tickets or leads were incorrectly including messages from the previous conversation session. Now only messages from the current session after the restart are included in the ticket/lead description, ensuring cleaner and more accurate records.
Original PR description
Before this commit: When a chatbot conversation is restarted and the script creates a new ticket/lead, the description also includes messages from the previous session. After this commit: Only the messages sent after the chatbot conversation is restarted are included in the ticket/lead description. Task-5118966 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#256295 Forward-Port-Of: odoo/odoo#253566
This fix restores the ability to sort grouped lists by date and datetime fields, which was broken in a recent update. Users can now click on date column headers in grouped views (like deferred invoice entries) to sort the data, improving the usability of financial reporting and data organization features.
Original PR description
Steps to reproduce 1. Open Accounting > Customers > Invoices and create an invoice with deferred dates. 2. Open the invoice and click the Deferred Entries smart button. 3. In the grouped list view,…
Steps to reproduce 1. Open Accounting > Customers > Invoices and create an invoice with deferred dates. 2. Open the invoice and click the Deferred Entries smart button. 3. In the grouped list view, click the Date column header to sort. 4. Nothing happens. Issue The [IMP] web: Grouped kanban/list in a single RPC (https://github.com/odoo-dev/odoo/commit/26c37c9c070107f8bd753cb8a6d8343384fdd7bf) refactor introduced a regression. _get_read_group_order() [1] iterated over the provided aggregates list to build the ORDER BY clause. Fields with an aggregator attribute that are not included in the aggregates list (e.g. date fields, which getAggregateSpecifications() excludes) were silently dropped from ORDER BY. [1] https://github.com/odoo/odoo/blob/26c37c9c070107f8bd753cb8a6d8343384fdd7bf/addons/web/models/models.py#L496-L514 Solution Add a fallback in _get_read_group_order() so that when fname is neither a groupby field nor present in the provided aggregates list, the method checks field.aggregator directly and appends `fname:aggregator direction` (e.g. `date:min ASC`) to the ORDER BY string. The ORM's _read_group_orderby() already accepts such specs in ORDER BY even without them being in SELECT. opw-6044059
This fix corrects a bug where the website editor was incorrectly converting page URLs into phone numbers. When users tried to link to pages with names like "/3-14", the system would mistakenly treat them as phone numbers and add a "tel:" prefix instead of creating a proper page link. The fix makes the phone number detection more accurate so it only recognizes actual phone numbers.
Original PR description
# How to reproduce - Add a new website page with a title that ressembles a phone number (3-14 does the trick even though it does not really look like a phone number) - Go to another page in edit mode…
# How to reproduce
- Add a new website page with a title that ressembles a phone number (3-14 does the trick even though it does not really look like a phone number)
- Go to another page in edit mode
- Select a button
- In the "Enter URL, /page, or #anchor" input, write the url to your page (/3-14)
- Click on Apply
# The problem
Instead of a link to our page, the button has a link with a tel: protocol.
# Cause
When clicking on the Apply button, the `applyDeducedUrl()` function will be run.
https://github.com/odoo/odoo/blob/892b15963625acc89b7ed7b1c6f94392111df6be/addons/html_editor/static/src/main/link/link_popover.js#L294
That function will change the selected url with the URL deduced from `deduceURLfromText()` if any is found. In our case "/3-14" matches the `PHONE_REGEX` pattern so the url is prefixed with the tel: protocol.
https://github.com/odoo/odoo/blob/892b15963625acc89b7ed7b1c6f94392111df6be/addons/html_editor/static/src/main/link/utils.js#L71
https://github.com/odoo/odoo/blob/892b15963625acc89b7ed7b1c6f94392111df6be/addons/html_editor/static/src/main/link/utils.js#L34
That regex is a bit too permissive and allows our "/3-14" to be matched even though it starts with "/".
Side note : cases like "( )", "...", "--)" are also a match, which is not really an issue because they do not really represent anyting but it shows that the regex is not strict enough.
# Proposed solutin
We edit the regex to make it so it only matches strings that have atleast a digit and where the first character (after "+") is a digit or "("
opw-6047571
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prThis fix resolves an issue where PDF files with a specific internal structure (using /Kids nodes) were not having their embedded attachments properly extracted. Previously, bills uploaded through the accounting dashboard would appear empty if the PDF used this alternative organization method. The fix now supports both standard and alternative PDF file organization formats, ensuring all embedded documents are correctly extracted.
Original PR description
Steps to reproduce: - From the accounting dashboard, upload a PDF containing intermediate /Kids nodes representing separate xml attachments Issue: No xml will be extracted, as result the bill will be empty. However, in the chatter pdf preview, the js pdf toolkit correctly show the xml attachemnts. Analysis: The PDF spec defines two ways to organize embedded files under /EmbeddedFiles in the document's name dictionary: - /Names: a flat array of pairs located directly under /EmbeddedFiles - /Kids: an array of child nodes, each of which carries its own /Names array. The extractor currently only handled the /Names case, not detecting embedded attachments in case of PDF using a /Kids tree. This change add lookup for both structures. opw-5929274 Forward-Port-Of: odoo/odoo#252523
Marketing emails sent in right-to-left languages (like Arabic) were incorrectly displaying in left-to-right format. This fix restores proper text direction handling so emails display correctly regardless of the user's language setting. Users sending campaigns in RTL languages will now see their content formatted properly in recipient mailboxes.
Original PR description
**Steps to reproduce:** - Install Mail Marketing app - Change user language to a RTL language (such as Arabic) - Create a marketing campaign with RTL content - Send it - Mail received changes from…
**Steps to reproduce:**
- Install Mail Marketing app
- Change user language to a RTL language (such as Arabic)
- Create a marketing campaign with RTL content
- Send it
- Mail received changes from RTL to LTR
**Issue:**
Conversion doesn't take into account the current
language direction anymore when creating the inline
styling. This keeps the mails in the default format ('ltr').
Previously the inline conversion was using the `/portal/static/src/scss/portal.scss`
to set the html body text direction using the `rtlcss` library:
```css
// Frontend general
body {
// Set frontend direction that will be flipped with
// rtlcss for right-to-left text direction.
direction: ltr;
}
```
It was used during the inline conversion in a `CSSStyleRule`
after loading the doc sheets, and added with the `.o_layout` selector:
```js
if (selector === "body") {
// The top element of a mailing has the class
// 'o_layout'. Give it the body's styles so they can
// trickle down.
cssRules.push({
selector: ".o_layout",
rawRule: subRule,
specificity: 1,
});
}
```
But recent refactor reworked the styling assets used by
this process, which removed this behavior.
**Fix:**
Keep style `direction` (instead of `dir` attribute) like
before, to avoid compatibility issues in mail engines.
This is done by reapplying the body rule on the
mass_mailing iframe styling, but it could also be manually
added to the fragment itself using the editor current config
or localization.
related: https://github.com/odoo/odoo/commit/354b8f60dbabcfac690d90bf657592e1347e4f86
opw-5982854This fix resolves a system crash that occurred when confirming sales orders containing both regular dropship products and subscription-based dropship products. The issue was caused by inconsistent date format handling in the purchase order system. By standardizing how dates are processed, the system can now handle mixed product types without errors.
Original PR description
**Steps to reproduce:** * Install *sale_management*, *sale_subscription*, and *stock* modules. * Go to *Settings* and enable *Dropshipping*. * Create two products: * One *normal dropship* product. *…
**Steps to reproduce:**
* Install *sale_management*, *sale_subscription*, and *stock* modules.
* Go to *Settings* and enable *Dropshipping*.
* Create two products:
* One *normal dropship* product.
* One *dropship + subscription* product.
* Create a *Quotation*.
Add both products to the order.
* Confirm the quotation.
**Observed behavior:**
* A traceback occurs during confirmation:
File '/home/odoo/workspace/odoo19/odoo/addons/purchase_stock/models/stock_rule.py', line 159, in _run_buy
date_planned = po.date_planned or min(v['date_planned'] for v in po_line_values)
TypeError: can't compare datetime.datetime to datetime.date
**Cause:**
* In *_run_buy*, the system computes the earliest *date_planned* using:
https://github.com/odoo/odoo/blob/4056fa8036ddad11c898cd775b7fa21ba4f8a5de/addons/purchase_stock/models/stock_rule.py#L159
* Subscription products set *date_planned* as *datetime.date*,
https://github.com/odoo/enterprise/blob/a88c64a224805d95b60a20c502428897655dba53/sale_subscription_stock/models/sale_order_line.py#L153
`current_period_start = self.order_id.last_invoice_date or
self.order_id.start_date or fields.Date.today()`
* while normal products set *date_planned* as *datetime.datetime*.
https://github.com/odoo/odoo/blob/4056fa8036ddad11c898cd775b7fa21ba4f8a5de/addons/sale_stock/models/sale_order_line.py#L286
before min() It call `_prepare_purchase_order_line_from_procurement`,
the value is assigned directly from `values.get('date_planned')`, and conversion
with `fields.Datetime.to_datetime()` only happens conditionally:
https://github.com/odoo/odoo/blob/98e6e929bf8e0c34ec77fb9d07ef253e0abf681c/addons/purchase_stock/models/purchase_order_line.py#L347-L351
As a result, some values remain `date` while others are `datetime`,
* When both are present in *po_line_values*, Python cannot compare the
two types, causing the crash.
**Fix:**
So by moving the `fields.Datetime.to_datetime()` cast to the initial
assignment of `res['date_planned']`, so it is always a `datetime`
regardless of the source, and removing the now-redundant cast inside
the `if` block.
---
opw-6034079
---
Description of the issue/feature this PR addresses:
Current behavior before PR:
Desired behavior after PR is merged:
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prThis update closes a loophole in email marketing that allowed users to create checklists using keyboard shortcuts and paste commands, even though the feature was supposed to be disabled. The fix ensures checklists cannot be created through any method in email marketing, providing a consistent and controlled user experience.
Original PR description
In email marketing, checklist creation is disabled via powerbox, toolbar, and shortcut (Ctrl+Shift+9), but it can still be created using the shorthand command ('[] ').
Disable the checklist shorthand command to ensure checklist creation is fully restricted in email marketing.
task-6048027This fix resolves an issue where tracker numbers added during the self-order kiosk checkout process were not being saved to orders. When customers added a tracker number on the confirmation page, it would be lost and not appear in the backend order details. The fix corrects a logic condition that was causing tracker data to be overwritten.
Original PR description
Step to reproduce: - install "pos_self_order" - have a kiosk type pos, with "service at" = "table" - start kiosk and fulfill a order - on confirmation page, add a tracker number for that order. - go to backend and open that order Observation: - check "order name" in "Extra info" page, we do not get tracker number Cause: - After this commit [1], the tracker data is overridden by next if blocks - hence the data is lost. Fix: - fix the condition. [1] https://github.com/odoo/odoo/commit/c3ea329f1dce44c668e4907fa98cb5104ed11741 opw-5975717 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes how text colors appear in the mass mailing builder tool. Previously, text with the "muted" style would change color based on the background, making it hard to read. Now the text color stays consistent and readable regardless of the background color chosen, ensuring better visibility in email campaigns.
Original PR description
This commit fixes an issue with the `text-muted` class that gives a specific color to the text based on a background-color. Since the mass_mailing builder is a special case for background colors. The class now gives a specific color no matter what the background color is set when used inside the mass_mailing builder. task-5993139
This update fixes two issues in the mass mailing feature: the onboarding tour now properly guides users through the subject line and theme selection steps, and text in the email builder now wraps correctly when words are too long for their container. These fixes improve the user experience when creating and sending mass emails.
Original PR description
## [FIX] mass_mailing: fix broken tour This commit fixes issues with the mass_mailing onboarding tour. The resolved issues are: * Subject tour step not properly handled: changed "click" to "edit" * Tour steps when theme is selected not shown: updated the trigger so that they are displayed. ## [FIX] mass_mailing: fix overlow-wrap This commit fixes an issue with the overflow-wrap behavior in the mass_mailing builder. By default the editor removes the overflow-wrap which sets its value to `normal`. This value makes it so that the text isn't wrapped if a word overflows the box its in. Now, the editable in the mass_mailing builder has the property set to `break-word` which is the wanted behavior. task-5974184
This fix prevents the express checkout option (Apple Pay and Google Pay) from appearing when customers have gelato products in their cart. Gelato requires email and street address information to calculate shipping costs, which aren't available during express checkout, causing errors for mobile users. By hiding express checkout for gelato orders, customers will use the standard checkout process instead.
Original PR description
Issue: --- Public users get error using Apple/Google pay with gelato. Steps to reproduce: --- 1- Setup gelato and stripe express checkout. 2- Using phone, in incognito mode, add a gelato product to cart. 3- Try express checkout. Cause: --- This is because email and street is not present in express checkout. While gelato needs these info to generate calculate shipping cost. Fix: --- We can prevent the express checkout to be shown in gelato orders. opw-5904177
This update fixes several issues with selecting and deleting content in the HTML editor, particularly when working with toggle lists and other special content blocks. Users will now be able to select all content with Ctrl+A and delete it properly, and keyboard selection will work correctly when moving across different types of content blocks.
Original PR description
Description of the issue this PR addresses: - When an element with `contenteditable="false"` is the first node in the editable, pressing Ctrl+A followed by Delete does not remove the entire selection…
Description of the issue this PR addresses: - When an element with `contenteditable="false"` is the first node in the editable, pressing Ctrl+A followed by Delete does not remove the entire selection and instead deletes only the last character. - Keyboard selection could skip or collapse when crossing contenteditable='false' toggle blocks. Desired behavior after PR is merged: - Ensure that the selection is anchored to the deepest editable position when performing a select-all operation so that the full editable content is correctly selected and removed. - Insert temporary placeholders before and after toggle blocks when keyboard selection starts. - Remove placeholders once the selection collapses. Steps to reproduce: - Insert a toggle list using `/togglelist` in a new todo - Add one or more paragraphs below it and enter some text - Select all content using Ctrl+A - Press Backspace to delete the selection - Observe that only the last character is removed Backport of: 67e6a617def3bf4f9eb6b63b0850f5cfc773bccc task-5363926 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#248292 Forward-Port-Of: odoo/odoo#241696
This fix corrects how inventory values are calculated when a purchase order is split across multiple receipts and invoices. Previously, the system was incorrectly devaluing inventory items, causing them to be priced higher than the actual invoiced amounts. Now the valuation correctly reflects the true cost of goods received, ensuring accurate financial reporting.
Original PR description
Description of the issue/feature this PR addresses: Assume the following use case: - Create a PO for 2 units with unit price 1000 - Receive 1 units -> Create a back order - Receive the backorder - Create a bill for 1 unit at 200 - Create a bill for the second unit at 500 Expected behavior: The moves have a total value of 700 (350 each) Current behavior: One move is valued correctly at 350 whereas the other one is valued at 1000 (in total 1350) This is a result of 47345b1fc8b805e232a4287cc6d5c54b2f5886cb removing the valued qty of all moves whose date is earlier than the current move or whose date is the same and having a smaller or **equal** id. This is unexpected as the same id should probably not be subtracted, as this is the QTY we are interested in. Tested on runbot. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr