Friday, March 7, 2025
19 changes · saas-17.4
Resolved issues and error corrections
This fixes a display issue where products without a ribbon could still show a small white triangle on their image. The shop page now properly hides the ribbon area when no ribbon is configured, improving product image presentation.
Original PR description
Versions -------- - saas-17.4+ Steps ----- Unsure. Issue ----- The ribbon element is technically always visible, even if the product has no ribbon. This can lead to CSS shadow being applied to it, resulting in a white triangle in the top right corner of images:  Cause ----- The `_get_position_class` method returns a position, even for empty recordsets, in which case it will return `o_ribbon_right`. Solution -------- If there is no record, return the `d-none` class to properly hide the element. opw-4151902
Miscellaneous changes
This commit fixed the access error issue that non-admin users would encounter when submitting a Jordanian e-invoice. It adds sudo access rights to the fields l10n_jo_edi_client_identifier and l10n_jo_edi_secret_key while reading them for e-invoice submission. task-4577597 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#200015
Original PR description
This commit fixed the access error issue that non-admin users would encounter when submitting a Jordanian e-invoice. It adds sudo access rights to the fields l10n_jo_edi_client_identifier and l10n_jo_edi_secret_key while reading them for e-invoice submission. task-4577597 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#200015
### Steps to reproduce: - Create a new invoice - Attach a ZIP file then a PDF file - The file viewer shows but tries to preview the ZIP file - Happens with all non-viewable files ### Cause: The ZIP file is put as main attachment and the method `register_as_main_attachment` only change the main attachment (with `force=False`) when there is no main attachment. The behavior of the file viewer is problematic because we cannot switch between the attachments in the preview, so we cannot see
Original PR description
### Steps to reproduce: - Create a new invoice - Attach a ZIP file then a PDF file - The file viewer shows but tries to preview the ZIP file - Happens with all non-viewable files ### Cause: The ZIP…
### Steps to reproduce: - Create a new invoice - Attach a ZIP file then a PDF file - The file viewer shows but tries to preview the ZIP file - Happens with all non-viewable files ### Cause: The ZIP file is put as main attachment and the method `register_as_main_attachment` only change the main attachment (with `force=False`) when there is no main attachment. The behavior of the file viewer is problematic because we cannot switch between the attachments in the preview, so we cannot see the PDF. But if we add another PDF file (so one ZIP and 2 PDFs), we can switch but it will never show the ZIP again, only the two PDFs. This behavior is due to the [next/previous arrows](https://github.com/odoo/odoo/blob/e4da068d6c9c8885dd4663d50dee11c9ea1516a3/addons/mail/static/src/components/web_client_view_attachment_view/web_client_view_attachment_view.xml#L13) being displayed only if [`attachmentsInWebClientView`](https://github.com/odoo/odoo/blob/e4da068d6c9c8885dd4663d50dee11c9ea1516a3/addons/mail/static/src/models/attachment.js#L323-L328) contains more than one item. But this list only contains viewable attachments (PDF or Images), and the next/previous arrows only take attachments from this list. As the arrows are [changing the main attachment](https://github.com/odoo/odoo/blob/e4da068d6c9c8885dd4663d50dee11c9ea1516a3/addons/mail/static/src/models/web_client_view_attachment_view.js#L17) to change the displayed preview, it never comes back to the problematic ZIP file. ### Solution: Also display the arrows if the main attachment is not viewable and there is more than one attachment. This way the user can return in the list of viewable attachments. This is not an optimal because Odoo will still try to display the ZIP file, but it is a simple fix that works. I tried restraining the main attachment field only to viewable files in this [PR](https://github.com/odoo/odoo/pull/196390), but it seems to break things specially with OCR extraction and apparently it is sometimes wanted to have an XML as main attachment. opw-4486363 Forward-Port-Of: odoo/odoo#200243 Forward-Port-Of: odoo/odoo#196446
Since the upgrade of Chartjs to v4.3 in [commit 1], stacked charts in website were wrongly computed. This commit fixes it. [commit 1]: https://github.com/odoo/odoo/commit/7e3c1ecdb86110912b15722e600f9571692807ed task-4603349 Forward-Port-Of: odoo/odoo#199186
Original PR description
Since the upgrade of Chartjs to v4.3 in [commit 1], stacked charts in website were wrongly computed. This commit fixes it. [commit 1]: https://github.com/odoo/odoo/commit/7e3c1ecdb86110912b15722e600f9571692807ed task-4603349 Forward-Port-Of: odoo/odoo#199186
Repro steps: 1. Create a new company. 2. Attempt to delete the newly created company. 3. The deletion is successful, but if the user tries to login again, they will keep getting this error `Record does not exist or has been deleted.` Cause: The cause was that the cache would have the id of the deleted company, and attempting to access this company was the bug cause. Solution: This commit solves this bug by clearing the cache on company deletion. task-4438207 --- I confirm I
Original PR description
Repro steps: 1. Create a new company. 2. Attempt to delete the newly created company. 3. The deletion is successful, but if the user tries to login again, they will keep getting this error `Record does not exist or has been deleted.` Cause: The cause was that the cache would have the id of the deleted company, and attempting to access this company was the bug cause. Solution: This commit solves this bug by clearing the cache on company deletion. task-4438207 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#200164
This https://github.com/odoo/enterprise/commit/68f6c1f9fd3ff6762c98e1a405ade035129efce0 caused the `test_create_res_partner` test to fail. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#200527
Original PR description
This https://github.com/odoo/enterprise/commit/68f6c1f9fd3ff6762c98e1a405ade035129efce0 caused the `test_create_res_partner` test to fail. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#200527
**Current behavior:** Adding a product which is invoiced based on delivered quantities to the delivery of a sale which has already been confirmed, then validating the delivery, does not reflect the change in price (which will be invoiced) on the sale order. **Expected behavior:** The sale order should show the actual amount of money to be charged to the orderer. **Steps to reproduce:** 1. Create a stored product with some price and change its invoicing policy to 'delivery' 2. Cr
Original PR description
**Current behavior:** Adding a product which is invoiced based on delivered quantities to the delivery of a sale which has already been confirmed, then validating the delivery, does not reflect the…
**Current behavior:** Adding a product which is invoiced based on delivered quantities to the delivery of a sale which has already been confirmed, then validating the delivery, does not reflect the change in price (which will be invoiced) on the sale order. **Expected behavior:** The sale order should show the actual amount of money to be charged to the orderer. **Steps to reproduce:** 1. Create a stored product with some price and change its invoicing policy to 'delivery' 2. Create a new sale order, add 1 of the created product, then confirm it 3. Open the delivery, add another line to it for the same created product, fill in the quantities for each move, then validate the picking 4. Check the sale order line to see that, while the price unit is populated with the product's price, the subtotal/total fields are not **Cause of the issue:** Order lines added in this manner have `product_uom_qty == 0` which will zero-out the price computation. **Fix:** First, `_compute_purchase_price` is modified such that lines for standard cost product will have a value computed (where previously they were skipped). Then for `_compute_margin`: use `qty_delivered` and an on-the-fly calculated `price_subtotal` to find a margin value for a SOL added from a delivery (which is determined when `product_uom_qty == 0` and `qty_delivered != 0` opw-4210056 Forward-Port-Of: odoo/odoo#186236
When a quotation has been confirmed, the invoice generated and confirmed by an accountant, the salesman of that first quotation has access to the invoice and its button "Send & Print". However, when trying to generate the document and send it, he receives an access right error. The salesman should be able to Send & Print when the invoice has been confirmed by an accountant. task-4378899 Forward-Port-Of: odoo/odoo#191823
Original PR description
When a quotation has been confirmed, the invoice generated and confirmed by an accountant, the salesman of that first quotation has access to the invoice and its button "Send & Print". However, when trying to generate the document and send it, he receives an access right error. The salesman should be able to Send & Print when the invoice has been confirmed by an accountant. task-4378899 Forward-Port-Of: odoo/odoo#191823
**Problem**: When rendering editor content that includes self-closing tags, it will not be rendered properly because self-closing tags are not valid HTML in this context. **Solution**: Convert self-closing tags to explicitly opened and closed tags before rendering. **Steps to Reproduce**: 1. Open an email template. 2. Edit content by adding a self-closing tag. 3. Save. 4. The content is not rendered properly. opw-4555555 --- I confirm I have signed the CLA and read the PR guid
Original PR description
**Problem**: When rendering editor content that includes self-closing tags, it will not be rendered properly because self-closing tags are not valid HTML in this context. **Solution**: Convert self-closing tags to explicitly opened and closed tags before rendering. **Steps to Reproduce**: 1. Open an email template. 2. Edit content by adding a self-closing tag. 3. Save. 4. The content is not rendered properly. opw-4555555 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#198076
Currently, the date filters do not have their title displayed in the `FilteValue` component which is an issue in dashboards where one could have multiple date filters defined and could not differentiate them. This revision adds the fiter label as a title such that users can identify the right filter given that they gave it an appropriate label. task-4606670 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged:
Original PR description
Currently, the date filters do not have their title displayed in the `FilteValue` component which is an issue in dashboards where one could have multiple date filters defined and could not differentiate them. This revision adds the fiter label as a title such that users can identify the right filter given that they gave it an appropriate label. task-4606670 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#200528 Forward-Port-Of: odoo/odoo#200502
Versions -------- - 16.0+ Steps ----- 1. Have a cart ready to be paid; 2. open `/shop/payment` in two windows; 3. click "Pay now" in one window; 4. click "Pay now" in the next window. Issue ----- Depending on version, installed modules & click speed, one of the following happens: - Error: "The operation cannot be completed: Reference must be unique!" - 500: Internal Server Error. - Both payments get confirmed. Cause ----- There's no check on whether a payment is already b
Original PR description
Versions -------- - 16.0+ Steps ----- 1. Have a cart ready to be paid; 2. open `/shop/payment` in two windows; 3. click "Pay now" in one window; 4. click "Pay now" in the next window. Issue -----…
Versions -------- - 16.0+ Steps ----- 1. Have a cart ready to be paid; 2. open `/shop/payment` in two windows; 3. click "Pay now" in one window; 4. click "Pay now" in the next window. Issue ----- Depending on version, installed modules & click speed, one of the following happens: - Error: "The operation cannot be completed: Reference must be unique!" - 500: Internal Server Error. - Both payments get confirmed. Cause ----- There's no check on whether a payment is already being processed for a particular order. This can happen in two manners: 1. The 1st one has finished, but the 2nd one is still allowed to start. 2. Clicking fast enough, both will try to transaction concurrently. Solution -------- 1. If the `amount_total` is equal to `amount_paid`, raise an error. 2. Put a database-level lock on the Sale Order using `FOR NO KEY UPDATE` which will get released as soon as the payment transaction is committed to the database, or is rolled back due to failure. Also modify the `_has_deliverable_products` method to return `False` if there are no products in the cart (e.g. due to the cart not existing), to prevent a server error after returning from a failed concurrent payment. opw-4555664 Forward-Port-Of: odoo/odoo#200191 Forward-Port-Of: odoo/odoo#198873
The Sales Details report in POS sometimes displays incorrect quantities due to floating point precision errors. This happens when summing product quantities that have decimal values, leading to unintended rounding inaccuracies in the report output. Steps to Reproduce: 1. Create a sample product to be sold in POS. 2. Check the rounding precision set for the unit of measure for this product. 3. Open a new POS session and confirm an order with `14.9` quantities of the product. 4. Create anot
Original PR description
The Sales Details report in POS sometimes displays incorrect quantities due to floating point precision errors. This happens when summing product quantities that have decimal values, leading to…
The Sales Details report in POS sometimes displays incorrect quantities due to floating point precision errors. This happens when summing product quantities that have decimal values, leading to unintended rounding inaccuracies in the report output. Steps to Reproduce: 1. Create a sample product to be sold in POS. 2. Check the rounding precision set for the unit of measure for this product. 3. Open a new POS session and confirm an order with `14.9` quantities of the product. 4. Create another order for the same product, this time with `59.7` as the quantity. 5. Go to POS → Reporting → Sales Details, select the relevant POS, and print the report. 6. Issue: The generated PDF report incorrectly shows `74.60000000000001` instead of `74.6`. The sum of product quantities was not respecting the unit of measure's decimal precision, leading to floating point inaccuracies in the report. I Applied rounding to the quantity aggregation using the decimal precision of Product Unit of Measure, ensuring consistent and correctly formatted values in the report. opw-4430513 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#197755
**Steps to reproduce:** 1. Log in with a non-admin users 2. Open any Partner from 3. Click on Actions > Privacy Lookup **Bug:** ``` You are not allowed to access 'Privacy Lookup Wizard' (privacy.lookup.wizard) records. This operation is allowed for the following groups: - Administration/Settings Contact your administrator to request access if necessary. ``` **Expected behavior:** The error message is correct. This feature should only be available to Administrator user
Original PR description
**Steps to reproduce:** 1. Log in with a non-admin users 2. Open any Partner from 3. Click on Actions > Privacy Lookup **Bug:** ``` You are not allowed to access 'Privacy Lookup Wizard' (privacy.lookup.wizard) records. This operation is allowed for the following groups: - Administration/Settings Contact your administrator to request access if necessary. ``` **Expected behavior:** The error message is correct. This feature should only be available to Administrator users. Therefore, the action should be hidden accordingly. See: - https://github.com/odoo/odoo/blob/16.0/addons/privacy_lookup/security/ir.model.access.csv#L2 --- ping @tivisse --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#150748
…rate The current implementation to handle the rate for multi-currency entries in CAMT creates problems when fetching the source rate from the file: the source rate can be taken from the SrcCcy or the TrgtCcy node, which should be compared with the source currency and target currency respectively. It is not done that way and is too restrictive (when the SrcCcy is found, it is always compared to the target currency, which leads to an incorrect transaction amount). Moreover, when the currenc
Original PR description
…rate The current implementation to handle the rate for multi-currency entries in CAMT creates problems when fetching the source rate from the file: the source rate can be taken from the SrcCcy or the TrgtCcy node, which should be compared with the source currency and target currency respectively. It is not done that way and is too restrictive (when the SrcCcy is found, it is always compared to the target currency, which leads to an incorrect transaction amount). Moreover, when the currency conversion introduces a exchange loss/gain, it is put back on the largest transaction of the entry. opw-4393164 Forward-Port-Of: odoo/enterprise#76828
As a user I want to be able to choose if I want the frame or not, and as it's saved in a preference like way, I want to be able to disable the default frame if I enable it previously Steps: - Setup a signature image for your user - Open Sign - Upload a document and add Signature field - Sign the document - Open the Sign dialog - Check the "frame" option - Sign - Repeat the steps BUT uncheck frame option Actual result: - Signature frame is still there for the user - All signature
Original PR description
As a user I want to be able to choose if I want the frame or not, and as it's saved in a preference like way, I want to be able to disable the default frame if I enable it previously Steps: - Setup a signature image for your user - Open Sign - Upload a document and add Signature field - Sign the document - Open the Sign dialog - Check the "frame" option - Sign - Repeat the steps BUT uncheck frame option Actual result: - Signature frame is still there for the user - All signature have the frame by default Expected result: - If user sign without frame, this preferences is apply for next signature opw-4610410 Forward-Port-Of: odoo/enterprise#80848
Forward-Port-Of: odoo/enterprise#80405
Original PR description
Forward-Port-Of: odoo/enterprise#80405
Steps to reproduce: - create two companies - create two analytic account (no company defined) - create for company B an analytic distribution model with one of the analytic account and define company A as parter - With Company A, create an invoice and on the line use the other analytic account and confirm Issue: The distribution model for Company B will not be used and only the account distribution from the original invoice will be defined on the line Cause: In the _get_distribution
Original PR description
Steps to reproduce: - create two companies - create two analytic account (no company defined) - create for company B an analytic distribution model with one of the analytic account and define company A as parter - With Company A, create an invoice and on the line use the other analytic account and confirm Issue: The distribution model for Company B will not be used and only the account distribution from the original invoice will be defined on the line Cause: In the _get_distribution method, the partner is incorrectly set to Company B, leading to this issue. opw-4414850 Forward-Port-Of: odoo/enterprise#78754 Forward-Port-Of: odoo/enterprise#76395
Add a step that ensures a name_search has been fired. The hypothesis is that the dropdown item is already present before editing the m2o's value (that triggers a name_search) The tour advances, captures a trigger but right there the rpc returns, modifies the DOM and the captured element is not there anymore, crashing as a consequence. runbot-error-67580 Forward-Port-Of: odoo/enterprise#80598
Original PR description
Add a step that ensures a name_search has been fired. The hypothesis is that the dropdown item is already present before editing the m2o's value (that triggers a name_search) The tour advances, captures a trigger but right there the rpc returns, modifies the DOM and the captured element is not there anymore, crashing as a consequence. runbot-error-67580 Forward-Port-Of: odoo/enterprise#80598
Overrides xml and xlsx export for Estonia intrastat because the current columns of the default intrastat report don't match with estonian government requirements. More information can be found at those addresses: - Arrivals: https://www.stat.ee/en/questionnaires/intrastat-arrivals-2024-month - Dispatches: https://www.stat.ee/en/questionnaires/intrastat-dispatches-2024-month task-3989930 Forward-Port-Of: odoo/enterprise#71114
Original PR description
Overrides xml and xlsx export for Estonia intrastat because the current columns of the default intrastat report don't match with estonian government requirements. More information can be found at those addresses: - Arrivals: https://www.stat.ee/en/questionnaires/intrastat-arrivals-2024-month - Dispatches: https://www.stat.ee/en/questionnaires/intrastat-dispatches-2024-month task-3989930 Forward-Port-Of: odoo/enterprise#71114