Friday, April 25, 2025
30 changes · saas-17.4
Resolved issues and error corrections
This fixes an automated test that could fail randomly when restaurant orders were sent for preparation and then validated immediately. The customer-facing behavior remains unchanged, while test results should be more stable and reduce false failures in quality checks.
Original PR description
`sync_from_ui` server method is called when sending items for preparation and when validating an order. We call the method asynchronously when sending items for preparation, so when running the test automatically, there is a risk of concurrent calls of `sync_from_ui` if preparation order action is immediately followed by validating the order. Runbot observes the issue randomly. It's a functional requirement that we don't wait for the preparation order request so in this PR, we fix the test by waiting for the preparation order request to finish before proceeding to the succeeding steps.
Miscellaneous changes
In https://github.com/odoo/odoo/pull/205403 I did some wrong changes to the totals of Modelo 390 section 1. This PR reverts these changes and fixes the section 2, which was the initial plan. Details: l10n_es tax has two main tax reports, modelo 303 (quarterly taxes) and modelo 390 (annual taxes). For both of these reports, for invoices, the taxes use positive tax tags corresponding the to tax line in the tax report. For refunds, the two reports work differently. Modelo 303 links all the
Original PR description
In https://github.com/odoo/odoo/pull/205403 I did some wrong changes to the totals of Modelo 390 section 1. This PR reverts these changes and fixes the section 2, which was the initial plan. Details:…
In https://github.com/odoo/odoo/pull/205403 I did some wrong changes to the totals of Modelo 390 section 1. This PR reverts these changes and fixes the section 2, which was the initial plan. Details: l10n_es tax has two main tax reports, modelo 303 (quarterly taxes) and modelo 390 (annual taxes). For both of these reports, for invoices, the taxes use positive tax tags corresponding the to tax line in the tax report. For refunds, the two reports work differently. Modelo 303 links all the refund amounts to some special report line (modification/correction of base/taxes), whereas the modelo 390 uses the negative tax tags corresponding to the tax line in the report. The issue lies in the multiple cross report references from modelo 303 to modelo 390. In section 1, some base and tax amounts are referrenced from modelo 303, as well as the modification amounts (the total of refunds mentionned above). When we compute the totals for that section, some refunds can be counted twice (once from the report using the negative tax tags, and a second time if we count the modification cross referenced from modelo 303). Since we have more taxes using the negative tags than cross-referenced in that section, it is better to omit the modification from the totals (i.e. we do not subtract [30] for the totals, as the negative amounts are already accounted for for the majority of the taxes). The totals will still be incorrect for that section, but less wrong. A future PR for master will fix the report by splitting all the tags used for the two reports. In section 2, we are in a similar case, so we remove the subtraction of [62] from the totals. In this case, the totals are correct after this modification. Forward-Port-Of: odoo/odoo#205860
Two lines in the French Chart of Accounts were inverted. 467 and 468 Steps to reproduce: ------------------- * French Fiscal Localization * Open the Chart of Accounts * Line 467 and 468 > Observation: Why the fix: ------------ Based on french gouvernement documentation https://www.anc.gouv.fr/files/anc/files/1_Normes_fran%C3%A7aises/Plans%20comptables/Plan-de-comptes-PCG-2025.pdf opw-4680252 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submi
Original PR description
Two lines in the French Chart of Accounts were inverted. 467 and 468 Steps to reproduce: ------------------- * French Fiscal Localization * Open the Chart of Accounts * Line 467 and 468 > Observation: Why the fix: ------------ Based on french gouvernement documentation https://www.anc.gouv.fr/files/anc/files/1_Normes_fran%C3%A7aises/Plans%20comptables/Plan-de-comptes-PCG-2025.pdf opw-4680252 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#207216 Forward-Port-Of: odoo/odoo#205323
This commit disable both protection upon neutralizing a db by removing the tokens. Version 16.0 : only reCaptcha Version 17.0+: both opw-4734555 upg-2759374 Forward-Port-Of: odoo/odoo#207020
Original PR description
This commit disable both protection upon neutralizing a db by removing the tokens. Version 16.0 : only reCaptcha Version 17.0+: both opw-4734555 upg-2759374 Forward-Port-Of: odoo/odoo#207020
Steps to reproduce the issue: - Create a new website using the configurator. - At the step where the color palette is defined, upload a large logo (e.g., 6 MB). - A traceback occurs. The issue comes from the fact that the logo is added to the browser's session storage, which has a 10 MB limit in most modern browsers. Before the logo upload, the session storage already contains some data, and adding a large file goes over the 10 MB limit, which causes the traceback. This commit prevent
Original PR description
Steps to reproduce the issue: - Create a new website using the configurator. - At the step where the color palette is defined, upload a large logo (e.g., 6 MB). - A traceback occurs. The issue comes from the fact that the logo is added to the browser's session storage, which has a 10 MB limit in most modern browsers. Before the logo upload, the session storage already contains some data, and adding a large file goes over the 10 MB limit, which causes the traceback. This commit prevents users from uploading a logo larger than 2.5 MB, which is already a lot for a logo shown in a website header. task-4742810 Forward-Port-Of: odoo/odoo#207071
During this commit: https://github.com/odoo/odoo/commit/2f86fb973a426a4d6c10d41d61dc524955aebb6b we checked the tin1 twice instead of checking the second one task: 4743115 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#207181
Original PR description
During this commit: https://github.com/odoo/odoo/commit/2f86fb973a426a4d6c10d41d61dc524955aebb6b we checked the tin1 twice instead of checking the second one task: 4743115 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#207181
## Description I am experiencing slow processing times for incoming stock from vendors when the historical data contains a large number of records. Currently, my company has around 20 million `stock.valuation.layer` records. As a result, any transaction involving incoming stock takes approximately 5–21 seconds to complete, even for a small number of products (around 1–5 products). Through profiling, I have identified that the root cause is the compute function `_compute_value_svl`. This c
Original PR description
## Description I am experiencing slow processing times for incoming stock from vendors when the historical data contains a large number of records. Currently, my company has around 20 million…
## Description
I am experiencing slow processing times for incoming stock from vendors when the historical data contains a large number of records.
Currently, my company has around 20 million `stock.valuation.layer` records. As a result, any transaction involving incoming stock takes approximately 5–21 seconds to complete, even for a small number of products (around 1–5 products).
Through profiling, I have identified that the root cause is the compute function `_compute_value_svl`. This computed field is always triggered during incoming stock transactions when calculating the average cost or fixing rounding errors.
## Proposal
To improve performance, I propose implementing a Parallel Index-Only Scan. This method is effective for grouping large datasets while retrieving only fixed columns, optimizing query execution.
## Benchmark
| Before | After | Speedup |
|--------|--------|--------|
| 1.1 s| 97.8 ms | 11x|
### Before
```
Finalize GroupAggregate (cost=1000.56..397852.39 rows=538 width=80) (actual time=1040.355..1114.694 rows=1 loops=1)
Group Key: product_id
Buffers: shared hit=227534 read=330906 dirtied=83 written=683
-> Gather (cost=1000.56..397825.49 rows=1076 width=80) (actual time=1039.900..1114.679 rows=3 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=227534 read=330906 dirtied=83 written=683
-> Partial GroupAggregate (cost=0.56..396717.89 rows=538 width=80) (actual time=1036.758..1036.759 rows=1 loops=3)
Group Key: product_id
Buffers: shared hit=227534 read=330906 dirtied=83 written=683
-> Parallel Index Scan using stock_valuation_layer_index on stock_valuation_layer
(cost=0.56..392927.16 rows=302613 width=20) (actual time=0.608..975.431 rows=247487 loops=3)
Index Cond: ((product_id = 140) AND (company_id = 1))
Buffers: shared hit=227534 read=330906 dirtied=83 written=683
Planning:
Buffers: shared hit=9 dirtied=1
Planning Time: 0.139 ms
Execution Time: 1114.732 ms
```
### After
```
Finalize GroupAggregate (cost=1000.56..21876.83 rows=538 width=80) (actual time=91.888..97.719 rows=1 loops=1)
Group Key: product_id
Buffers: shared hit=12889 read=7121
-> Gather (cost=1000.56..21849.93 rows=1076 width=80) (actual time=91.636..97.704 rows=3 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=12889 read=7121
-> Partial GroupAggregate (cost=0.56..20742.33 rows=538 width=80) (actual time=87.579..87.580 rows=1 loops=3)
Group Key: product_id
Buffers: shared hit=12889 read=7121
-> Parallel Index Only Scan using idx_svl_company_product on stock_valuation_layer
(cost=0.56..16951.60 rows=302613 width=20) (actual time=0.044..46.642 rows=247487 loops=3)
Index Cond: ((company_id = 1) AND (product_id = 140))
Heap Fetches: 9188
Buffers: shared hit=12889 read=7121
Planning Time: 0.107 ms
Execution Time: 97.751 ms
```
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#206587
Forward-Port-Of: odoo/odoo#203038Scenario: - edit the website theme and change a font to external font Buda - save and go back to edition and theme tab Result: Infinite spinning when loading the theme tab, and we see an error of AssetsLoadingError as well as an error 400 in console when loading https://fonts.googleapis.com/css?family=Buda URL. Issue: Buda font only has a 300 size, but when loading for the FontFamilyPickerUserValueWidget, we don't specify sizes so google fonts returns an error because there os no 400 size vers
Original PR description
Scenario: - edit the website theme and change a font to external font Buda - save and go back to edition and theme tab Result: Infinite spinning when loading the theme tab, and we see an error of AssetsLoadingError as well as an error 400 in console when loading https://fonts.googleapis.com/css?family=Buda URL. Issue: Buda font only has a 300 size, but when loading for the FontFamilyPickerUserValueWidget, we don't specify sizes so google fonts returns an error because there os no 400 size version of the font. This is not an issue when adding the font because we use 300 up to 700: d0ba6c26e64e711e21b191bdba0ede14abc6afb9 This is also not an issue for self-hosted google font because we load it with the same parameters: 5145d84dc02d8068a5feaac769f5d83cefc65804 opw-4657897 opw-4497707 opw-4338034 opw-3236787 opw-3584322 opw-3306789 Forward-Port-Of: odoo/odoo#207229
This error occurs when a user attempts to `Configure Document Layout` in settings using a large vertically-oriented image. Steps to Reproduce: - Install the `web` module. - Go to `Settings`. - In the `companies` section, under Your Company, click on `Update Info`. - Upload an image with dimensions width = 8 and height = 901. - Go back, and in the Companies section, click `Configure Document Layout`. ValueError: height and width must be > 0 This error is due to the current lo
Original PR description
This error occurs when a user attempts to `Configure Document Layout` in settings using a large vertically-oriented image. Steps to Reproduce: - Install the `web` module. - Go to `Settings`. - In the…
This error occurs when a user attempts to `Configure Document Layout` in settings using a large vertically-oriented image. Steps to Reproduce: - Install the `web` module. - Go to `Settings`. - In the `companies` section, under Your Company, click on `Update Info`. - Upload an image with dimensions width = 8 and height = 901. - Go back, and in the Companies section, click `Configure Document Layout`. ValueError: height and width must be > 0 This error is due to the current logic in `base_document_layout.py`, where the width (w) is computed using int(50 * base_w / base_h). For highly vertical images (e.g., width = 8, height = 901), this calculation results in w = 0, which subsequently causes a ValueError when passed to the resize() function. This commit resolves the error by using `math.ceil` to compute the width (w) instead of int, ensuring that the value is never zero, even for extremely vertical images. Sentry-6516888945 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#205017
The default rounding method of '_compute_quantity' function is "UP" while the rounding method used for stock quantities is "HALF-UP". Hence, small discrepancies in the valuation would be introduced over time. ## How to reproduce - Create product P, storable, tracked in Kg - Create a receipt/delivery move for 14g of P -> Stock Quant is updated by 0.01Kg -> Stock Valuation is updated by 0.02Kg OPW-4734980 --- Test result without fix: ``` 2025-04-22 13:40:45,088 38626 ERROR oes_tes
Original PR description
The default rounding method of '_compute_quantity' function is "UP" while the rounding method used for stock quantities is "HALF-UP". Hence, small discrepancies in the valuation would be introduced…
The default rounding method of '_compute_quantity' function is "UP" while the rounding method used for stock quantities is "HALF-UP". Hence, small discrepancies in the valuation would be introduced over time.
## How to reproduce
- Create product P, storable, tracked in Kg
- Create a receipt/delivery move for 14g of P -> Stock Quant is updated by 0.01Kg
-> Stock Valuation is updated by 0.02Kg
OPW-4734980
---
Test result without fix:
```
2025-04-22 13:40:45,088 38626 ERROR oes_test_16 odoo.addons.stock_account.tests.test_stockvaluation: FAIL: TestStockValuation.test_valuation_rounding_method
Traceback (most recent call last):
File "/home/odoo/projects/odoo-src/multiverse/src/16.0/odoo/addons/stock_account/tests/test_stockvaluation.py", line 4397, in test_valuation_rounding_method
self.assertEqual(receipt.move_ids.stock_valuation_layer_ids.quantity, 0.01)
AssertionError: 0.02 != 0.01
```
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#207066
Forward-Port-Of: odoo/odoo#206884In Hungary, when you fully reverse what is left to pay of an invoice with a Credit Note, it's usually called a "Storno" invoice, meaning an invoice that fully cancels what was previously sent. In the Hungarian EDI, invoices and credit notes are linked together, and they make a clear difference between a "modification" invoice (like a partial credit note, a debit note, etc) and a "cancellation" (Storno) invoice. We used to send it as a "modification" even when the residual amount was zero. Thi
Original PR description
In Hungary, when you fully reverse what is left to pay of an invoice with a Credit Note, it's usually called a "Storno" invoice, meaning an invoice that fully cancels what was previously sent. In the Hungarian EDI, invoices and credit notes are linked together, and they make a clear difference between a "modification" invoice (like a partial credit note, a debit note, etc) and a "cancellation" (Storno) invoice. We used to send it as a "modification" even when the residual amount was zero. This fix makes sure that it is sent as "cancellation" (Storno) in that case. task - 4707254 Forward-Port-Of: odoo/odoo#205390
Changing the syntax of the product code line in the invoice to not have a space before the colon. Example: `VTSZ : 8604000` -> `VTSZ: 8604000` task-4707459 Forward-Port-Of: odoo/odoo#206602
Original PR description
Changing the syntax of the product code line in the invoice to not have a space before the colon. Example: `VTSZ : 8604000` -> `VTSZ: 8604000` task-4707459 Forward-Port-Of: odoo/odoo#206602
**Current behavior before PR:** - When gradient image is applied on element other than font or span, applying a gradient color to its child text would trigger a traceback. **Desired behavior after PR is merged:** - Now, if the gradient image is applied on element other than font or span, applying gradient color on its child text will applied gradient color properly. task:4730500 Forward-Port-Of: odoo/odoo#206272
Original PR description
**Current behavior before PR:** - When gradient image is applied on element other than font or span, applying a gradient color to its child text would trigger a traceback. **Desired behavior after PR is merged:** - Now, if the gradient image is applied on element other than font or span, applying gradient color on its child text will applied gradient color properly. task:4730500 Forward-Port-Of: odoo/odoo#206272
When a partner's receivable account is set with a secondary currency, and an invoice is duplicated and its currency is changed, Odoo currently allows the invoice to be validated even though the account's currency no longer matches the invoice currency. that was because the order of calling ```_check_constrains_account_id_journal_id ``` in move line write function. This creates inconsistencies, as the account currency should match the invoice currency when posted. task-4684038 Descrip
Original PR description
When a partner's receivable account is set with a secondary currency, and an invoice is duplicated and its currency is changed, Odoo currently allows the invoice to be validated even though the account's currency no longer matches the invoice currency. that was because the order of calling ```_check_constrains_account_id_journal_id ``` in move line write function. This creates inconsistencies, as the account currency should match the invoice currency when posted. task-4684038 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#207238 Forward-Port-Of: odoo/odoo#204164
Add missing codes for payment methods --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#207034
Original PR description
Add missing codes for payment methods --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#207034
This PR refactors `_create_backorder `for better extensibility. Related: https://github.com/OCA/manufacture/pull/1467 @qrtl QT5016 Forward-Port-Of: odoo/odoo#207017 Forward-Port-Of: odoo/odoo#195958
Original PR description
This PR refactors `_create_backorder `for better extensibility. Related: https://github.com/OCA/manufacture/pull/1467 @qrtl QT5016 Forward-Port-Of: odoo/odoo#207017 Forward-Port-Of: odoo/odoo#195958
When the website domain is defined using punycode (e.g., `xn--ingenieurbro-mlb.localhost`), navigating to the Unicode URL (e.g., `Ingenieurbüro.localhost`) would not reflect the updated `robots.txt`. Steps to reproduce the issue: - Navigate to Website > Configuration > Website. - Set a domain name with punycode (e.g., http://xn--ingenieurbro-mlb.localhost:8069). - Go to settings and modify the robots.txt file. - Visit http://Ingenieurbüro.localhost:8069 and notice that the changes are n
Original PR description
When the website domain is defined using punycode (e.g., `xn--ingenieurbro-mlb.localhost`), navigating to the Unicode URL (e.g., `Ingenieurbüro.localhost`) would not reflect the updated `robots.txt`. Steps to reproduce the issue: - Navigate to Website > Configuration > Website. - Set a domain name with punycode (e.g., http://xn--ingenieurbro-mlb.localhost:8069). - Go to settings and modify the robots.txt file. - Visit http://Ingenieurbüro.localhost:8069 and notice that the changes are not reflected. This commit ensures the correct handling of punycode domains so that the robots.txt is properly served, regardless of whether the domain is accessed in Unicode or punycode form. opw-4641081 Forward-Port-Of: odoo/odoo#206215
The config param skip_create_bank_account_on_reconcile currently also skips the search. In the original commit https://github.com/odoo/odoo/commit/62354663c6622f6d059e36097f0455ab5890b616, it was not the case. It was a mistake during the fw-port 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#
Original PR description
The config param skip_create_bank_account_on_reconcile currently also skips the search. In the original commit https://github.com/odoo/odoo/commit/62354663c6622f6d059e36097f0455ab5890b616, it was not the case. It was a mistake during the fw-port 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#206496 Forward-Port-Of: odoo/odoo#206420
Before this commit, searching for a customer in the PoS using a phone number without spaces (e.g. "0612345678") would return no results if the number was stored with spaces (e.g. "06 12 34 56 78"). opw-4683209 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#206276
Original PR description
Before this commit, searching for a customer in the PoS using a phone number without spaces (e.g. "0612345678") would return no results if the number was stored with spaces (e.g. "06 12 34 56 78"). opw-4683209 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#206276
**Issue:** When User-defined Defaults are set for Unit of Measure (product.template or product.product) and sale_timesheet module is installed, the uom default is not respected. **Steps to reproduce:** - ensure sale_timesheet module is installed - settings > technical > user-defined Defaults - create a default for unit of measure (product.template) other than hour - create a new product of type service The issue occurs in both product.template and product.product opw-4604491 Forwa
Original PR description
**Issue:** When User-defined Defaults are set for Unit of Measure (product.template or product.product) and sale_timesheet module is installed, the uom default is not respected. **Steps to reproduce:** - ensure sale_timesheet module is installed - settings > technical > user-defined Defaults - create a default for unit of measure (product.template) other than hour - create a new product of type service The issue occurs in both product.template and product.product opw-4604491 Forward-Port-Of: odoo/odoo#204423
[FIX] accounting: missing chart line "758 Indemnités et autres produits" was missing Steps to reproduce: ------------------- * French Fiscal Localization * Open the Chart of Accounts * Line 758 missing Why the fix: ------------ Based on French government documentation https://www.anc.gouv.fr/files/anc/files/1_Normes_fran%C3%A7aises/Plans%20comptables/Plan-de-comptes-PCG-2025.pdf opw-4699235 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/
Original PR description
[FIX] accounting: missing chart line "758 Indemnités et autres produits" was missing Steps to reproduce: ------------------- * French Fiscal Localization * Open the Chart of Accounts * Line 758 missing Why the fix: ------------ Based on French government documentation https://www.anc.gouv.fr/files/anc/files/1_Normes_fran%C3%A7aises/Plans%20comptables/Plan-de-comptes-PCG-2025.pdf opw-4699235 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#207312 Forward-Port-Of: odoo/odoo#205552
Steps to reproduce [17.1]: - Add a property field to a job application in the backend. - Go to the linked website job application form (in edit mode). - The property field is inaccessible. To be able to access the new property field in the application form, the `job_id` value of the related job record needs to be specified by default. Unfortunately, these values are removed before accessing "edit" mode: Starting from [1], a fix was added to clear default values coming from `data-f
Original PR description
Steps to reproduce [17.1]: - Add a property field to a job application in the backend. - Go to the linked website job application form (in edit mode). - The property field is inaccessible. To be able…
Steps to reproduce [17.1]: - Add a property field to a job application in the backend. - Go to the linked website job application form (in edit mode). - The property field is inaccessible. To be able to access the new property field in the application form, the `job_id` value of the related job record needs to be specified by default. Unfortunately, these values are removed before accessing "edit" mode: Starting from [1], a fix was added to clear default values coming from `data-for` attributes when the form is edited (at `cleanForSave()`) to prevent saving it with changed default values. Since the code from [1] can also remove default values set by the user, a new fix (see [2]) updated this implementation to ensure that only values from auto-fill and data-for fields will be removed (this time, when the form public widget is destroyed [3]). The behaviour from [3] will always unlink the `data-for` values in edit mode, and as a consequence, the related property fields won't be correctly retrieved. The goal of this commit is to fix this behaviour by excluding `data-for` values from the reset in [3]. An extra check will be added to be sure the form won't be saved with updated default values if it already has `data-for` ones [4]. Important: The diff from [5] made the `email_to` field as an exception for the data-for/prefill priority system and only used the `data-for` value if nothing has been configured by the user (it also used the `data-for` value if what was configured by the user is the dummy default email: `info@yourcompany.example.com`). That's why we need to exceptionally allow saving the default value added by the user in the check from [4] to preserve the same behavior. Following [6], The `email_to` value won't be kept in edit mode to prevent breaking its dynamic behavior. [1]: https://github.com/odoo/odoo/commit/b637a5e32f767b62736241042f88fa0cecf9f10b [2]: https://github.com/odoo/odoo/commit/043e1fdf923d2037dd8da128ab99388f0c92e544 [5]: https://github.com/odoo/odoo/commit/a08574a04ff2ce8ea2d6fd2b79f56cc57bba953b [6]: https://github.com/odoo/odoo/commit/6658d61e304c9dfd8e512648c4a001dcaac44bc1 task-3922573 Forward-Port-Of: odoo/odoo#166565
Forward-Port-Of: odoo/enterprise#77188
Original PR description
Forward-Port-Of: odoo/enterprise#77188
### Issue: Although Fedex's API shoud accept GBP's UK currency for rate requests, you will raise a `CURRENCY.TYPE.INVALID` error from Fedex if you try to get the shipping rate for an order whose currency is GBP. ### Steps to reproduce: - Install UK accounting and select UK's company: the currency will be GBP - Install and set up Fedex Integration - Configure the Fedex in the delivery method, FEDEX_YOU_PACKAGE and Fedex priority for package type and service type - Create a sale order,
Original PR description
### Issue: Although Fedex's API shoud accept GBP's UK currency for rate requests, you will raise a `CURRENCY.TYPE.INVALID` error from Fedex if you try to get the shipping rate for an order whose…
### Issue: Although Fedex's API shoud accept GBP's UK currency for rate requests, you will raise a `CURRENCY.TYPE.INVALID` error from Fedex if you try to get the shipping rate for an order whose currency is GBP. ### Steps to reproduce: - Install UK accounting and select UK's company: the currency will be GBP - Install and set up Fedex Integration - Configure the Fedex in the delivery method, FEDEX_YOU_PACKAGE and Fedex priority for package type and service type - Create a sale order, add shipping and get the shipping rate for your set up fedex UK. #### > Fedex request error: `CURRENCY.TYPE.INVALID` ### Cause of the issue: The currency used in the fedex request is the currency of the order: https://github.com/odoo/enterprise/blob/07845988daad911b10de3b7199b81cc4ed3cfba9/delivery_fedex_rest/models/delivery_fedex.py#L133-L141 that is GBP, however since 44e32359bb79eed08a41861e155c98f664c6d09a we do not automatically convert the GBP currency in UKL. Since Fedex API does not seem to support the GBP we raise the error. ### Fix: We should use the currency conversion available between GBP and UKL. opw-4712354 Forward-Port-Of: odoo/enterprise#83388
Beofre this commit: Products with both positive and negative sales order lines in SO can result it total quantity = 0 when calcuating average cost. Causing division by zero error. After this commit: Added a check to prevent division if total quantity of product is zero. Negative order lines are usually used for return of product, it is not included in shipping request. opw-4655713 Forward-Port-Of: odoo/enterprise#83500
Original PR description
Beofre this commit: Products with both positive and negative sales order lines in SO can result it total quantity = 0 when calcuating average cost. Causing division by zero error. After this commit: Added a check to prevent division if total quantity of product is zero. Negative order lines are usually used for return of product, it is not included in shipping request. opw-4655713 Forward-Port-Of: odoo/enterprise#83500
This PR adds a validation check for a company's GST token before making GST API calls via cron. These validations already exist when making GST API calls through the GST return period but were missing in the cron execution. This ensures that no unnecessary cron execution and api call takes place. task-4350780 Forward-Port-Of: odoo/enterprise#81974
Original PR description
This PR adds a validation check for a company's GST token before making GST API calls via cron. These validations already exist when making GST API calls through the GST return period but were missing in the cron execution. This ensures that no unnecessary cron execution and api call takes place. task-4350780 Forward-Port-Of: odoo/enterprise#81974
In this commit: - Updated Table 12 HSN Summary to classify HSN data separately for B2B and B2C as per the latest GST advisory. - Previously, all HSN summary data was pushed into Table 12 without distinction. - Now, HSN summary is categorized into B2B and B2C for accurate reporting. Task ID: 4465102 Forward-Port-Of: odoo/enterprise#84015 Forward-Port-Of: odoo/enterprise#80738
Original PR description
In this commit: - Updated Table 12 HSN Summary to classify HSN data separately for B2B and B2C as per the latest GST advisory. - Previously, all HSN summary data was pushed into Table 12 without distinction. - Now, HSN summary is categorized into B2B and B2C for accurate reporting. Task ID: 4465102 Forward-Port-Of: odoo/enterprise#84015 Forward-Port-Of: odoo/enterprise#80738
Currently, when validating deliveries, if multiples attachments are posted in the same chatter message, the printing jobs do not complete. Steps to reproduce: ------------------- * Install fedex * In operation types, select Delivery Orders then hardware * In print on validation, enable Carrier Labels and Export Documents * In the shipping methods, select fedex international * Change Label format to ZPL11 * Connect the database to an iot box * Set up the shipping labels to be send on z
Original PR description
Currently, when validating deliveries, if multiples attachments are posted in the same chatter message, the printing jobs do not complete. Steps to reproduce: ------------------- * Install fedex * In…
Currently, when validating deliveries, if multiples attachments are posted in the same chatter message, the printing jobs do not complete. Steps to reproduce: ------------------- * Install fedex * In operation types, select Delivery Orders then hardware * In print on validation, enable Carrier Labels and Export Documents * In the shipping methods, select fedex international * Change Label format to ZPL11 * Connect the database to an iot box * Set up the shipping labels to be send on zebra printer * Set up commercial invoice (/invoice) to be sent to another printer * Create a sale order, using fedex international as shipping * Confirm the SO * Select the delivery * Validate the delivery > Observation: Nothing prints, jobs are sent to CUPS bu not printing Why the fix: ------------ https://github.com/odoo/enterprise/blob/8075101192fb81a78f2a984cf2adf67fc77c0194/delivery_fedex_rest/models/delivery_fedex.py#L192-L196 As show, when sending the shipping, if the invoice is generated, it gets added to the attachements. The function `message_post` will post all attachments in the same chatter message. In `delivery_iot` the `message_post` function is overridden to allow sending the printing jobs to the iot. https://github.com/odoo/enterprise/blob/8075101192fb81a78f2a984cf2adf67fc77c0194/delivery_iot/models/stock_picking.py#L33-L46 Here, `attachments_names` will both contain `Label` and `ShippingDoc`. Since we enter the first if condition, the report is related to the shipping labels. Then we send the data related to all attachments to the device linked to the shipping labels, aka the zebra printer. Since the other attachment is of type PDF, the zebraprinter does not know what to do with it and ends up printing nothing. Since we can have multiple different attachment, the if/elseif condition does not make sense. By breaking it in two if, we can send both reports separately, while still keeping all attachments in the same chatter message. opw-4546715 Forward-Port-Of: odoo/enterprise#82094
Forward-Port-Of: odoo/enterprise#83992
Original PR description
Forward-Port-Of: odoo/enterprise#83992
Steps to reproduce: - starting planning_test_tour => error raised Source: - https://github.com/odoo/enterprise/pull/69888 introduced a new method _get_non_working_days_bounds which computes user_tz but the value can be False and also not coherent with user_tz computed in _calculate_start_end_dates (method from wich this new method is called) Fix: user_tz is computed the same way as its computed in the original method, the code is duplicated as signature cannot be changed in stable. For
Original PR description
Steps to reproduce: - starting planning_test_tour => error raised Source: - https://github.com/odoo/enterprise/pull/69888 introduced a new method _get_non_working_days_bounds which computes user_tz but the value can be False and also not coherent with user_tz computed in _calculate_start_end_dates (method from wich this new method is called) Fix: user_tz is computed the same way as its computed in the original method, the code is duplicated as signature cannot be changed in stable. Forward-Port-Of: odoo/enterprise#83926