Monday, March 24, 2025
42 changes · saas-18.1
Resolved issues and error corrections
Order dates and times in Point of Sale sessions now display using the user's configured time zone instead of GMT/UTC. This prevents confusion for staff reviewing orders and makes session records easier to interpret accurately.
Original PR description
The date and time displayed in the order section of a POS session were always shown in GMT, ignoring the user's time zone.  opw-4416447 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Point of Sale receipts now use the available company name when building the receipt header. This prevents the company name from being missing or causing issues after a recent receipt data change, helping customers receive correctly branded receipts.
Original PR description
Issue: order.company.partner_id[1] is undefined during the change to use `order` object as props component. in this PR: #189446 Purpose of this PR: use order.company.name if it exists to include into the receipt header. opw-4654437 I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Miscellaneous changes
When putting products in pack from the picking FormView `picking._put_in_pack` is eventually called. This method does a few things, amongst those is a write on picking.move_line_ids and another is the creation of a new package level. Both of these can be a bit slow when the picking's number of move_lines gets bigger. This can happen for SN tracked products for instance. In a database with 1800 move_lines, each _put_in_pack call takes around 1.5s, which can become cumbersome when customers are u
Original PR description
When putting products in pack from the picking FormView `picking._put_in_pack` is eventually called. This method does a few things, amongst those is a write on picking.move_line_ids and another is…
When putting products in pack from the picking FormView `picking._put_in_pack` is eventually called. This method does a few things, amongst those is a write on picking.move_line_ids and another is the creation of a new package level. Both of these can be a bit slow when the picking's number of move_lines gets bigger. This can happen for SN tracked products for instance. In a database with 1800 move_lines, each _put_in_pack call takes around 1.5s, which can become cumbersome when customers are using multiple packages. Most of this slowness is coming from two things. The first one is stock.quants synchronization when writing on move.lines. The propose solution in this commit is to skip this synchronization when the only value in the vals dict is `result_package_id`. We can do that because this value is not used in the first quants synchronization of the write method. The second one is a write of `location_dest_id` on the picking's move_ids and move_line_ids in `package_level.create`. Since the package_level.location_dest_id value is coming from the `move_line_ids` value in `_put_in_pack`, this commit adds a context key to skip this write in case we're coming from `picking._put_in_pack` #### speedup In a 17.4 customer database, putting in pack for a picking with 1800 move_lines: 1.5s -> 90ms --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#200767
computed by dedicated method _compute_reference when a single invoice is overdue. Forward-Port-Of: odoo/odoo#202701
Original PR description
computed by dedicated method _compute_reference when a single invoice is overdue. Forward-Port-Of: odoo/odoo#202701
Currently, when ordering on kiosk a menu combo, if you do not select sides it will crash when adding it to the cart Steps to reproduce: ------------------- * Open kiosk * Select burger Menu Combo * Select Cheese burger * DO NOT select sides * Select Next button * Add drink * Add to cart > Observation: White screen crashes Why the fix: ------------ The crash is ultimately cause by a undefined `attribute_value_ids` https://github.com/odoo/odoo/blob/ea67d5ad5f81c7eae85cff352bcc7529
Original PR description
Currently, when ordering on kiosk a menu combo, if you do not select sides it will crash when adding it to the cart Steps to reproduce: ------------------- * Open kiosk * Select burger Menu Combo * Select Cheese burger * DO NOT select sides * Select Next button * Add drink * Add to cart > Observation: White screen crashes Why the fix: ------------ The crash is ultimately cause by a undefined `attribute_value_ids` https://github.com/odoo/odoo/blob/ea67d5ad5f81c7eae85cff352bcc75290053ba20/addons/pos_self_order/static/src/app/self_order_service.js#L263-L266 If we compare the behavior of the same product, outside a combo, we are not allowed to add the product to the cart if we did not select sides. We will now have a consistent behavior with/without combo. opw-4516061 Forward-Port-Of: odoo/odoo#201004
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#200348 Forward-Port-Of: odoo/odoo#198760
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#200348 Forward-Port-Of: odoo/odoo#198760
This reference should only be shown in the backend. Forward-Port-Of: odoo/odoo#202862
Original PR description
This reference should only be shown in the backend. Forward-Port-Of: odoo/odoo#202862
Issue ===== When product's code is computed, which is depend of the product's suppliers since each supplier can have a specific code, the first supplier is taken regardless if this supplier info is specific to another product variant which can cause to use the wrong code if there is multiple supplier with the same vendor but for different variants of the same product template. How to reproduce ================ 1. Install Puchase and Barcode; 2. Create a product with at least 2 variants;
Original PR description
Issue ===== When product's code is computed, which is depend of the product's suppliers since each supplier can have a specific code, the first supplier is taken regardless if this supplier info is…
Issue ===== When product's code is computed, which is depend of the product's suppliers since each supplier can have a specific code, the first supplier is taken regardless if this supplier info is specific to another product variant which can cause to use the wrong code if there is multiple supplier with the same vendor but for different variants of the same product template. How to reproduce ================ 1. Install Puchase and Barcode; 2. Create a product with at least 2 variants; 3. In the "Purchase" tab of this product, add two vendor pricelists with the same vendor but each for a different product variant and each with a different code; 4. Go in Purchase, create a new RFQ for this vendor, add a PO line for each variant and confirm the order; 5. Go in Barcode and open the PO's receipt -> You can see both lines have the same vendor's code (from the first pricelist) regardless the pricelist's product variant. Cause of the issue ================== In `_compute_product_code`, it uses the first product (template) supplier info regardless the product variant. Solution ======== In `_compute_product_code`, we skip a supplier info if it concerns another variant, and we break the supplier info loop only if it concerns the current product variant. Miscellaneous ============= The check of the `product.supplierinfo` `read` access right is moved outside of the loop so it is done only one time. [OPW-4589073](https://www.odoo.com/odoo/project/49/tasks/4589073) Forward-Port-Of: odoo/odoo#202592 Forward-Port-Of: odoo/odoo#201753
Description: ------------ Following commit 4e7b5e44b292dc41217e4c50048b8bb8408246f5, the list view for bills now shows a colored highlight on the bill's reference if there is a potential duplicate, and the matching on the invoice date was relaxed to include potential bills from the same year. This caused a performance regression, as the index on `invoice_date` could no longer be used since the year is now extracted from it. This patch adds a partial 'btree' index on the `ref` field speci
Original PR description
Description: ------------ Following commit 4e7b5e44b292dc41217e4c50048b8bb8408246f5, the list view for bills now shows a colored highlight on the bill's reference if there is a potential duplicate,…
Description: ------------ Following commit 4e7b5e44b292dc41217e4c50048b8bb8408246f5, the list view for bills now shows a colored highlight on the bill's reference if there is a potential duplicate, and the matching on the invoice date was relaxed to include potential bills from the same year. This caused a performance regression, as the index on `invoice_date` could no longer be used since the year is now extracted from it. This patch adds a partial 'btree' index on the `ref` field specifically for bills, as it is the most discriminatory factor when identifying potential duplicates. Benchmark: ---------- On a database with 6M `account_move` records, 230k of which are `'in_invoice'` & `'in_refund'`, `_fetch_duplicate_reference`, triggered when opening the list view of bills, took: | Before | After | Speedup | |--------|-------|---------| | 19.8s | 20ms | 990x | --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202923
- Automatically assigns the outstanding account for payment methods using bank journals. task-id: 4600008 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#199787
Original PR description
- Automatically assigns the outstanding account for payment methods using bank journals. task-id: 4600008 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#199787
Before this commit: ------------------------- When increasing the quantity of a combo product before adding it to the cart, only `1 unit` was added due to a hardcoded quantity value. After this commit: ----------------------- - The hardcoded quantity of `1` was removed. - The selected quantity is now correctly added to the cart, preserving user input. Task-4592610 Forward-Port-Of: odoo/odoo#202301 Forward-Port-Of: odoo/odoo#199160
Original PR description
Before this commit: ------------------------- When increasing the quantity of a combo product before adding it to the cart, only `1 unit` was added due to a hardcoded quantity value. After this commit: ----------------------- - The hardcoded quantity of `1` was removed. - The selected quantity is now correctly added to the cart, preserving user input. Task-4592610 Forward-Port-Of: odoo/odoo#202301 Forward-Port-Of: odoo/odoo#199160
Steps to reproduce: - insert a line chart into a spreadsheet with the horizontal axis being a time axis - ensures a domain is applied such that at least some past data is excluded - open the configuration side panel - check the "Cumulative data" checkbox => the chart doesn't take into account past data. When reloading it works. opw-4646477 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202841 Forward-Port-Of:
Original PR description
Steps to reproduce: - insert a line chart into a spreadsheet with the horizontal axis being a time axis - ensures a domain is applied such that at least some past data is excluded - open the configuration side panel - check the "Cumulative data" checkbox => the chart doesn't take into account past data. When reloading it works. opw-4646477 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202841 Forward-Port-Of: odoo/odoo#202746
Follow-up of https://github.com/odoo/odoo/pull/194593 This PR added test coverage for the fix, but it failed at the last step '.o_menu_brand' to confirm the quotation. The intent is to save to quotation, but it relies on implicit action to quit (and save) the record from the app icon, which acts as a "go to main page of app". This button is not present in tours for some reasons, hence the step failing. This commit fixes it by manually confirming the quotation by clicking on the dedicate
Original PR description
Follow-up of https://github.com/odoo/odoo/pull/194593 This PR added test coverage for the fix, but it failed at the last step '.o_menu_brand' to confirm the quotation. The intent is to save to quotation, but it relies on implicit action to quit (and save) the record from the app icon, which acts as a "go to main page of app". This button is not present in tours for some reasons, hence the step failing. This commit fixes it by manually confirming the quotation by clicking on the dedicated button, which is present in practice and in the tour. runbot-161274 In practice  In tour <img width="558" alt="Screenshot 2025-03-21 at 11 13 11" src="https://github.com/user-attachments/assets/8013a70a-0a0a-4a73-8820-d49678af84a5" /> Forward-Port-Of: odoo/odoo#202857
Follow-up of https://github.com/odoo/odoo/pull/200310 PR above made a small typo: it removed `isCategoryOpen` which was alias for `thread.discussAppCategory.open` in template, but this was still mistakenly used in the `isFirst` props of a sub-thread template. As a result, the list of pinned thread was not shown correctly, as all items we wrongly flagged as the first item. Before / After   Forward-Port-Of: odoo/odoo#202978
## Pull Request HOOT (PRHOOT) 29 This pull requests brings various improvements and fixes to Hoot and the Odoo unit test ecosystem. See the different commit messages for more details. Note: these changes are made in stable to avoid having to support multiple versions of the HOOT API. As such, these changes are intended to be strictly limited to unit tests as to not put the rest of the code base at risk. Enterprise: https://github.com/odoo/enterprise/pull/81834 --- I confirm I have s
Original PR description
## Pull Request HOOT (PRHOOT) 29 This pull requests brings various improvements and fixes to Hoot and the Odoo unit test ecosystem. See the different commit messages for more details. Note: these changes are made in stable to avoid having to support multiple versions of the HOOT API. As such, these changes are intended to be strictly limited to unit tests as to not put the rest of the code base at risk. Enterprise: https://github.com/odoo/enterprise/pull/81834 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#199461
Description of the issue/feature this PR addresses: Current behavior before PR:  Desired behavior after PR is merged:  --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202636
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR:  Desired behavior after PR is merged:  --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202636
- In POS, open a register and add Product A with a price of 100. Proceed with the payment using a card. - Close the register, increase the cash count by 20, and reduce the card count to 80. In the session report, the difference in the card payment is not displayed correctly. It shows the expected amount as 100 and the counted amount as 100, whereas it should be expected at 100 and counted at 80. Commit https://github.com/odoo/odoo/commit/01b87f1230beac0568f4e3b1b76e547909506892#diff-143
Original PR description
- In POS, open a register and add Product A with a price of 100. Proceed with the payment using a card. - Close the register, increase the cash count by 20, and reduce the card count to 80. In the…
- In POS, open a register and add Product A with a price of 100. Proceed with the payment using a card. - Close the register, increase the cash count by 20, and reduce the card count to 80. In the session report, the difference in the card payment is not displayed correctly. It shows the expected amount as 100 and the counted amount as 100, whereas it should be expected at 100 and counted at 80. Commit https://github.com/odoo/odoo/commit/01b87f1230beac0568f4e3b1b76e547909506892#diff-143d17de807d23650088a8c12f0a5b5cc2246b1b51e0bb7634e85247b6e535ea made journal entry optional for payments and removed the `synchronize_from_moves` method from `account_payment`. This mean that there is no longer a synchronization between account_payment and its potential journal entries. The source (here pos_session) is now responsible for creating and linking the moves to the payment. The amount field of account_payment, which is used to construct the session report and created in `_create_combine_account_payment` was not updated with the new balance created in `_apply_diff_on_account_payment_move`. opw-4494656 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#196253
The "Lot / SN" column is redundant with the "Pick From" column. When Pick From is displayed, we can hide the "Lot/SN". However, if the user does not have the lot/serial number in a quant, they still need a way to select it, so we allow for a quant creation. In order to not re-introduce the bug fixed by this commit: 60d95aa8304c11698e49336391d98926861e640d , we overwrite the name_create to return False, aka no action is done. --- ## BEFORE https://github.com/user-attachments/assets/7
Original PR description
The "Lot / SN" column is redundant with the "Pick From" column. When Pick From is displayed, we can hide the "Lot/SN". However, if the user does not have the lot/serial number in a quant, they still…
The "Lot / SN" column is redundant with the "Pick From" column. When Pick From is displayed, we can hide the "Lot/SN". However, if the user does not have the lot/serial number in a quant, they still need a way to select it, so we allow for a quant creation. In order to not re-introduce the bug fixed by this commit: 60d95aa8304c11698e49336391d98926861e640d , we overwrite the name_create to return False, aka no action is done. --- ## BEFORE https://github.com/user-attachments/assets/7e6c5a6a-ed86-4564-bcb5-51c94a5a4ae4 - Selecting a SN is very fast - We can easily use an unavailable SN - The unavailable SN is taken from a quant without lot - Lot is displayed twice (pick from & lot/sn) ## AFTER https://github.com/user-attachments/assets/f5bd7cc6-d77e-410c-a1aa-8ad6ba6d0020 - Selecting a SN is a bit harder - Selecting an unavailable SN is even more complicated - The unavailable SN is taken from a quant with its lot OPW-4485159 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202778 Forward-Port-Of: odoo/odoo#199630
When a user tries to access a vendor bill where the vendor is their own company, Odoo displays a warning indicating that the user is trying to invoice themselves. To determine whether to show this warning, we check if the partner has any related `employee_ids`. However, if the user does not have the `"Employees / Officer: Manage all employees"` access rights, they cannot check the `employee_ids`, leading to an access error when opening the vendor bill. Steps to Reproduce: 1. Create a vend
Original PR description
When a user tries to access a vendor bill where the vendor is their own company, Odoo displays a warning indicating that the user is trying to invoice themselves. To determine whether to show this…
When a user tries to access a vendor bill where the vendor is their own company, Odoo displays a warning indicating that the user is trying to invoice themselves. To determine whether to show this warning, we check if the partner has any related `employee_ids`. However, if the user does not have the `"Employees / Officer: Manage all employees"` access rights, they cannot check the `employee_ids`, leading to an access error when opening the vendor bill. Steps to Reproduce: 1. Create a vendor bill where the vendor is set to your own company. 2. Try to access the vendor bill with a user who does not have `"Employees / Officer: Manage all employees"` access rights. Issue: An error occurs because the user lacks permission to check the related `employee_ids` for the vendor. Refer to this [video](https://drive.google.com/file/d/1hIUTbNYhZxT4aOtNq8XE1z7uy7K_HJM1/view) for clearer steps. opw-4539017 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202033
Versions -------- - 18.0+ Steps ----- 1. Create a pricelist with any discount on all products with a minimum quantity of 5; 2. Create a new sale order in mobile view; 3. Create a new sale order line, select any product and set a quantity higher than 5. Issue ----- The price unit isn't discounted as expected. Cause ----- `_compute_price_unit` needs `technical_price_unit` which is missing from the mobile view. Solution -------- Add `technical_price_unit` to mobile sale orde
Original PR description
Versions -------- - 18.0+ Steps ----- 1. Create a pricelist with any discount on all products with a minimum quantity of 5; 2. Create a new sale order in mobile view; 3. Create a new sale order line, select any product and set a quantity higher than 5. Issue ----- The price unit isn't discounted as expected. Cause ----- `_compute_price_unit` needs `technical_price_unit` which is missing from the mobile view. Solution -------- Add `technical_price_unit` to mobile sale order views. opw-4569731 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202748
- Fix issue where canceled orderlines were not printed on the preparation ticket. task-id: 4663618 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202860
Original PR description
- Fix issue where canceled orderlines were not printed on the preparation ticket. task-id: 4663618 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202860
Increase image size from 128 to 256 for combo items in the configurator opw-4630831 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202740
Original PR description
Increase image size from 128 to 256 for combo items in the configurator opw-4630831 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202740
Steps to reproduce: - In any of the SOL Many2one field with create=True. - Create a SOL using create option in dropdown. Issue: - A SOL is created without product. Reason: - Incorrect SQL constraint passed . Fix: - Adding a validation error which is tapped in if Many2one quick create i.e., Create option fails and opens the Many2X form. - We cant change the SQL contraint because it is only applied when module is intalled/updated/reinstalled. --- Why the SQL contsrai
Original PR description
Steps to reproduce: - In any of the SOL Many2one field with create=True. - Create a SOL using create option in dropdown. Issue: - A SOL is created without product. Reason: - Incorrect SQL constraint…
Steps to reproduce: - In any of the SOL Many2one field with create=True. - Create a SOL using create option in dropdown. Issue: - A SOL is created without product. Reason: - Incorrect SQL constraint passed . Fix: - Adding a validation error which is tapped in if Many2one quick create i.e., Create option fails and opens the Many2X form. - We cant change the SQL contraint because it is only applied when module is intalled/updated/reinstalled. --- Why the SQL contsraint fails "CHECK(display_type IS NOT NULL OR is_downpayment OR (product_id IS NOT NULL AND product_uom IS NOT NULL))" Also is_downpayment doesnt have a default value. Here consider we dont event send a single value all as nulls then result would be CHECK(NULL IS NOT NULL OR NULL OR (NULL IS NOT NULL AND NULL IS NOT NULL)) CHECK(FALSE OR NULL OR (FALSE AND FALSE) CHECK(FALSE OR NULL OR FALSE) CHECK(NULL) SQL doesn't categorize NULL into truthy or falsy value. For example a SQL constraint as CHECK (row1 NOT NULL OR row2 ...(and N number of conditions)) -- will always pass the check (even if you pass all the rows as NULL) NULL OR NULL -- TRUE (passes the empty NULL column value as [null]) FALSE OR NULL -- TRUE (passes the empty NULL column value as [null]) TRUE OR NULL -- TRUE It there is another column which has value it glady create a row with values and [null]/empty value for others. task-4441043 Co-Authored By - @xavierbol Forward-Port-Of: odoo/odoo#202769 Forward-Port-Of: odoo/odoo#192464
- Implemented support for partial VAT deduction (e.g., 35% reclaimable VAT on EU acquisitions like fuel or electricity). task-4575302 Forward-Port-Of: odoo/odoo#197928
Original PR description
- Implemented support for partial VAT deduction (e.g., 35% reclaimable VAT on EU acquisitions like fuel or electricity). task-4575302 Forward-Port-Of: odoo/odoo#197928
#### This PR addresses 2 issues with the update of Manufacturing Order with kit products in the BoM (and subsequent bugs). Please see commits for details on the issues. Issue 1 ----- When using the "Update BOM" button for a confirmed manufacturing order, quantities for components derived from kit products are incorrectly updated to the kit product's bom instead of the new required quantity. Issue 2 ----- When using the "Update BOM" button for a confirmed manufacturing order, components
Original PR description
#### This PR addresses 2 issues with the update of Manufacturing Order with kit products in the BoM (and subsequent bugs). Please see commits for details on the issues. Issue 1 ----- When using the…
#### This PR addresses 2 issues with the update of Manufacturing Order with kit products in the BoM (and subsequent bugs). Please see commits for details on the issues. Issue 1 ----- When using the "Update BOM" button for a confirmed manufacturing order, quantities for components derived from kit products are incorrectly updated to the kit product's bom instead of the new required quantity. Issue 2 ----- When using the "Update BOM" button for a confirmed manufacturing order, components used to produce a specific variant of a kit product are not added to the MO consumables. Commit breakdown ----- - Commit 1 (handle component quantities - first ticket): - use the correct exploded value for the quantity (divided by the original quantity as the ratio isn't done for the top-level bom) - update test_update_mo_from_bom_with_kit with correct values - extend test_update_mo_from_bom_with_kit for when the kit components' quantities are updated - Commit 2 (handle components for specific variants - second ticket): - adapt the filtering of bom lines to keep them based on the kit's attribute instead of the end product one's - add a new test_update_mo_from_bom_with_kit_vraiants - Commit 3 (handle confusion of multi-variants/UoM kits - additional issues): - change bom_lines_by_id to a defaultdict to consolidate quantity of components - update test_update_mo_from_bom_with_kit to test for multiple UoMs - update test_update_mo_from_bom_with_kit_variants to test for multiple variants ----- Tickets: opw-4473337 opw-4480039 Forward-Port-Of: odoo/odoo#196227
Description of the issue/feature this PR addresses: Odoo Individual Contributor License Agreement Current behavior before PR: Odoo Individual Contributor License Agreement Desired behavior after PR is merged: Odoo Individual Contributor License Agreement --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202642
Original PR description
Description of the issue/feature this PR addresses: Odoo Individual Contributor License Agreement Current behavior before PR: Odoo Individual Contributor License Agreement Desired behavior after PR is merged: Odoo Individual Contributor License Agreement --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#202642
Steps to reproduce the bug: - Install accounting - Go to reporting, Invoice analysis - Select Product Quantity, Untaxed Total and Average Price in Measures Traceback is thrown that the field prive_subtotal is used twice for the combination Untaxed total and Average price. Another traceback is thrown that quantity field is used twice for the combination Product Quantity and Average price. This is because the override of the read_group in the account.account_invoice_report in case of ave
Original PR description
Steps to reproduce the bug: - Install accounting - Go to reporting, Invoice analysis - Select Product Quantity, Untaxed Total and Average Price in Measures Traceback is thrown that the field…
Steps to reproduce the bug: - Install accounting - Go to reporting, Invoice analysis - Select Product Quantity, Untaxed Total and Average Price in Measures Traceback is thrown that the field prive_subtotal is used twice for the combination Untaxed total and Average price. Another traceback is thrown that quantity field is used twice for the combination Product Quantity and Average price. This is because the override of the read_group in the account.account_invoice_report in case of average price in the fields it add fields of quantity and price_subtotal. By default the fields are added with the default agg, so they are as <field>:sum. And the Untaxed Total and Poruct Quantity by default add both quantity and prive_subtotal as well. So they are duplicate columns to show on pivot and view crashes. The override of the read_group was introduced in d741788306. opw-4638089 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#201155
Currently, a traceback is occurs when the user tries to remove the date value, while creating a Bill. To reproduce this issue: 1) Install account 2) Create a Bills record from vendors 3) Change the `Auto-Post` value to `at date` from `other info` 4) Now remove the `Accounting Date` Error:- ``` TypeError: '>' not supported between instances of 'bool' and 'datetime.date' ``` When the user removed the date value, a compute method will be triggered in which a comparison is done
Original PR description
Currently, a traceback is occurs when the user tries to remove the date value, while creating a Bill. To reproduce this issue: 1) Install account 2) Create a Bills record from vendors 3) Change the `Auto-Post` value to `at date` from `other info` 4) Now remove the `Accounting Date` Error:- ``` TypeError: '>' not supported between instances of 'bool' and 'datetime.date' ``` When the user removed the date value, a compute method will be triggered in which a comparison is done between the record date and the today value. However, the user removed the record's date value, which leads to the above traceback from the below line https://github.com/odoo/odoo/blob/2adabe7321f26e67eea9853460948cbd4ac10a4a/addons/account/models/account_move.py#L626-L627 sentry-6402545255 Forward-Port-Of: odoo/odoo#202057
Multiple problems can arise when a project has the documents feature enabled but no folder linked to it. This PR fixes two edge cases related to projects not having a folder. Task-4107728 Forward-Port-Of: odoo/enterprise#80248 Forward-Port-Of: odoo/enterprise#68688
Original PR description
Multiple problems can arise when a project has the documents feature enabled but no folder linked to it. This PR fixes two edge cases related to projects not having a folder. Task-4107728 Forward-Port-Of: odoo/enterprise#80248 Forward-Port-Of: odoo/enterprise#68688
Forward-Port-Of: odoo/enterprise#81564
Original PR description
Forward-Port-Of: odoo/enterprise#81564
Before this commit a translated mail layout's header would be (e.g. in Dutch) 'Je signature'. After this commit, the model's description is translated (e.g. in Dutch) to 'Je Handtekening'. This replicates the same behavior as the _send_signature_access_mail() method. Impacted versions: 16.0, 17.0 and 18.0 Forward-Port-Of: odoo/enterprise#79575 Forward-Port-Of: odoo/enterprise#77948
Original PR description
Before this commit a translated mail layout's header would be (e.g. in Dutch) 'Je signature'. After this commit, the model's description is translated (e.g. in Dutch) to 'Je Handtekening'. This replicates the same behavior as the _send_signature_access_mail() method. Impacted versions: 16.0, 17.0 and 18.0 Forward-Port-Of: odoo/enterprise#79575 Forward-Port-Of: odoo/enterprise#77948
If a list contains multi-line content, only the first line of the content is shown in the spreadsheet cells. This commit fixes this with an `AUTORESIZE_ROWS`, which now works for multi-line formulas. Task: [4609545](https://www.odoo.com/web#id=4609545&cids=1&menu_id=4720&action=333&active_id=2328&model=project.task&view_type=form) Forward-Port-Of: odoo/enterprise#81929 Forward-Port-Of: odoo/enterprise#81325
Original PR description
If a list contains multi-line content, only the first line of the content is shown in the spreadsheet cells. This commit fixes this with an `AUTORESIZE_ROWS`, which now works for multi-line formulas. Task: [4609545](https://www.odoo.com/web#id=4609545&cids=1&menu_id=4720&action=333&active_id=2328&model=project.task&view_type=form) Forward-Port-Of: odoo/enterprise#81929 Forward-Port-Of: odoo/enterprise#81325
Before this PR the function _compute_unpaid_invoices is using an antipattern of running a search in a for loop. This PR performs a single search and uses a python dictionary for faster lookup in the forloop and fewer queries. Benchmarks: |num res.partner | time before | no. queries| time after | no. queries after| |-----|-----|----|------|----| | 80 | ~18s | 80 | ~0.4s | 1| Forward-Port-Of: odoo/enterprise#81438
Original PR description
Before this PR the function _compute_unpaid_invoices is using an antipattern of running a search in a for loop. This PR performs a single search and uses a python dictionary for faster lookup in the forloop and fewer queries. Benchmarks: |num res.partner | time before | no. queries| time after | no. queries after| |-----|-----|----|------|----| | 80 | ~18s | 80 | ~0.4s | 1| Forward-Port-Of: odoo/enterprise#81438
## Pull Request HOOT (PRHOOT) 29 This pull requests brings various improvements and fixes to Hoot and the Odoo unit test ecosystem. See the different commit messages for more details. Note: these changes are made in stable to avoid having to support multiple versions of the HOOT API. As such, these changes are intended to be strictly limited to unit tests as to not put the rest of the code base at risk. Community: https://github.com/odoo/odoo/pull/199461 --- I confirm I have signed
Original PR description
## Pull Request HOOT (PRHOOT) 29 This pull requests brings various improvements and fixes to Hoot and the Odoo unit test ecosystem. See the different commit messages for more details. Note: these changes are made in stable to avoid having to support multiple versions of the HOOT API. As such, these changes are intended to be strictly limited to unit tests as to not put the rest of the code base at risk. Community: https://github.com/odoo/odoo/pull/199461 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/enterprise#81834
Versions -------- - 18.0+ Steps ----- 1. Have a second company & select it; 2. create a project w/out `company_id`; 3. set its documents folder to "Projects"; 4. create a service product that creates a project on confirm; 5. set created project as its project template; 6. add service product to a quotation; 7. confirm quotation. Issue ----- Access Error. Cause ----- Commit ac051d00e96c added a constraint on the `website_id` of documents: - OR the document's `company_id` h
Original PR description
Versions -------- - 18.0+ Steps ----- 1. Have a second company & select it; 2. create a project w/out `company_id`; 3. set its documents folder to "Projects"; 4. create a service product that creates…
Versions -------- - 18.0+ Steps ----- 1. Have a second company & select it; 2. create a project w/out `company_id`; 3. set its documents folder to "Projects"; 4. create a service product that creates a project on confirm; 5. set created project as its project template; 6. add service product to a quotation; 7. confirm quotation. Issue ----- Access Error. Cause ----- Commit ac051d00e96c added a constraint on the `website_id` of documents: - OR the document's `company_id` has to match the website's `company_id`; - OR the website's `company_id` has to be in `self.env.companies`. The Projects folder was created without `website_id`, but was assigned company 1's website by the `_compute_website_id` method. When a document gets created by the sale order, it inherits the `website_id` of the Projects folder. Hence having a shared folder between companies can lead to access errors if the website's `company_id` isn't selected in the company selector. Solution -------- Bypass the constraint when in sudo mode, so you don't have to enable the website's company in the company selector when setting up a sale order. opw-4548619 Forward-Port-Of: odoo/enterprise#80966
Before this commit: The "I Take It" button visibility was inconsistent across different view because different conditions were used to determine its visibility in each view. After this commit: This commit enhance the visibility of the "I Take It" button now it has consistent visibility across the views by follow same condition for every view. task-4455488 Forward-Port-Of: odoo/enterprise#81854 Forward-Port-Of: odoo/enterprise#79319
Original PR description
Before this commit: The "I Take It" button visibility was inconsistent across different view because different conditions were used to determine its visibility in each view. After this commit: This commit enhance the visibility of the "I Take It" button now it has consistent visibility across the views by follow same condition for every view. task-4455488 Forward-Port-Of: odoo/enterprise#81854 Forward-Port-Of: odoo/enterprise#79319
Currently on the Frontdesk welcome screen the words "Welcome" and "to" (welcoming visitors to your company) were exported separately, because they weren't in the same parent node. This caused translation issues, since the word "to" is translated differently depending on the context and was not scoped to the module (Javascript translation). This commit puts "Welcome to" together in the same parent node, so the phrase is exported as a whole. [task-4421055](https://www.odoo.com/odoo/project.t
Original PR description
Currently on the Frontdesk welcome screen the words "Welcome" and "to" (welcoming visitors to your company) were exported separately, because they weren't in the same parent node. This caused translation issues, since the word "to" is translated differently depending on the context and was not scoped to the module (Javascript translation). This commit puts "Welcome to" together in the same parent node, so the phrase is exported as a whole. [task-4421055](https://www.odoo.com/odoo/project.task/4421055) Forward-Port-Of: odoo/enterprise#80851 Forward-Port-Of: odoo/enterprise#78781
Use case: -Create a parent company and a child company. -Create two journals, assigning one to each company. -Connect with a normal user (not an admin, I connected with marc demo) after adding both companies to their allowed companies list. -activate the child company, and attempt to access the General Ledger. --> there is an access right error raised because the user doesn't have access to the parent company. ticket - 4577222 Forward-Port-Of: odoo/enterprise#81452
Original PR description
Use case: -Create a parent company and a child company. -Create two journals, assigning one to each company. -Connect with a normal user (not an admin, I connected with marc demo) after adding both companies to their allowed companies list. -activate the child company, and attempt to access the General Ledger. --> there is an access right error raised because the user doesn't have access to the parent company. ticket - 4577222 Forward-Port-Of: odoo/enterprise#81452
- Removed VAT report banners for warnings but kept rejection banners. task-4575302 Forward-Port-Of: odoo/enterprise#79469
Original PR description
- Removed VAT report banners for warnings but kept rejection banners. task-4575302 Forward-Port-Of: odoo/enterprise#79469
[[FIX] account_batch_payment: show correct amount in reconciled batch payments](https://github.com/odoo/enterprise/pull/80862/commits/d9f837d4bb459a10e74b65c10204e2c31573e7a5) **Issue:** When reconciling a batch payment, its amount is incorrectly displayed as zero in the list view. **Steps to Reproduce:** 1. Install the Accounting app. 2. Navigate to Accounting > Customers > Payments. 3. Create or select two payments, then click Create Batch. 4. Validate the batch payment. 5. Go to Das
Original PR description
[[FIX] account_batch_payment: show correct amount in reconciled batch payments](https://github.com/odoo/enterprise/pull/80862/commits/d9f837d4bb459a10e74b65c10204e2c31573e7a5) **Issue:** When…
[[FIX] account_batch_payment: show correct amount in reconciled batch payments](https://github.com/odoo/enterprise/pull/80862/commits/d9f837d4bb459a10e74b65c10204e2c31573e7a5) **Issue:** When reconciling a batch payment, its amount is incorrectly displayed as zero in the list view. **Steps to Reproduce:** 1. Install the Accounting app. 2. Navigate to Accounting > Customers > Payments. 3. Create or select two payments, then click Create Batch. 4. Validate the batch payment. 5. Go to Dashboard > Transactions. 6. Create a new transaction with the same value as the batch payment. 7. Click on the transaction, select the batch payment, and click Validate to reconcile them. 8. Navigate to Customers > Batch Payments. 9. Observe that the batch payment in the list view shows an amount of zero. Expected Behavior: The list view should display the sum of the payments included in the batch. Actual Behavior: The amount displayed in the list view is always zero after reconciliation. **Root Cause** During reconciliation, when execution reaches line 138 in account_batch_payment.py https://github.com/odoo/enterprise/blob/08084d8423a7d75c1ee2647256e01a464eec0b14/account_batch_payment/models/account_batch_payment.py#L137 , the batch payments are already in the paid state. However, _valid_payment_states() https://github.com/odoo/enterprise/blob/08084d8423a7d75c1ee2647256e01a464eec0b14/account_batch_payment/models/account_batch_payment.py#L69-L70 calls _get_invoice_in_payment_state(), which returns "in_payment". As a result, _valid_payment_states() only returns "in_process", excluding payments in the "paid" state from the computation. Consequently, in _compute_from_payment_ids(), the loop over valid payments is skipped, leaving the amount variable at its initial value of zero. https://github.com/odoo/enterprise/blob/08084d8423a7d75c1ee2647256e01a464eec0b14/account_batch_payment/models/account_batch_payment.py#L132-L162 **Fix** Always compute `amount`. Skip `amount_residual` and `amount_residual_currency` for valid payment states. Opw-4585624 Forward-Port-Of: odoo/enterprise#80862
Before this PR: - The computation used `start_yearly_period` as the start date. - This caused incorrect depreciation calculations when an asset was disposed of early. - Example: - Prorata Date: 01/01/2025 - Disposal Date: 20/02/2025 - Computed Days: 326 (incorrect, should be 20) After this PR: - `period_start_date` is now set as `max(start_yearly_period, self.paused_prorata_date)`. - Ensures depreciation is calculated only for the valid period before disposal. - Example: - P
Original PR description
Before this PR: - The computation used `start_yearly_period` as the start date. - This caused incorrect depreciation calculations when an asset was disposed of early. - Example: - Prorata Date: 01/01/2025 - Disposal Date: 20/02/2025 - Computed Days: 326 (incorrect, should be 20) After this PR: - `period_start_date` is now set as `max(start_yearly_period, self.paused_prorata_date)`. - Ensures depreciation is calculated only for the valid period before disposal. - Example: - Prorata Date: 01/01/2025 - Disposal Date: 20/02/2025 - Computed Days: 20 (correct). OPW: 4599614 Forward-Port-Of: odoo/enterprise#81888 Forward-Port-Of: odoo/enterprise#80214
Currently an error occurs when the user tries to uninstall `Sales` or `helpdesk_sale_timesheet` after creating a helpdesk ticket. Steps to generate an error: - Create a database without a demo and install helpdesk_sale_timesheet. - Create a helpdesk ticket. - Now try to uninstall sale_management (Sales). Error `KeyError: 'helpdesk.ticket.sale_line_id'` This issue was generated because in the helpdesk ticket we have the `use_helpdesk_sale_timesheet` field (see [1]), which is a depen
Original PR description
Currently an error occurs when the user tries to uninstall `Sales` or `helpdesk_sale_timesheet` after creating a helpdesk ticket. Steps to generate an error: - Create a database without a demo and…
Currently an error occurs when the user tries to uninstall `Sales` or `helpdesk_sale_timesheet` after creating a helpdesk ticket. Steps to generate an error: - Create a database without a demo and install helpdesk_sale_timesheet. - Create a helpdesk ticket. - Now try to uninstall sale_management (Sales). Error `KeyError: 'helpdesk.ticket.sale_line_id'` This issue was generated because in the helpdesk ticket we have the `use_helpdesk_sale_timesheet` field (see [1]), which is a depends field of the `compute_sale_line_id` method, which is the compute method of the field sale_line_id (see [2] and [3]) in the helpdesk ticket. In helpdesk code line [4] tries to update the value of the field `use_helpdesk_sale_timesheet` since this field is related to the helpdesk ticket (see [1]) value of this field also changed in the helpdesk ticket, and the value was changed the compute method trigger because this field depends on the compute method. This commit will solve the above issue by executing an SQL query instead of writing the team field so it doesn't trigger depending on that field. [1]- https://github.com/odoo/enterprise/blob/1619b74b7895108a80d466c57972fc97923c860c/helpdesk_sale_timesheet/models/helpdesk_ticket.py#L27 [2]- https://github.com/odoo/enterprise/blob/1619b74b7895108a80d466c57972fc97923c860c/helpdesk_sale_timesheet/models/helpdesk_ticket.py#L31-L38 [3]- https://github.com/odoo/enterprise/blob/1619b74b7895108a80d466c57972fc97923c860c/helpdesk_sale_timesheet/models/helpdesk_ticket.py#L77-L78 [4]- https://github.com/odoo/enterprise/blob/1619b74b7895108a80d466c57972fc97923c860c/helpdesk/models/ir_module.py#L15 sentry-6308112739 Forward-Port-Of: odoo/enterprise#81008