Thursday, December 11, 2025
12 changes · saas-18.3
Resolved issues and error corrections
This update fixes an issue where increasing the number of people in a POS appointment reservation didn't correctly update the allocated table resources. The fix ensures that changes to reservation size are accurately reflected, preventing incorrect capacity displays and ensuring accurate resource management. This improves the user experience when managing bookings.
Original PR description
Currently, updating a POS appointment reservation from the gantt view to increase the number of people does not update the allocated resources. The booking modification is not saved and the UI…
Currently, updating a POS appointment reservation from the gantt view to increase the number of people does not update the allocated resources. The booking modification is not saved and the UI appears unchanged. Steps to Reproduce: 1) Install Restaurant and Appointments app with a demo. Enable booking for the restaurant 2) Open POS restaurant and go to Booking, switch to Gantt view. 3) Create a reservation for 2 people on a table with capacity 2. 4) Edit the booking to 4 people and add another table with capacity 2 and save. 5) The reservation remains at 2 seats and changes are lost. Root cause: After [this commit](https://github.com/odoo/enterprise/pull/81810/commits/e710cebceab096f48e044b5b0229de743a204864), the field `waiting_list_capacity` was introduced but the write() method was not present to propagate this value to `resource_total_capacity_reserved`, causing incorrect capacity computation in the `_inverse_resource_ids_or_capacity` method at [1]. FIX: Add `write()` to propagate `waiting_list_capacity` into `resource_total_capacity_reserved` to ensure correct recompute and resource update. [1]- https://github.com/odoo/enterprise/blob/763b34029253a786d1e4bf09a780c1fb799f0ba5/appointment/models/calendar_event.py#L265-L266 Before Fix: <img width="1911" height="965" alt="image" src="https://github.com/user-attachments/assets/1470c656-7e8b-42bc-96c5-1fd240489ec0" /> After Fix: <img width="1909" height="961" alt="image" src="https://github.com/user-attachments/assets/ce3b1a46-4e33-42f8-a902-461e05220c23" /> Note: This fix needs to be merged only in versions 18.3 and 18.4. since in version 18.0-18.2 and 19.0 the `resource_ids` is calculated based on `resource_total_capacity_reserved`(for 18.0-18.2) and `total_capacity_reserved`(for 19.0). opw-5354559
This update resolves an issue where CFDI invoices with global discounts were failing due to incorrect discount allocation. The fix corrects a bug in how discounts are distributed, ensuring invoices can be successfully sent to the PAC (Payment Authorization Center) in Mexican companies.
Original PR description
**PROBLEM** With a Mexican company, when trying to send a CFDI with a global discount, it can happen that after the repartition of the discount we have lines with a negative amount, so we can't send…
**PROBLEM** With a Mexican company, when trying to send a CFDI with a global discount, it can happen that after the repartition of the discount we have lines with a negative amount, so we can't send the CFDI. **STEP TO REPRODUCE** 1. Take a Mexican company 2. create a quotation with, product A = 1$, product B = 100$, global discount of 15% 3. create an invoice using this quotation, confirm it and try sending the CDFI. 4. the following error will appear : "Error when sending the CFDI to the PAC: Failed to distribute some negative lines" **CAUSE** In account, the function `_normalize_target_factor()` takes a list of dictionary `target_factors`, with the keys being invoice lines (the targets) and the keys being weights (the factors). It is used to normalize the weight associated with the lines, to later use them to dispatch things like discounts to those lines. This function also does a sort on the weight, and return a list containing pairs of index and weights. This is useful only in the function `_distribute_delta_amount_smoothly()`, other functions doesn't work well with the sorted returned list: they don't use the index, and dispatch discounts to the wrong lines. https://github.com/odoo/enterprise/pull/101109 adds a test in l10n_mx to reproduce the client use case.
This update fixes an issue where tax calculations were incorrectly distributing negative amounts across positive lines, particularly impacting scenarios in Mexico. The change ensures that tax factors are assigned to the correct base lines based on their original order, resolving a previous error that resulted in incorrect financial reporting. This improves the accuracy of tax calculations.
Original PR description
The factors are sorted so zipping them with base_lines won't assign the factor to the correct base_line. We need to use the index in it instead to reorder them as previously. Before this commit, in Mexico, when having lines with price_unit set as l1=326.4, l2=24.0, l3=172.8, l4=691.2 and a negative line of 1149.6, this last line was distributed accross the positive lines. However, the negative amount of l4 was wrongly assigned to l1 making this line negative at the end because of the reordering of lines in _split_base_lines. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update ensures Odoo correctly handles negative line items in Mexican e-invoicing (CFDI) transactions. Previously, there was an issue with distributing negative amounts across multiple positive lines. This change adds a test to verify proper distribution, aligning with Mexican regulations.
Original PR description
In mexico, you cannot send any negative lines in the CFDI (Mexican e-invoicing). The negative lines are distributed accross the positive ones in _dispatch_global_discount_lines. This test ensures the negative line is well distributed when its amount is higher than the sum of multiple positive lines.
This update fixes a problem where payments were incorrectly linked to the employee's bank account instead of the correct tax account. The change ensures that payments, particularly for taxes like federal income tax, are now processed using the intended bank account, preventing payment errors and ensuring accurate financial records. This resolves a previous bug impacting payment accuracy.
Original PR description
## Reproducing steps 1. Create a DB with demo data (hr,hr_payroll,accountant modules) 2. Set the bank account of Mitchell Admin (in Personal employee notebook page): create a new one by specifying…
## Reproducing steps 1. Create a DB with demo data (hr,hr_payroll,accountant modules) 2. Set the bank account of Mitchell Admin (in Personal employee notebook page): create a new one by specifying the account number (here is a random account IT22M8576110068R4A56E760901) and setting it as "trusted") 3. Set the bank account of the Internal Revenue Service (IRS) partner (also set it as trusted, and here is another random account: IT77H400725028682A0R202P050) 4. Create a new Off-Cycle Payslip : a. Payroll -> Payslips -> Payslips -> New Off-Cycle button b. Set Mitchell Admin as the employee of the payslip c. Change the Structure to "United States: Regular Pay" d. Compute Sheets 5. Create payments : a. Go to the Journal Entries linked to the payslip, and Post them b. Go back to the payslip and 'Pay' c. In the new wizard: Click on 'Create Payments' 6. Go back to the journal entries, a new button should've appeared on top of the page for the payments (click it now!) 7. Click on the PAY00001 (it the Federal Income Tax which is made to the Internal Revenue Service (ISR) and notice that the bank account used in payment is the bank account of the employee (should be the ISR account obviously) ## Purpose Avoid payment wrong initialization when a default value has been set to initialize the `account.payment.register`. Indeed, the `account.payment` also has a `partner_bank_id` property, and so the method `_create_payment`of the `account.payment.register` can initialize payment with wrong `partner_bank_id`. [enterprise#99373](https://github.com/odoo/enterprise/pull/99373) [task-4979220](https://www.odoo.com/odoo/action-4043/4979220) Forward-Port-Of: odoo/odoo#235475
This update fixes an issue where payroll payments were incorrectly linked to the employee's bank account instead of the correct vendor account (like the IRS). The change ensures payments are accurately routed to the intended recipient, improving financial reporting and compliance. Automated tests have been added to verify this correction.
Original PR description
## Reproducing steps 1. Create a DB with demo data (hr,hr_payroll,accountant modules) 2. Set the bank account of Mitchell Admin (in Personal employee notebook page): create a new one by specifying…
## Reproducing steps 1. Create a DB with demo data (hr,hr_payroll,accountant modules) 2. Set the bank account of Mitchell Admin (in Personal employee notebook page): create a new one by specifying the account number (here is a random account IT22M8576110068R4A56E760901) and setting it as "trusted") 3. Set the bank account of the Internal Revenue Service (IRS) partner (also set it as trusted, and here is another random account: IT77H400725028682A0R202P050) 4. Create a new Off-Cycle Payslip : a. Payroll -> Payslips -> Payslips -> New Off-Cycle button b. Set Mitchell Admin as the employee of the payslip c. Change the Structure to "United States: Regular Pay" d. Compute Sheets 5. Create payments : a. Go to the Journal Entries linked to the payslip, and Post them b. Go back to the payslip and 'Pay' c. In the new wizard: Click on 'Create Payments' 6. Go back to the journal entries, a new button should've appeared on top of the page for the payments (click it now!) 7. Click on the PAY00001 (it the Federal Income Tax which is made to the Internal Revenue Service (ISR) and notice that the bank account used in payment is the bank account of the employee (should be the ISR account obviously) ## Purpose Modifying `account.payment.register` for fixing `hr.payslip` payments generation so that each payment is assigned the correct `partner_bank_id`. Also, fixing a SEPA payslip payment bug which says that the employee bank account is untrusted even if it isn't. ## Tests Adding `test_bank_account_partner_payment_payslip` test to check that the payment generated for Professional Tax is made to the correct bank account (before this fix, the selected account was always the employee bank account, whatever the vendor specified in the payment). Adding `test_sepa_payslip_partner_bank_id` test to check that the `partner_bank_id` is set after account_register_payment wizard has been initialized and that the action_create_payments (action launched when the user clicks on "Create Payments" button of the `account_register_payment` wizard) doesn't raise any error. This second test is not really specified in the specs, I just stumbled upon some stacktrace when coding this PR and decided to add a test to check the flow of sepa payment. [community#235475](https://github.com/odoo/odoo/pull/235475) [task-4979220](https://www.odoo.com/odoo/action-4043/4979220) Forward-Port-Of: odoo/enterprise#99373
This update fixes an issue where the barcode scanning app on mobile devices displayed stock locations in a list view, which wasn't ideal for smaller screens. By setting a mobile view preference, the app now prioritizes a more suitable kanban view, improving usability and the overall user experience.
Original PR description
Issue ===== On mobile, we should prioritize kanban views over list views because kanban views are usually more suitable for small device screen. That said, when a product's barcode is scanned in the Barcode app main menu, we show this product's stock locations but we do that with a list view, no matter if the user is on a big screen or a small screen. How to reproduce ================ On mobile device: - Enable location and have a product with a barcode and with quantities in two different locations; - Open Barcode app; - Scan the product's barcode => The product's stock locations are displayed in a list view, which is not very pratical on small device. Fix === The action key `mobile_view_mode` was not set, with this key, we can define what view type we want to prioritize for mobile device. [opw-5180783](https://www.odoo.com/odoo/project/49/tasks/5180783) Forward-Port-Of: odoo/enterprise#101336
This update resolves issues where changes to cover images in nested website cards were incorrectly applied to other cards, or where cover image options were not displayed correctly. The fix ensures that image settings are applied only to the specific card being edited, improving the user experience and consistency of the website editor.
Original PR description
This commit fixes three issues occurring when editing nested `s_card` snippets. **Problem 1 - Incorrect cover image detection** Issue: An `s_card` without a cover image displayed the cover image…
This commit fixes three issues occurring when editing nested `s_card` snippets. **Problem 1 - Incorrect cover image detection** Issue: An `s_card` without a cover image displayed the cover image option if it contained a child `s_card` with a cover image. Cause: The `querySelector` in `CardImageOption` could detect images inside child snippets. Fix: Now the `querySelector` only searches among direct children of the snippet root element. **Problem 2 - Ratio settings applied to all child cards** Issue: Changing the cover image ratio on an `s_card` applied the setting to all nested cards. Cause: The `we-select` in `s_card` options targeted `.o_card_img_wrapper`, causing the class to apply to all descendants. Fix: The selector is now `>.o_card_img_wrapper`, so the option acts only on the current snippet. **Problem 3 - Parent image positioning leaking to children** Issue: Adjusting the cover image position on a parent `s_card` affected the rendering of all child card images. Cause: CSS rules for `.o_card_img_horizontal` applied to all descendant elements matching `.o_card_img_wrapper`. Fix: The rules now apply only to direct children of `.o_card_img_horizontal`. The same correction was applied to `.o_card_img_ratio_custom`. task-5349540 Forward-Port-Of: odoo/odoo#239503 Forward-Port-Of: odoo/odoo#237587
This update resolves an issue where the control panel's actions (like duplicate or trash) only worked on the first 40 documents uploaded to a folder. The fix ensures that all selected documents, regardless of the number, are now correctly processed. This improves usability and prevents data inconsistencies.
Original PR description
Steps to Reproduce =================== 1. Upload more than 40+ files in a folder. (One page displays upto 40 docs) 2. Use the checkbox to select all files on the page (this selects only 40 files) 3.…
Steps to Reproduce =================== 1. Upload more than 40+ files in a folder. (One page displays upto 40 docs) 2. Use the checkbox to select all files on the page (this selects only 40 files) 3. Click the 'Select All' button in the control panel to select all 40+ files. 4. Now, try duplicating or moving them to the trash. => Only the first 40 selected files (on the single page) are considered for action, not all the selected files. Technical ========== For documents control panel action we have custom handling for selecting records and executing action. We use `model.root.selection` which only consider records in current page, case of select all records from other pages is missed here. After this PR ================== - All selected records are considered for the actions - Added custom `getResIds` method to get filtered `resIds` as per domain. Note: `getResIds` in DynamicList doesn't have custom domain feature so create our own as per use case Task-4700841 Forward-Port-Of: odoo/enterprise#100496 Forward-Port-Of: odoo/enterprise#87634
This update fixes a performance issue within Odoo's PDF handling that could cause an infinite loop when uploading corrupted files. By updating the PDF.js library to version 4.8.69, we're ensuring smoother PDF uploads and a more reliable user experience. This also includes important Odoo-specific customizations to the PDF.js library.
Original PR description
This commit updates the PDF.js library to patch the issue related to: https://github.com/mozilla/pdf.js/pull/18878 In Odoo this issue raises a performance issue that makes a infinite loop when you upload a corrupted file and Odoo tries to upload a traceback. OPW-5214755 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#238994 Forward-Port-Of: odoo/odoo#236471
This update resolves a performance issue in the Odoo sign module related to corrupted PDF uploads. By updating the PDF.js library, the system now avoids an infinite loop and traceback errors, ensuring smoother PDF upload functionality. This improves the overall reliability of the sign process.
Original PR description
Modification of module to align it with the newer version This commit updates the PDF.js library to patch the issue related to: mozilla/pdf.js#18878 In Odoo this issue raises a performance issue that makes a infinite loop when you upload a corrupted file and Odoo tries to upload a traceback. OPW-5214755 Forward-Port-Of: odoo/enterprise#101551 Forward-Port-Of: odoo/enterprise#99912
This update fixes an issue where flexible employee leave durations were incorrectly calculated due to timezone differences. The fix uses date ranges (request_date_from and request_date_to) to accurately determine leave duration, ensuring correct hours are applied regardless of employee timezone settings. This ensures accurate leave tracking and payroll processing.
Original PR description
### Steps to reproduce: - Create an employee with Flexible working schedule - Set the timezone for this employee very far from yours - Create an Unpaid leave with Custom Hours for this employee - Set the hours of the leave from 8 to 21 - Notice the duration is just 8 hours ### Cause: When calculating the duration of the flexible employee leave we check if the date_from and the date_to has the same date and if so we get the difference between the hour_to - hour_from but sometime when the tz is different when we convert it to UTC the dates overlap in two days so the condition sets to false so we get the working hours of the employee. ### Fix: Using the request_date_from and request_date_to in this condition where it will always be accurate in terms of days opw-5118689 Forward-Port-Of: odoo/odoo#230366