Daily updates from Odoo
Thursday, May 22, 2025
12 changes · 18.0
Resolved issues and error corrections
This update prevents phone number errors from appearing too early when companies activate PEPPOL electronic invoicing. Phone numbers are now auto-formatted after editing and only validated during activation, reducing setup friction and avoiding accidental company data changes when users discard the wizard.
Original PR description
Steps to reproduce on runbot: 1. Select company "My Belgian Company" (`l10n_be` and `account_peppol`) should be installed 2. Settings -> Accounting -> PEPPOL Electronic Invoicing -> Activate…
Steps to reproduce on runbot: 1. Select company "My Belgian Company" (`l10n_be` and `account_peppol`) should be installed 2. Settings -> Accounting -> PEPPOL Electronic Invoicing -> Activate Electronic Invoicing 3. Ensure `+32470123456` is given as the phone number 4. Remove the country prefix from the phone number 5. A validation error is raised complaining about the phone number format The validation should only be performed when we click on the "Activate Peppol" button.. When editing the phone number the wizard should try to auto-format the given phone number before validating. In case there is no country prefix it should assume the phone number is from the country of the company. Since commit 7cd8c87e3fcacfefa6c789449eec32a3c5577089 the validation is performed before the auto-formating. There a call to the validation logic (`_sanitize_peppol_phone_number`) was added before the auto-formatting logic. (It was mainly just done to ensure that an external dependency is installed.) But there we do not (and should not) assume the country prefix of the phone number. The phone number is used during the registration process. A missing country prefix could lead to a failed registration. After this commit - the validation is only performed when we click on the "Activate Peppol" button. - the auto-formatting is performed after editing the phone number - the changes are not stored on the company when clicking on "Discard" - fix a `self` in a `for ... in self` part of task-4791098
When a Saudi e-invoicing journal is re-onboarded with ZATCA and receives a new compliance identifier, Odoo now resets its invoice counter to the starting value. This prevents old numbering from carrying over and helps keep Saudi e-invoicing records aligned with expected ZATCA onboarding behavior.
Original PR description
…ew PCSID When a journal is re-onboarding on ZATCA and a new PCSID is generated, the Invoice Counter Value (ICV) should be reset > Currently, the system does not reset the ICV when a journal is re-onboarded. The fix resets the sequence back to 1 on re-onboarding task-4652483 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
The product quantity selector setting now works the same way on product pages and configurator flows. This prevents shoppers from seeing different quantity controls depending on where they configure a product or combo, creating a more consistent buying experience.
Original PR description
Currently the show quantity setting visible on /product page does not apply on the product and combo configurator. We want to uniformize the behavior and if the setting is enabled then view the quantity selector everywhere depending on whether its visible on /product opw-4716312 opw-4781159 Backport of https://github.com/odoo/odoo/pull/209116 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Fixes an issue where changing a discount pricing rule to another pricing type and back could silently switch the discount to use the product list price instead of the selected base pricelist. This helps ensure sales quotations calculate expected discounted prices and makes the pricing rule state clearer to users.
Original PR description
**Problem:** When changing the price type of a Discount pricelist rule to "formula" and going back to the original price type "discount" the rule does not take into account the base pricelist anymore…
**Problem:** When changing the price type of a Discount pricelist rule to "formula" and going back to the original price type "discount" the rule does not take into account the base pricelist anymore and uses the list price of the product to compute the discount **Steps to reproduce:** - Navigate to Sales/Products/Pricelists - Create a new pricelist, click on Add a line - In "Price Type" select Fixed Price and set a Fixed Price of 10 - Save and Close > create a second new price list - Click on "Add a line" and select a Price Type Discount - Set a 50% discount percent and select your first pricelist as the base price (next to "on") - Save and Close > save the form - Open the rule again and change the Price Type to formula - Change the Price Type back to Discount and set a discount percentage of 50% again - Save and Close - Create a new quotation with a product and select the second pricelist you created > click on Update Prices **Current behavior:** Amount is 50% of the price of the product **Expected behavior:** It should be 50% of 10 because our second pricelist is based on the first one which has a fixed price of 10 **Cause of the issue:** when _onchange_compute_price is triggeredwhen going back to discount value, base will be set to list_price https://github.com/odoo/odoo/blob/d3e43681fd2b989ae7272731662cc3ac6a6d913b/addons/product/models/product_pricelist_item.py#L334-L342 because of this, the base price will not be computed based on the base pricelist https://github.com/odoo/odoo/blob/d3e43681fd2b989ae7272731662cc3ac6a6d913b/addons/product/models/product_pricelist_item.py#L580-L583 **fix:** By resetting the base_pricelist_id, it's now visible to the user on the form that the computation is no more based on a pricelist. If the user enters a pricelist, the correct value will be computerd for base and base_pricelist_id at that time. opw-4757951
Loyalty point history now correctly adds together the cost of all rewards used on the same order. This prevents sales orders and loyalty card histories from showing too few points spent when customers redeem multiple rewards at checkout.
Original PR description
Versions -------- - 18.0+ Steps ----- 1. Create a loyalty card program applying on future orders; 2. add 2 rewards: free shipping (100 points) & discount (200 points); 3. create a loyalty card for current user with 500 points; 4. apply both rewards on an eCommerce order & pay to confirm. Issue ----- In the back end, the sale order displays the loyalty points cost as 200 instead of 300. The same applies to the points history on the loyalty card view. Cause ----- The loyalty history model introduced by 17ef5c57a5c1 does not sum up the total cost of the points used on an order, instead it only saves the points used of the last reward line per coupon. Solution -------- Sum up the points per coupon. opw-4783518
This fixes an issue where adding a document to a new email template could duplicate content or break the layout after saving. Email templates with embedded media should now save more reliably, preserving the intended content and appearance.
Original PR description
Problem: Adding a document when creating a new email template using `/media` results in duplicated content on save. Cause: During HTML processing on save, `flattenBackgroundImages` wraps elements…
Problem: Adding a document when creating a new email template using `/media` results in duplicated content on save. Cause: During HTML processing on save, `flattenBackgroundImages` wraps elements with inline background images (`style*=background-image`) in MSO-specific comments: `<!--[if mso]><![endif]-->`. However, if multiple such elements are nested, they are each wrapped, resulting in invalid nested comments and broken layout. Solution: Since the two conditions are opposites, we remove completely the content of the nested comment if it has oppisite condition otherwise we just remove the comment tags since they will be replaced with the upper comment Fixed in `web_editor` in https://github.com/odoo/odoo/commit/fcedeb63f5b5da6758e75d02f0c1d4f3b965adc1 Steps to reproduce: 1. Create a new email template. 2. Add a document using `/media`. 3. Save. → The content is duplicated or layout is broken. opw-4775908 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Fixes an issue where a delivery in one company could be incorrectly reserved because a product was treated as a kit from another company. This helps keep multi-company inventory availability checks accurate and prevents unintended stock assignments.
Original PR description
### Steps to reproduce: - Have 2 companies: COMP1 and COMP2 - Create a storable product P with a kit bom for attached to COMP1. - With COMP2 create a delivery for 1 unit of P. > If you click on check…
### Steps to reproduce: - Have 2 companies: COMP1 and COMP2 - Create a storable product P with a kit bom for attached to COMP1. - With COMP2 create a delivery for 1 unit of P. > If you click on check availability the move should not be assigned. - As COMP1 and with COMP2 active, click on check availability once more #### > The move is assigned. ### Cause of the issue: Checking the availability will launch a call of the `action_assign` of the stock picking. During this call, the moves that shoudl by pass the reservation process will automatically be reserved: https://github.com/odoo/odoo/blob/9b0c1c416eaa0df64fbe28c5672f2590a218f315/addons/stock/models/stock_move.py#L1852-L1853 However, kit products are flagged to bypass the reservation process by these lines: https://github.com/odoo/odoo/blob/9b0c1c416eaa0df64fbe28c5672f2590a218f315/addons/mrp/models/stock_move.py#L521-L522 The issue with this line being that the product is a kit form COMP1 and not for COMP2 (the context is used to determine this in the compute method): https://github.com/odoo/odoo/blob/9b0c1c416eaa0df64fbe28c5672f2590a218f315/addons/mrp/models/product.py#L38-L40 ### Note: The issue can not be reproduced prior to 18.0, since the override of the `_should_bypass_reservation` was introduced by commit 4e1d46869e6c2d1ff473317179393007522a10a3 opw-4660233 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Stripe express checkout now correctly accounts for free shipping discounts, including taxes, when calculating cart totals. This prevents checkout errors and avoids showing negative or incorrect amounts when customers use delivery rewards.
Original PR description
Steps to reproduce: 1) Create a free shipping reward 2) Enable standard delivery and set price to 100 3) Configure stripe provider with express checkout 4) Go to /shop 5) Add a product to the cart with the price less than 100 6) Go to the checkout and apply reward 7) Go back to the cart and observe a traceback Reason: delivery_amount was calculated without a discount and in express checkout form `_getOrderDetails` this amount was subtracted from the order total which resulted in negative value Solution: Add discount if any opw-4648641
Point of Sale now still adds a weighed product when the scale cannot respond, such as when an IoT box is disconnected, so staff can enter the weight manually. Closing the scale popup still cancels the product as intended, preventing accidental default weights.
Original PR description
In odoo/odoo#208571, a fix was made to prevent 1 unit of weight from added when cancelling weighing. However, this also changed the behaviour when a scale error (such as IoT box being disconnected) occurs, preventing the product from being manually entered. In this commit, we amend the condition to only stop adding the order line if the user closes the scale popup, but still add it on error. opw-4643243 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Vendor bills now prioritize the prices set for each vendor on product records instead of defaulting to the product cost. This makes bill creation, including catalog-based entry, more consistent with what users see and expect, while preserving prices coming from purchase or sales flows when quantities change.
Original PR description
When creating a vendor bill, the vendor prices defined on the product is not used. This is very evident when using the catalog option on the vendor bill. The price displayed is the seller's price, but the product's cost price is used instead. This commit gives preference to the vendor price. No Task (18.0 Bug pad) 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
A4 statement reports now keep their header details visible when printed. This prevents important information from being covered by the folder-style layout, improving the reliability of customer-facing accounting documents.
Original PR description
Before this PR: In A4 statement format reports, the folder layout was overwriting header information, causing important header details to be obscured in the printed output. After this PR: Fixed folder layout rendering to preserve header information in A4 statement format reports, ensuring all header details are properly displayed. Solution: Adapted the A4 statement format implementation to work with the new report margin approach that replaces paperformat spacing with $o-default-report-margins CSS variable, preventing layout conflicts that were causing header overwrites. OPW-4741128
Currency rate inputs in accounting reports now validate the number before processing, preventing errors caused by letters or other invalid characters. Users can also enter amounts using the decimal and thousands separators that match their language settings, making the report easier and safer to use.
Original PR description
Update on the filterExchangeRate function. The text input allowed users to enter non-numeric characters, which led to float conversion errors during processing. Now we parse the string into a float, catch errors and notify the user that the number was not valid. It also enables the user to use the thousands and decimal separators based on the language of the user. opw-4788246