Friday, February 27, 2026
38 changes · saas-19.2
Enhancements to existing features
This update simplifies how businesses can tailor the product container element across different modules. Previously, customization required extensive code changes, limiting flexibility. Now, a dedicated method makes it easier to extend and maintain this functionality, ensuring future compatibility.
Original PR description
The product_container element may vary across modules and cannot be hardcoded. Modifying it currently requires overriding the entire add_to_cart method, which reduces flexibility and maintainability. This change extracts the product_container logic into a dedicated method, making it easier to extend and customize without duplicating the full add_to_cart implementation. This ensures better forward compatibility and modular extensibility. Enterprise PR: https://github.com/odoo/enterprise/pull/107343 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#249289
This update streamlines the user experience for accessing notification settings within the Discuss app. Previously, settings opened in a dialog, now they appear in a dropdown, creating a more consistent and user-friendly interface. Minor UI improvements have also been made for better visual harmony.
Original PR description
Before this PR, opening the notification settings from the thread action (In Discuss App) displayed them in a dialog, which made the UI less consistent with other thread actions. After this commit, opening the notification settings from the thread action displays them in a dropdown instead of a dialog, providing a more consistent and streamlined user experience. Task-5936685 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update streamlines the user experience by changing how notification settings are accessed from thread actions in the Discuss sidebar. Previously, settings opened in a dialog, now they open in a dropdown, creating a more consistent and user-friendly interface.
Original PR description
Before this PR, opening the notification settings from the thread action in the Discuss sidebar displayed them in a dialog, making the UI inconsistent with other thread actions. After this PR, the notification settings open in a dropdown instead of a dialog, ensuring a more consistent and streamlined user experience. community: https://github.com/odoo/odoo/pull/247352 task-5936685
This update enhances the Odoo inbox by streamlining the user interface and improving functionality. Specifically, it removes distracting elements, provides clearer notifications for bulk actions, and ensures all messages are properly displayed. These changes contribute to a more efficient and user-friendly email management experience.
Original PR description
This commit improves the UX of the inbox by: 1. Improving the copywrite of the empty inbox. 2. Removing the rainbow man animation. 3. Showing a toast notification upon marking all read giving the possibility to undo. 4. Allowing any message that got notified to the inbox to be marked as unread. 5. Adapted the spacing of messages with subject. task-5952525 | Before | After | | ------------- | ------------- | | <img width="564" height="235" alt="image" src="https://github.com/user-attachments/assets/fc937a48-9947-42ed-8f5c-77455a203702" /> | <img width="554" height="232" alt="image" src="https://github.com/user-attachments/assets/dc295e3e-57d3-4007-9aad-05f555943cba" />|
Resolved issues and error corrections
This update resolves an issue where the tax report export button was failing when companies had different VAT numbers. By adding a setting to allow for branch company selection, the button now correctly handles multi-company setups, ensuring accurate report generation. This improves the reliability of financial reporting.
Original PR description
To reproduce the issue: - Create a company with a branch - Give the company and its branch different VAT numbers - Make both companies active in the company selector - Open the tax report - Click on gear icon - Click on the XML(l10n_lu_reports)/Export SAWT & QAP(l10n_ph_reports) button ===> The following error is raised: "Please select the main company and its branches in the company selector to proceed." This is because the tax report's options only consider one of the two companies (because they have different VAT numbers). The button is not declared as branch_allowed, so when clicked, it checks whether all the companies of the branch hierarchy are in the options => they're not => error. We can fix this by simply making the buttons branch_allowed. Followup on: https://github.com/odoo/enterprise/commit/34ba0609e984496f0dcc862f0d7a46c6721beab9 task-5416330 Forward-Port-Of: odoo/enterprise#105961
This update fixes an issue where the 'Packages' report combined multiple package details into a single, unreadable page. Now, each package is printed on a separate page, allowing for clear identification and reducing the risk of errors during packing and shipping. This improves operational efficiency and accuracy.
Original PR description
Issue before this PR: ========================= - Currently, when printing a `Packages` report that contains `multiple packages` all `Package with Content` reports are printed as a `single continuous…
Issue before this PR: ========================= - Currently, when printing a `Packages` report that contains `multiple packages` all `Package with Content` reports are printed as a `single continuous document` without any line or page separation between packages. - This leads to issues because each `Package with Content` report is meant to be printed individually and physically attached to its corresponding package during packing and logistics operations. It creates `confusion and a risk of mislabeling`, as users must `manually interpret and separate package boundaries` when handling printed documents. Steps to Reproduce: ========================= 1. Install the `Inventory` app. 2. Go to Configuration → Settings and enable the `Packages` option. 3. Create a new transfer with multiple product lines and click `Mark as Todo`. 4. In Detailed Operations, assign `different packages` to at least two different product lines and `Validate` the transfer. 5. Open the `Actions` menu, select `Print → Packages`. 6. Open the generated PDF. All packages are printed on the same page, without any page or line separation. **Packages report before this PR:** <img width="500" height="300" alt="combined" src="https://github.com/user-attachments/assets/6a6b8cb5-bcf3-488e-b95a-7670db8fc6ad" /> Cause of the issue:- ========================= In the file `report_package_barcode.xml`, a `t-foreach` loop is used to iterate over the packages included in the report. However, the report template does not define any `page break or visual separation` between iterations. As a result, each package is rendered consecutively in a single, continuous page instead of being split into separate pages. After this PR:- ========================= This PR ensures that, when printing a `Packages` report containing `multiple packages`, each `Package with Content` starts on a new page. This clear separation allows users to easily identify and handle `individual package details`, reducing confusion and the risk of mislabeling, while preserving the existing report layout and content. **Packages report after this PR:** <img width="491" height="500" alt="breaked (1)" src="https://github.com/user-attachments/assets/d87a52e5-8b54-49d4-911a-2e07e487c0d8" /> TaskID-5025192 Forward-Port-Of: odoo/odoo#241762
This update fixes an issue where social security numbers were incorrectly displayed across different company versions in the payroll module. The change restricts SSN visibility to only appear within the relevant country's company records, ensuring data privacy and compliance. This improves the accuracy and security of employee data.
Original PR description
[FIX] l10n_hr_payroll: limit l10n_xx_ssn to appear only in xx companies Bug reproduction: Select version >= saas-19.2 -> select your company -> payroll->employee->personal->you will see social security number even though that can belong to SA, MX, EG. Bug cause: added ssn fields are not restricted to their own l18n, then they are appearing in each employee form views. Bug solution: add country restrictions for MX, EG, SA to not appear in other country's company. task - 5974006
This update fixes an issue where rental accessories added from the cart's suggested products were failing due to mismatched rental periods. Now, the accessory's rental period matches the existing cart's period, ensuring accessories are correctly added to the cart and preventing errors. This improves the user experience for rental product purchases.
Original PR description
Why this commit --- When adding a rental accessory product from the cart page suggested products, the…
Why this commit --- When adding a rental accessory product from the cart page suggested products, the [add_to_cart](https://github.com/odoo/enterprise/blob/19.0/website_sale_renting/controllers/cart.py#L52-L58) was triggered without the rental start and end dates(None was taken by default). As a result, the system uses [default rental duration](https://github.com/odoo/enterprise/blob/19.0/website_sale_renting/models/sale_order.py#L95-L99) for comparison and considers the accessory as having a different rental period then on the sale order and raised an error preventing it from being added to the cart. This issue did not occur when adding the same product from its product page, as the rental context was correctly provided there. After this Commit --- The rental start and end dates from the current sale order are passed when adding accessory products from the cart page suggested products. This ensures that rental period consistency checks succeed and the accessory can be added without raising an invalid operation error. Steps to Reproduce --- 1. Create two rental products A and B. 2. Configure product B as an accessory of product A. 3. Add product A to the cart with any rental period(except default). 4. From the cart page, attempt to add product B from suggested products. 5.Observe the error about mixing different rental periods. Here is the video demonstrating on how the error is reproduced : https://github.com/user-attachments/assets/3d5e6f96-cebd-4221-8592-1bdb6ae40ec7 Expected Result The accessory product is added to the cart using the same rental period as the existing cart's rental period. OPW: 5823691 Forward-Port-Of: odoo/enterprise#107343 Forward-Port-Of: odoo/enterprise#106426
This update resolves several issues impacting the Odoo Profiler's reliability, specifically related to thread management and data handling. The fixes prevent errors that could interrupt profiling sessions and ensure consistent data collection, leading to more accurate performance insights. These improvements enhance the overall stability and usability of the profiling tool.
Original PR description
Multiple fixes for the Profiler. Issues: - Python throws cannot join current thread when using the entry count with memory and traces async profilers. - The periodic profilers were waiting the full amount of the sleep before ending. - When using the entry_count, the memory profiler was throwing a non serializable object error - Sometimes the memory collector throws an error that the tracemalloc needs to be started so that it collects. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#248501 Forward-Port-Of: odoo/odoo#232551
This update ensures that employees cannot check in through the attendance app if location tracking is enabled and a location cannot be determined. This prevents inaccurate attendance records and ensures data integrity, particularly important for payroll and workforce management reporting.
Original PR description
When a user is trying to check in on the attendance app with the setting Device tracking enabled and the location cannot be determined, it should raise an error to prevent the check-in without a valid location. Task: 5486178 Forward-Port-Of: odoo/odoo#249753
This update resolves an issue related to how sick leave is tracked in Belgium, specifically when extended periods of absence occur. The change moves a targeted logic to a localized module to avoid conflicts and ensure accurate work entry type matching, improving the reliability of sick leave calculations. This addresses a previous localization problem and enhances the overall accuracy of HR data.
Original PR description
In Belgium, when more than a month of consecutive sick time of is taken, every day over the month is of a different type of work entry (sick time of without pay). This means that work entries relative to the same leave have different work entry types which was causing problems when checking the matching of the types. To fix this, a previous PR (https://github.com/odoo/odoo/pull/237829) made it so that if the internal_leaves computation returned empty, every leave was considered. Because of this some problems in the HK localization arose so we go back to the original code and we move the BE specific changes to the BE localization module. To do this, we move the logic in a function which we will override inside that module (see related Enterprise PR). Task: 5472538 Enterprise PR: https://github.com/odoo/enterprise/pull/105776 Forward-Port-Of: odoo/odoo#246116
This update fixes an issue where financial reports were inaccurate due to accounts lacking codes in company mappings. Now, the system automatically finds the correct code for these accounts across other companies, ensuring consolidated reports match expected financial figures. This improves the reliability of our reporting.
Original PR description
Description of the issue this commit addresses: When consolidating reports, any account that doesn't have a code on the consolidating company is filtered out of the consolidation. This will lead to amounts that do not match which should not happen. --- Desired behavior after this commit is merged: When an account should be used but is filtered out because of not having a code in the per company mapping, we try to find its code on any of the other companies he is and use that one as anchor in the consolidation. --- task-5911409 Forward-Port-Of: odoo/enterprise#107651
This update fixes an issue where stock deliveries weren't accurately reflecting the FIFO (First-In, First-Out) inventory valuation method. The previous process didn't properly account for quantities already delivered, leading to incorrect cost calculations. This change ensures that stock valuations align with the FIFO method, improving financial reporting accuracy.
Original PR description
Steps to reproduce: - Have a product valued in fifo - Create 3 PO for it, each for 1 qty of price 10, 20 and 30. - Confirm these PO & validate their receipts - Create 2 SO for this product, each for 1 qty - Confirm these SO & validate their deliveries together Issue: The value associated to the delivery moves (and so the cogs generated from them) is 10 for both. When calling `_action_done()` on the moves, we'll set the value of each move before moving them. To get the correct value from the fifo stack, we rely on the `qty_available` at the time. However, since we're going to set the value of multiple moves before validating them, the `qty_available` won't be updated between each call. opw-5359484 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#240866 Forward-Port-Of: odoo/odoo#238680
This update fixes a bug in the Swiss payroll calculations, ensuring the employer cost is accurately computed. Previously, the system incorrectly reported a zero employer cost due to a missing flag. This change ensures accurate payroll reporting for Swiss businesses.
Original PR description
The computation of the employer cost in Switzerland was wrong (always 0) because the rules didn't have the appears_on_employee_cost_dashboard flag set and were therefore not counted in the computation of the fiels. Furthermore we modify the override of the function used to compute the values of some fields, to add the correct computation of the employer cost. Task: 5354103 Forward-Port-Of: odoo/enterprise#106839
This update resolves an issue where creating scrap orders from the shopfloor view resulted in a traceback. The fix reintroduces a necessary method and corrects a display problem that incorrectly prompted users to add lot/serial numbers for non-trackable products like screws. This ensures scrap orders can be created smoothly.
Original PR description
Issue before this commit: ========================= Creating a scrap order from a specific workorder in the shopfloor view raises a traceback: `The method 'mrp.workorder.action_scrap' does not…
Issue before this commit: ========================= Creating a scrap order from a specific workorder in the shopfloor view raises a traceback: `The method 'mrp.workorder.action_scrap' does not exist.` Additionally, in the scrap form view, the `Lot/Serial Numbers field is displayed for non-tracked(e.g. consumables such as screw) products`, incorrectly prompting the user to add a lot/serial number. Steps to Reproduce: ========================= - Install the mrp module. - Create a Manufacturing Order for a product with at least one operation (e.g. Desk Combination). - Open the shopfloor view. - Enter a specific workcenter (e.g. Assembly 1). - Open the three-dot menu and create a scrap order. - Confirm the scrap order. - A traceback is raised. Cause of the issue: ========================= The method action_scrap was removed from mrp.workorder in [this PR](https://github.com/odoo/odoo/pull/210299), However, from the JavaScript side, the scrap option still triggers a call on the mrp.workorder model when the user clicks Scrap in the shopfloor view. With This Commit: ========================= Reintroduce the action_scrap method on mrp.workorder so users can correctly create scrap orders from a specific workcenter in the shopfloor view without triggering a traceback. Fix the visibility condition of lot_ids so the Lot/Serial Numbers field is hidden for non-tracked (consumable) products and is shown only for trackable products (lot/serial). Enterprise PR: https://github.com/odoo/enterprise/pull/108259 Task: 5958933
This update fixes an issue where deleting a partially signed offer would incorrectly delete the associated employee. The change ensures the employee record is only deleted when the offer is archived and the employee has no other active offers. This prevents data loss and maintains accurate employee records.
Original PR description
Version – saas-18.4 ### Issue: When an applicant has both a partially signed offer and a fully signed offer, deleting the partially signed one also deletes the employee that was created from the…
Version – saas-18.4 ### Issue: When an applicant has both a partially signed offer and a fully signed offer, deleting the partially signed one also deletes the employee that was created from the fully signed offer. ### Steps to Reproduce: - Create two offers for an applicant. - Fully sign the first offer and partially sign the second one. - Delete the partially signed offer. The employee created from the fully signed offer is also deleted. ### Cause: Due to this issue, the employee record is incorrectly deleted from the system, which is not expected behavior. ### Fix: Improved the employee deletion logic by deleting the employee only when: - the employee is archived, and - they do not have any other offers besides the one being deleted. ### Impact: The employee will no longer be deleted when another partially signed offer for the same applicant is removed. --- Task – 5347109 Forward-Port-Of: odoo/enterprise#108634 Forward-Port-Of: odoo/enterprise#100991
This update optimizes how Odoo synchronizes data between its database and IndexedDB, specifically addressing slow synchronization when dealing with large datasets like loyalty cards. This change improves the speed and responsiveness of adding products to the cart in the Point of Sale module, leading to a better user experience.
Original PR description
Before this commit, if a model had a large number of records, for example, loyalty card, the synchronization of IndexedDB could be slow, leading to performance issues when adding products to the cart. opw-5232087 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#250799 Forward-Port-Of: odoo/odoo#241373
This update fixes a RecursionError that occurred when producing large quantities of serial-tracked products. The issue stemmed from excessive recordset access during the splitting process of manufacturing orders. This change improves stability and reliability for users managing high-volume production runs.
Original PR description
**Issue** When producing a large number of serial-tracked products, a RecursionError can occur. **Steps to reproduce** - Create three products tracked by serial number (ensure MTO and Manufacture…
**Issue** When producing a large number of serial-tracked products, a RecursionError can occur. **Steps to reproduce** - Create three products tracked by serial number (ensure MTO and Manufacture routes are enabled). - Create a BoM for product A containing product B. - Create a BoM for product B containing product C. - Create a BoM for product C containing another product. - Create a manufacturing order of 100 units for product A and confirm it. - Go to the MO C and split into 100 mo - Go to the MO B and split into 100 mo -> RecursionError: maximum recursion depth exceeded. **Cause** While splitting, this method is called: https://github.com/odoo/odoo/blob/cda011dc8590773f6c3a26f4ae9d5242a3147024/addons/mrp/models/mrp_production.py#L2031 which ultimately calls: https://github.com/odoo/odoo/blob/cda011dc8590773f6c3a26f4ae9d5242a3147024/addons/stock/models/stock_move.py#L658-L661 This retriggers `_compute_packaging_uom_id` for all moves in `move_orig_ids` or `move_dest_ids`, and accessing the full recordsets causes recursive recomputation leading to a RecursionError. opw-5265424 Forward-Port-Of: odoo/odoo#247839
This update resolves a bug that caused a RecursionError when producing large quantities of serial-tracked products. The issue stemmed from an inefficient calculation process during order splitting, which triggered repeated data processing. This fix ensures stable production runs for high-volume manufacturing.
Original PR description
**Issue** When producing a large number of serial-tracked products, a RecursionError can occur. **Steps to reproduce** - Create three products tracked by serial number (ensure MTO and Manufacture…
**Issue** When producing a large number of serial-tracked products, a RecursionError can occur. **Steps to reproduce** - Create three products tracked by serial number (ensure MTO and Manufacture routes are enabled). - Create a BoM for product A containing product B. - Create a BoM for product B containing product C. - Create a BoM for product C containing another product. - Create a manufacturing order of 100 units for product A and confirm it. - Go to the MO C and split into 100 mo - Go to the MO B and split into 100 mo -> RecursionError: maximum recursion depth exceeded. **Cause** While splitting, this method is called: https://github.com/odoo/odoo/blob/cda011dc8590773f6c3a26f4ae9d5242a3147024/addons/mrp/models/mrp_production.py#L2031 which ultimately calls: https://github.com/odoo/odoo/blob/cda011dc8590773f6c3a26f4ae9d5242a3147024/addons/stock/models/stock_move.py#L658-L661 This retriggers `_compute_packaging_uom_id` for all moves in `move_orig_ids` or `move_dest_ids`, and accessing the full recordsets causes recursive recomputation leading to a RecursionError. opw-5265424 Forward-Port-Of: odoo/enterprise#106999
This update fixes an issue where the VAT Book download was only generating for the primary company. Now, when multiple branches with the same CUIT are selected, the VAT Book will correctly include data for all related branches. This ensures accurate tax reporting for businesses with multiple Argentinian branches.
Original PR description
#### Issues: VAT Book should download for all selected companies with same CUIT as the current one. #### Step to reproduce: - In a company in Argentina ("Parent Company") - Create a branch "Child…
#### Issues:
VAT Book should download for all selected companies with same CUIT as the current one.
#### Step to reproduce:
- In a company in Argentina ("Parent Company")
- Create a branch "Child Company A" with no CUID
- Create a branch "Child Company B" with a different CUID than parent
- Go to "Child Company A"
- Either:
- i. Select both "Parent Company" and "Child Company A" but not "Child Company B"
- ii. Select all 3 "Parent Company", "Child Company A" and "Child Company B"
- In Accounting > Report > Tax Return :
- Download the VAT Book (wheel > "VAT book(ZIP)")
#### Current behavior:
i. Get Invalid Operation
ii. Download the VAT Book for "Parent Company" only
#### Expected behavior:
- Download the VAT Book for both "Parent Company" and "Child Company A"
A previous call to get_options provide the client with the info about which selected companies have the same CUIT as the current company. Therefore companies in the options are the correct ones.
opw-5385585
Forward-Port-Of: odoo/enterprise#108466
Forward-Port-Of: odoo/enterprise#101898This update resolves an issue preventing portal users from accessing documents with restricted permissions. A recent change introduced an access error when attempting to view document owners, specifically for users without internal access. The fix replaces a problematic widget and restricts the 'View Profile' button to internal users, ensuring stable document access for all portal users.
Original PR description
Steps to reproduce: 1. Create a fully restricted folder in Documents. 2. Share it with a portal user as an editor. 3. Insert a file into the folder. 4. Log in as the portal user and access the…
Steps to reproduce: 1. Create a fully restricted folder in Documents. 2. Share it with a portal user as an editor. 3. Insert a file into the folder. 4. Log in as the portal user and access the Documents portal. 5. The view crashes and the file is not visible. Cause: Recent changes added `write_date` to the `many2one_avatar_user` widget for image cache-busting. When portal views load, the frontend requests this field for the document's `owner_id`. Since portal users lack read access to `res.users`, this triggers an Access Error and crashes the view. Furthermore, clicking the avatar opens a popover with a "View Profile" button that also crashes for portal users, as they cannot access backend form views. Solution: 1. Register a new `many2one_avatar_user_no_unique_cache` widget that inherits the standard avatar but drops the `write_date` requirement. 2. Apply this widget to the `owner_id` field in Documents portal views to prevent the ACL error while keeping the avatar visible. 3. Update the avatar card popover to only show the "View Profile" button if the current user is internal (`user.isInternalUser`). Task-5977195
This update resolves an issue where the system incorrectly identified the currency of multiple journals with the same IBAN. The fix ensures that CODA transactions are now accurately routed to the correct journal based on its currency, improving financial reporting accuracy. This addresses a previous bug impacting multicurrency accounting.
Original PR description
When having multiple journals with the same IBAN, but different currencies, upon fetching and dispatching the CODA into the right journals, the currency of the journal was not correctly taken into account as the condition was incorrect. This commit fixes this condition which was introduced in [^1] such that the right journal, with the right currency is correctly chosen. [^1]: 4fda4fb5353ed9c14dbc023ab7d07fabd3c06e98 opw-5723017 Forward-Port-Of: odoo/enterprise#108677
This update fixes an issue where the salary calculator incorrectly calculated pay based on the selected work schedule (e.g., 40h/week vs. 20h/week). The change ensures the calculator now accurately reflects the chosen schedule when simulating employee pay, improving payroll accuracy. This resolves a discrepancy in how the system handled different work patterns.
Original PR description
Steps to reproduce: 1- Go to Payroll > Employees > Salary calculator 2- Put a yearly cost of 10000 3- Select the "40h/week calendar" 4- Check the yearly cost 5- Change to "20h/week calendar" Cause of the bug: _get_version inside ContractSalaryOffer would take the default calendar from the version if it exists (in our case it will always be the full time for the simulation employee) Fix done: Keep the condition as it is for normal offers, and for simulation offers change the default to the selected resource calendar task-5431216 Forward-Port-Of: odoo/enterprise#108572 Forward-Port-Of: odoo/enterprise#103159
This update fixes an issue where invoicing closed POS orders with stock items incorrectly doubled-debited the accounting account. The change ensures the reversal move accurately neutralizes stock valuation, improving invoice processing accuracy. This resolves a discrepancy in how stock adjustments are handled during invoicing.
Original PR description
When invoicing a pos order from a closed session, we create a reversal move to "neutralize" the invoice. If the order contained storable products, the part of the reversal move that should neutralize the stock valuation was wrong. It would instead debit the same account two times. Steps to reproduce: ------------------- * Create a storable product with a cost price different than 0 and a category with automated inventory valuation * Create a pos order with that product, validate it and close the session * Invoice the order from the backend > Observation: The reversal move lines that should neutralize the stock valuation credit and debit the same account as the invoice. Why the fix: ------------ After the `stock.valuation.layer` was removed, the value of the stock move are now directly stored on the `stock.move`. But they are not signed so we need to rely on `is_out` to determine if we should inverse the value or not. opw-5359646 Forward-Port-Of: odoo/odoo#247863
This update resolves an issue preventing child companies from utilizing their parent's SDI proxy user. The original problem stemmed from a missed update during a recent software release, causing errors when sending invoices from child companies. This fix ensures seamless integration with the parent proxy for improved efficiency.
Original PR description
This fix implements the same change made in PR #209120 to allow a child company to use the parent proxy user. It seems the record rules modification was missed during the FW, causing issues for clients using this feature in 18.2+ Steps to reproduce: - Create company A and a child company B sharing the same fiscal and VAT information - Register company A in the SDI (creating a proxy user) - Go to company B and try to send an invoice. You will get an error because Odoo will try to create a new proxy user as the parent proxy is currently inaccessible due to record rule constraints. Ticket [link](https://www.odoo.com/odoo/project.task/5927104) opw-5927104 Forward-Port-Of: odoo/odoo#250780 Forward-Port-Of: odoo/odoo#249821
This update resolves access issues preventing basic sale, stock, and purchase flows for users with limited permissions. The changes ensure these users can correctly create and manage invoices, purchase orders, and stock deliveries, improving usability for standard users.
Original PR description
*: account,sale,stock_delivery Since [19.0](https://github.com/odoo/odoo/pull/217277#issue-3198442339), read access rights are checks on comodels when trying to read the value of a many2many fields…
*: account,sale,stock_delivery Since [19.0](https://github.com/odoo/odoo/pull/217277#issue-3198442339), read access rights are checks on comodels when trying to read the value of a many2many fields you have read acccess to. This change highlight numerous access right issues in basic flows for users with minimal access. Here is a list of examples (each performed with every other access rights disabled): - With a `stock user`, open the delivery list or form view #### > Access error - With a `purchase user` create and confirm a PO > Upload Bill #### > the Bill will be created but an access error will prevent the draft bill from opening. - With a `sale user` create and confrim an SO > Create invoice #### > the invoice will be created but an access error will prevent the draft invoice from opening. ## Solutions: ### Use case: Open an invoice (`acount.move`) linked to one of your SO/PO with a basic `sale`/`purchase` user: 1) For basic `sale` and `purchase` users to be able to open the `account.move` Form on which they have read, update, create, delete access rights, it is necessary for the `payment_count` to be compute sudo since it is used in the view: https://github.com/odoo/odoo/blob/4ea42f8b16a8619cced4255f5bba8de6427345b7/addons/account/views/account_move_views.xml#L859 And these users do not have the read access of the `account.payment` model. Similarily the `_compute_asset_ids` needs to be compute sudo because it relies on the related `asset_ids` of `account.move.line`s or on values of these `account.asset`s for which the users shoud not have read access: https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/models/account_move.py#L27-L30 https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/models/account_move.py#L317-L323 and the `asset_ids`, `count_asset`, `asset_id_display_name` and `draft_asset_exists` are all used in the view. #### Note for master: IMO, the `asset_ids` field of the `account.move` model should probably be in a separate compute to not be computed in sudo and removed from the views as it is currently used only to determine if there is or not `asset_ids`. An information that is provided by the `count_asset`. E.G. here: https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/views/account_move_views.xml#L10 https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/views/account_move_views.xml#L35-L40 https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/views/account_move_views.xml#L44-L52 2) For basic `purchase` users to open the invoice linked to one of their PO, it is necessary that the `sale_order_count` is computed in sudo as they do not have access to the related `sale_line_ids` field and the field is used in the `account.move` form: https://github.com/odoo/odoo/blob/4ea42f8b16a8619cced4255f5bba8de6427345b7/addons/sale/models/account_move.py#L46-L49 https://github.com/odoo/odoo/blob/4ea42f8b16a8619cced4255f5bba8de6427345b7/addons/sale/views/account_views.xml#L53 ### Use case: Open a `stock.picking` views as basic stock user: 3) The basic `stock` users have a read access on the `delivery.carrier` model and should also on the related `delivery.zip.prefix` and `delivery.price.rule` models. First as it make sense functionally but also as it currently blocks them on basic flows. For instance basic stock users can not open the `stock.picking` list or form view as the `carrier_id` is part of these view: https://github.com/odoo/odoo/blob/4ea42f8b16a8619cced4255f5bba8de6427345b7/addons/stock_delivery/views/delivery_view.xml#L125-L132 This is problematic as this field has a domain relying on the related `allowed_carrier_ids` field: https://github.com/odoo/odoo/blob/93fa6d9fff63534cfa9251e21fc82797d8b83468/addons/stock_delivery/models/stock_picking.py#L23-L24 As such, when the view is opened, the related field needs to be read. However, the `_compute_allowed_carrier_ids` fails if you do not have read access rights on the `delivery.zip.prefix` model: https://github.com/odoo/odoo/blob/93fa6d9fff63534cfa9251e21fc82797d8b83468/addons/delivery/models/delivery_carrier.py#L198 https://github.com/odoo/odoo/blob/93fa6d9fff63534cfa9251e21fc82797d8b83468/addons/delivery/models/delivery_carrier.py#L70-L72 Similarily `delivery.price.rule` model should be readable for `stock` users in order to be able to get be able to rely on the `price_rule_ids` when necessary such as here: https://github.com/odoo/odoo/blob/93fa6d9fff63534cfa9251e21fc82797d8b83468/addons/delivery/models/delivery_carrier.py#L492-L496 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr opw-5461135 opw-5417749 Forward-Port-Of: odoo/odoo#249138 Forward-Port-Of: odoo/odoo#247531
This change resolves access errors preventing basic sales, stock, and purchase flows for users with limited permissions. The update ensures these users can correctly interact with key documents like invoices and purchase orders, improving usability and preventing workflow disruptions.
Original PR description
*: account_asset, sale_lazada Since [19.0](https://github.com/odoo/odoo/pull/217277#issue-3198442339), read access rights are checks on comodels when trying to read the value of a many2many fields…
*: account_asset, sale_lazada Since [19.0](https://github.com/odoo/odoo/pull/217277#issue-3198442339), read access rights are checks on comodels when trying to read the value of a many2many fields you have read acccess to. This change highlight numerous access right issues in basic flows for users with minimal access. Here is a list of examples (each performed with every other access rights disabled): - With a `stock user`, open the delivery list or form view #### > Access error - With a `purchase user` create and confirm a PO > Upload Bill #### > the Bill will be created but an access error will prevent the draft bill from opening. - With a `sale user` create and confrim an SO > Create invoice #### > the invoice will be created but an access error will prevent the draft invoice from opening. ## Solutions: ### Use case: Open an invoice (`acount.move`) linked to one of your SO/PO with a basic `sale`/`purchase` user: 1) For basic `sale` and `purchase` users to be able to open the `account.move` Form on which they have read, update, create, delete access rights, it is necessary for the `payment_count` to be compute sudo since it is used in the view: https://github.com/odoo/odoo/blob/4ea42f8b16a8619cced4255f5bba8de6427345b7/addons/account/views/account_move_views.xml#L859 And these users do not have the read access of the `account.payment` model. Similarily the `_compute_asset_ids` needs to be compute sudo because it relies on the related `asset_ids` of `account.move.line`s or on values of these `account.asset`s for which the users shoud not have read access: https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/models/account_move.py#L27-L30 https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/models/account_move.py#L317-L323 and the `asset_ids`, `count_asset`, `asset_id_display_name` and `draft_asset_exists` are all used in the view. #### Note for master: IMO, the `asset_ids` field of the `account.move` model should probably be in a separate compute to not be computed in sudo and removed from the views as it is currently used only to determine if there is or not `asset_ids`. An information that is provided by the `count_asset`. E.G. here: https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/views/account_move_views.xml#L10 https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/views/account_move_views.xml#L35-L40 https://github.com/odoo/enterprise/blob/06cf3f2b6663c61f1fcc158678dfb1fa43ece4e1/account_asset/views/account_move_views.xml#L44-L52 2) For basic `purchase` users to open the invoice linked to one of their PO, it is necessary that the `sale_order_count` is computed in sudo as they do not have access to the related `sale_line_ids` field and the field is used in the `account.move` form: https://github.com/odoo/odoo/blob/4ea42f8b16a8619cced4255f5bba8de6427345b7/addons/sale/models/account_move.py#L46-L49 https://github.com/odoo/odoo/blob/4ea42f8b16a8619cced4255f5bba8de6427345b7/addons/sale/views/account_views.xml#L53 ### Use case: Open a `stock.picking` views as basic stock user: 3) The basic `stock` users have a read access on the `delivery.carrier` model and should also on the related `delivery.zip.prefix` and `delivery.price.rule` models. First as it make sense functionally but also as it currently blocks them on basic flows. For instance basic stock users can not open the `stock.picking` list or form view as the `carrier_id` is part of these view: https://github.com/odoo/odoo/blob/4ea42f8b16a8619cced4255f5bba8de6427345b7/addons/stock_delivery/views/delivery_view.xml#L125-L132 This is problematic as this field has a domain relying on the related `allowed_carrier_ids` field: https://github.com/odoo/odoo/blob/93fa6d9fff63534cfa9251e21fc82797d8b83468/addons/stock_delivery/models/stock_picking.py#L23-L24 As such, when the view is opened, the related field needs to be read. However, the `_compute_allowed_carrier_ids` fails if you do not have read access rights on the `delivery.zip.prefix` model: https://github.com/odoo/odoo/blob/93fa6d9fff63534cfa9251e21fc82797d8b83468/addons/delivery/models/delivery_carrier.py#L198 https://github.com/odoo/odoo/blob/93fa6d9fff63534cfa9251e21fc82797d8b83468/addons/delivery/models/delivery_carrier.py#L70-L72 Similarily `delivery.price.rule` model should be readable for `stock` users in order to be able to get be able to rely on the `price_rule_ids` when necessary such as here: https://github.com/odoo/odoo/blob/93fa6d9fff63534cfa9251e21fc82797d8b83468/addons/delivery/models/delivery_carrier.py#L492-L496 opw-5461135 opw-5417749 Forward-Port-Of: odoo/enterprise#107732 Forward-Port-Of: odoo/enterprise#106694
This update ensures self-order transactions in Odoo (including online payments, restaurants, and standard self-order) now use the same data validation rules as regular point-of-sale orders. This enhances data accuracy and reliability, reducing potential errors during self-service ordering processes.
Original PR description
*: pos_online_payment_self_order, pos_restaurant, pos_self_order This commit improves the data validation of pos self order by using the same validation as the one used for regular pos order. Forward-Port-Of: odoo/odoo#250410 Forward-Port-Of: odoo/odoo#249455
This update fixes a data validation issue within the self-order point-of-sale system. By aligning the validation rules with those used for standard point-of-sale orders, the system now handles self-order transactions more reliably and accurately. This ensures data integrity and a smoother customer experience.
Original PR description
This commit improves the data validation of pos self order by using the same validation as the one used for regular pos order. Forward-Port-Of: odoo/enterprise#108535 Forward-Port-Of: odoo/enterprise#108224
This update fixes an error in how payroll rates were calculated for employees on attendance-based contracts. Previously, rates were incorrectly based on actual work hours, not the planned working schedule. Now, rates are accurately determined using the employee's working schedule, ensuring correct compensation.
Original PR description
Step to Reproduce: - install UAE Payroll localization and attendance - create employee and running employee contract and give basic salary, housing, transportation and other allowance. - work entry…
Step to Reproduce: - install UAE Payroll localization and attendance - create employee and running employee contract and give basic salary, housing, transportation and other allowance. - work entry source should be attendance - create a payslip and compute sheet. Issue: - The values for payslip lines are not as expected. - The rate per hour for basic salary , housing, transportation and other allowances was being calculated based on employee's attendance work entries, not the planned working schedule. Reason: - When using attendance-based contracts, the hourly rates for basic salary, housing, transportation, and other allowances should be calculated based on the working schedule's hours per day, if a working schedule is available. Solution: - Instead of sum_worked_hours which takes working hours of employee's work entries, use total_number_of_days multiplied by the hours per day from the working schedule. task-5270185 Forward-Port-Of: odoo/enterprise#108863 Forward-Port-Of: odoo/enterprise#103282
This update fixes an issue where dependent salary rules weren't appearing in the employee input selection. The change ensures that all relevant rules, including dependent ones, are displayed when adding inputs, streamlining payroll configuration for users. This resolves a previous limitation in version 19.0.
Original PR description
Problem ------------------ The salary inputs selection widget only displays the main salary rule, not the dependent rules, so when a new dependent rule is created after the main one was added to the…
Problem ------------------ The salary inputs selection widget only displays the main salary rule, not the dependent rules, so when a new dependent rule is created after the main one was added to the employee form, it is not possible to select the the new rule to display. Navigation: 1. Payroll > Configuration > Rules > New > Condition Based On: Salary Input > Input On: Employee > Save 2. Employees > Select Employee > Payroll > Add Inputs > Select Rule > Save 3. Configuration > Rules > New > Condition Based on: Salary Input > Input On: Employee > Depends On: Previous Rule > Save 4. Employees > Select Employee > Payroll > Add Inputs > New Rule is not available Objective ---------------------- Version 19.0 doesn't filter out existing rules, so it is possible to select the prerequisite rule again and add the new dependent rule, but later commits changed the search domain to filter out inputs that were already selected. Some of the changes should probably have been included in the 19.0 version. Need to back port the changes and edit the search domain to show dependent rules that have not been selected yet. Solution --------------------------- Option B from the task specifications to show the dependent salary rules when "Add Inputs" is clicked if it's not already displayed even if the prerequisite rule is displayed. Edited the payroll structure search domain to find rules that are not displayed and either do not have prerequisites OR have a prerequisite that is already displayed. Task: 5942461 Forward-Port-Of: odoo/enterprise#108985 Forward-Port-Of: odoo/enterprise#107719
This update resolves an issue preventing the SAF-T report from correctly identifying suppliers for fixed assets. The fix ensures that supplier information is accurately retrieved by expanding the data source to include depreciation lines, addressing a problem caused by bills being posted in a previous month.
Original PR description
**Steps to reproduce:** - Install l10n_ro_saft - Switch to a Romanian company (e.g. RO Company) - Create an asset model: * Method: Straight Line * Duration: 12 Months - Configure a "Fixed Assets"…
**Steps to reproduce:** - Install l10n_ro_saft - Switch to a Romanian company (e.g. RO Company) - Create an asset model: * Method: Straight Line * Duration: 12 Months - Configure a "Fixed Assets" account: * Automate Asset: Create and validate * Asset Model: [the asset model created above] - Create a bill: * Vendor: [create a new vendor] * Bill Date: [last month] * Invoice Line: [A line with the fixed asset account] - Confirm the bill - Go to "Accounting / Reporting / Audit Reports / General Ledger" - Select the current month (The fixed asset account should be present) - In the cog menu, select "SAF-T (D406 Asset Declaration)" **Issue:** A traceback is raised while trying to display the name of a supplier. **Cause:** To display the supplier name of an asset, a dict having the id of the customer or supplier as key (i.e. partner_detail_map) is used. This dict is build by getting the list of all partners linked to a posted journal item on an asset (or liability) account in the period of the report. In this case, it's the current month. However, the created bill has been posted the month before. So no journal item is found for the vendor that has been created just for the bill and therefore there is no key for him in the dict, which leads to the error when trying to get the id of the supplier of the asset in the dict. **Solution:** Instead of just fetching the posted entries linked to a receivable or payable account in order to get the list of the potential customers and suppliers, we also fetch the depreciation lines that are linked to an asset account and can still be in draft. opw-5499918 Forward-Port-Of: odoo/enterprise#109014 Forward-Port-Of: odoo/enterprise#105987
This update improves the handling of HSN (HSN/SAC) codes for Indian Point of Sale (POS) transactions. Now, the system checks for missing HSN codes during the POS closing process and prompts the user to complete them before generating the final report, preventing inaccurate GST reporting.
Original PR description
Before this PR: - POS order validation did not enforce the presence of HSN/SAC codes on products. Products without HSN could be sold via POS, and missing HSN values were only detected downstream during GST reporting, after the POS closing entry was generated. After this PR: - HSN/SAC validation is deferred to POS session closing. During the close flow, POS order lines with GST taxes and missing HSN/SAC codes are detected, and the user is required to complete the missing values before the closing journal entry is generated. POS order validation remains unblocked. Why: For Indian localization, POS closing entries are reported in GSTR-1, Table 12 (B2C HSN Summary). Missing HSN/SAC values on POS order lines result in incomplete or incorrect GST reporting. Deferring validation to session closing ensures all required HSN values are captured and propagated into the closing entry, while preserving the POS sales workflow. Task Id: 5404786 Forward-Port-Of: odoo/odoo#241986
This update corrects a previous issue where NSSF Tier 2 and Pension Contribution deductions weren't consistently shown on payslips, even when correctly reported. The fix ensures all contributions are accurately displayed on the payslip, providing greater transparency and accuracy for payroll reporting in Kenya.
Original PR description
Issue: - NSSF Tier 2 and Pension Contribution salary rules only appeared on the payslip and salary computation when remitted to NSSF. - When Tier 2 was remitted to insurance, NSSF Tier 2 deductions were missing from the payslip display, even though reporting was correct. - Similarly, Pension Contribution was missing from the payslip when pension was remitted to insurance instead of the pension authority. Fix: - Updated the NSSF Tier 2 salary rule condition to ensure it always appears in salary computation and payslip. - Updated the Pension Contribution salary rule to ensure it is always displayed on the payslip even when remitted to insurance. - Adapted the NSSF Report as well. task-5896380 Forward-Port-Of: odoo/enterprise#106173
This update resolves a critical issue where portal users accessing documents would experience view crashes due to access restrictions. The fix prevents errors by modifying how avatar widgets handle user permissions, ensuring stable document viewing for all portal users. This improves the overall user experience and prevents data access problems.
Original PR description
Steps to reproduce: 1. Create a fully restricted folder in Documents. 2. Share it with a portal user as an editor. 3. Insert a file into the folder. 4. Log in as the portal user and access the…
Steps to reproduce: 1. Create a fully restricted folder in Documents. 2. Share it with a portal user as an editor. 3. Insert a file into the folder. 4. Log in as the portal user and access the Documents portal. 5. The view crashes and the file is not visible. Cause: Recent changes added `write_date` to the `many2one_avatar_user` widget for image cache-busting. When portal views load, the frontend requests this field for the document's `owner_id`. Since portal users lack read access to `res.users`, this triggers an Access Error and crashes the view. Furthermore, clicking the avatar opens a popover with a "View Profile" button that also crashes for portal users, as they cannot access backend form views. Solution: 1. Register a new `many2one_avatar_user_no_unique_cache` widget that inherits the standard avatar but drops the `write_date` requirement. 2. Apply this widget to the `owner_id` field in Documents portal views to prevent the ACL error while keeping the avatar visible. 3. Update the avatar card popover to only show the "View Profile" button if the current user is internal (`user.isInternalUser`). Task-5977195
This update enhances the accuracy of payment reference validation by tailoring checks to the bank account's country. Previously, a single check applied to all countries could lead to incorrect validations. Now, the system verifies reference formats against the specific country of the bank account, falling back to a standard ISO 11649 check if the country isn't supported.
Original PR description
Currently, when initiating a payment, we check if the reference is a structured one by using `is_valid_structured_reference` which checks the validity of the structure accross all supported countries. This can lead to issues when it matches formats accepted by other countries but not the one of the bank account. With this commit, we replace this check by a call to a new function that checks the structure validity according to the country of the bank account, with a fallback to the generic check (ISO 11649) if the country is not supported. opw-5387269 Forward-Port-Of: odoo/odoo#249469 Forward-Port-Of: odoo/odoo#248194
This update ensures that fast payment orders are correctly validated and generate a 'pay later' line alongside the fast payment, mirroring the behavior when settling invoices through the standard payment screen. Previously, fast payments were missing this crucial balancing line. The fix moves the necessary validation code to ensure consistent order validation regardless of the payment flow.
Original PR description
Steps to reproduce ------------------ 1. Install `pos_settle_due` 2. Enable "One-Click Payment" from the configs, and make sure it has some valid payment methods (Cash, Card, etc). 3. Open PoS, and…
Steps to reproduce ------------------ 1. Install `pos_settle_due` 2. Enable "One-Click Payment" from the configs, and make sure it has some valid payment methods (Cash, Card, etc). 3. Open PoS, and click "Settle Invoices" for a client having a "Total Due" > 0 4. Select the invoice(s) 5. Fast settle the invoice by directly paying on the product screen, using one of the fast payment methods on the bottom. -> The order is payed, however, it only has the fast payment line, while it should also have an additional equivalent "pay later" line, with a negative amount, balancing the amount payed with the fast payment method. Why the issue ------------- If we settled this invoice from the payment page, this issue does not happen, i.e. an equivalent "pay later" payment line is created. That additional "pay later" line is created when calling the `validateOrder` method on the `payment_screen`, which in `pos_settle_due`, is overriden to also add the "pay later" payment lines under certain conditions. After introducing the "One-Click Payment" feature in #216523, we needed to be able to validate the order in two different places: 1. On the payment screen, that was already taken care of, by the method `validateOrder` mentioned just above, that is normal validation. 2. On the products screen, when using fast payment, that is fast validation. For that reason, the validation code has been moved from the payment screen to the class `OrderPaymentValidation` which will be used by the two flow: the normal validation and the fast validation. However, we have forgot to move the `pos_settle_due` specific validation code from payment_screen to the new `OrderPaymentValidation`, hence, the `pos_settle_due` validation that creates the "pay later" PL is only executed from the payment_screen, never from fast validation. The fix ------- Now, we move the `pos_settle_due` validation code from `payment_screen` to an override of `OrderPaymentValidation` so it's executed when for both normal and fast validation. Notes ----- - We keep the methods in `payment_screen` for backward compatibility, they will be removed in master. - We replace the usage of `props.isDepositOrder` in the `payment_screen` with `order.is_settling_account`, as they will have both the same value, but `order.is_settling_account` is available on the order, so it can be used for both normal and fast flows, while `props.isDepositOrder` was only available in the payment screen during normal valuation. On master, we can remove the prop `isDepositOrder` in favor of `order.is_settling_account === true`. opw-5488587 Forward-Port-Of: odoo/enterprise#108396 Forward-Port-Of: odoo/enterprise#105660
This update fixes an issue where incorrect company registry information was being used on PEPPOL invoices. Currently, the system doesn't automatically verify company registry details, leading to potential errors. This change ensures invoices comply with PEPPOL standards by correctly reflecting the company registry number.
Original PR description
We expect people to put BCE number in the company registry. But it is not enforced client-side, resulting in invoices in error. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#251272 Forward-Port-Of: odoo/odoo#251168