Tuesday, August 27, 2024
16 changes · saas-17.2
Resolved issues and error corrections
Duplicating a spreadsheet sheet now correctly keeps comment tracking linked to the new sheet. This prevents errors when users add rows or columns after duplicating a sheet with comments, improving reliability for spreadsheet workflows.
Original PR description
Backport of https://github.com/odoo/enterprise/pull/68406 as the issue was introduced in saas-17.2. Duplicating a sheet would not add the sheet ID to the cellThreads map in the cell threads plugin. This would cause issues when adding rows or columns because the sheetId can't be referenced and an error is thrown. Added a case in handle in order to add the new sheet id from duplicating to the cellThreads map. opw-4100746
Miscellaneous changes
Before this commit, the salesmen did not had the right group and the test crashed with the following error when the test was run without demo data: ``` FAIL: TestCommissions.test_commission_plan_rules_with_template Traceback (most recent call last): File "/data/build/enterprise/partner_commission/tests/test_commissions.py", line 221, in test_commission_plan_rules_with_template form.sale_order_template_id = so_template File "/data/build/odoo/odoo/tests/form.py", line 326, in __set
Original PR description
Before this commit, the salesmen did not had the right group and the test crashed with the following error when the test was run without demo data: ``` FAIL:…
Before this commit, the salesmen did not had the right group and the test crashed with the following error when the test was run without demo data:
```
FAIL: TestCommissions.test_commission_plan_rules_with_template
Traceback (most recent call last):
File "/data/build/enterprise/partner_commission/tests/test_commissions.py", line 221, in test_commission_plan_rules_with_template
form.sale_order_template_id = so_template
File "/data/build/odoo/odoo/tests/form.py", line 326, in __setattr__
self[field_name] = value
File "/data/build/odoo/odoo/tests/form.py", line 331, in __setitem__
assert field_info is not None, f"{field_name!r} was not found in the view"
AssertionError: 'sale_order_template_id' was not found in the view
```
runbot task: 70916 and 73195
https://runbot.odoo.com/web/#id=70916&view_type=form&model=runbot.build.error&menu_id=405&cids=1 https://runbot.odoo.com/web/#id=73195&view_type=form&model=runbot.build.error&menu_id=405&cids=1
Forward-Port-Of: odoo/enterprise#68829Before the commit the [appointment single module build](https://runbot.odoo.com/runbot/build/66250461) is breaking due to query_count being more than 9 (11) The increase was introduced in b3487219c070cdc03c933d92bc0d362ad733e11f in `_unavailable_intervals_batch`. It wasn't detected because the are less queries in the standard build all modules installed) because of a warmer ormcache. (get_lang) This commit proposes to warmup the test in all case to avoid the extra queries when appointment
Original PR description
Before the commit the [appointment single module build](https://runbot.odoo.com/runbot/build/66250461) is breaking due to query_count being more than 9 (11) The increase was introduced in b3487219c070cdc03c933d92bc0d362ad733e11f in `_unavailable_intervals_batch`. It wasn't detected because the are less queries in the standard build all modules installed) because of a warmer ormcache. (get_lang) This commit proposes to warmup the test in all case to avoid the extra queries when appointment is installed alone, hopefully avoiding to miss the increased query count next time. Forward-Port-Of: odoo/enterprise#67769
### Steps to Reproduce: - Create a field service task > switch the worksheet template to false > add products and timesheets > sign report > error because there is no worksheet template set. ### After this PR: - Allow signing the report when there is no worksheet template, it will be possible to sign and send the report as long as there is content to populate the report with ( products and timesheets). task-3974170 Forward-Port-Of: odoo/enterprise#68787 Forward-Port-Of: odoo/enterprise#
Original PR description
### Steps to Reproduce: - Create a field service task > switch the worksheet template to false > add products and timesheets > sign report > error because there is no worksheet template set. ### After this PR: - Allow signing the report when there is no worksheet template, it will be possible to sign and send the report as long as there is content to populate the report with ( products and timesheets). task-3974170 Forward-Port-Of: odoo/enterprise#68787 Forward-Port-Of: odoo/enterprise#65367
Issue ----- When setting a "Counted Quantity" of 0 in the inventory adjustment, the difference would incorrectly stay as 0. Steps ----- 1. Inventory > Operations > Physical Inventory. 2. Set the "Counted Quantity" of a line where it is not set to 0. -> The difference stays at 0. Cause ----- The widget was previously relying on an onchange being triggered even if the actual value wasn't changed in input fields. This beahviour was modified by https://github.com/odoo/odoo/commit/dc
Original PR description
Issue ----- When setting a "Counted Quantity" of 0 in the inventory adjustment, the difference would incorrectly stay as 0. Steps ----- 1. Inventory > Operations > Physical Inventory. 2. Set the "Counted Quantity" of a line where it is not set to 0. -> The difference stays at 0. Cause ----- The widget was previously relying on an onchange being triggered even if the actual value wasn't changed in input fields. This beahviour was modified by https://github.com/odoo/odoo/commit/dcba2a87b7ab15b357d57c410868f19e829a8db0. https://github.com/odoo/odoo/blob/69de944b95a9790548b239f3bf05ba48eda2efef/addons/web/static/src/views/fields/input_field_hook.js#L74 Since then, changing the value from 0.00 to 0 won't trigger the onchange and the difference won't be computed. Change ----- Update the record on blur, in the same way it is already done on keydown. opw-4064858 opw-4063994 Forward-Port-Of: odoo/odoo#175680
Problem: The tax group name is not translated to Arabic. Purpose: Display the Arabic translation of the tax group name as well to stay consistent with the report. Steps to Reproduce: 1. Install l10n_sa 2. Switch to SA company 3. Add Arabic as a language 4. Add an Arabic translation for a tax group name 5. Change a contact's language to Arabic 6. Create an invoice with the Arabic contact and a tax from the same tax group 7. Preview or Print and observe that the tax group name is n
Original PR description
Problem: The tax group name is not translated to Arabic. Purpose: Display the Arabic translation of the tax group name as well to stay consistent with the report. Steps to Reproduce: 1. Install l10n_sa 2. Switch to SA company 3. Add Arabic as a language 4. Add an Arabic translation for a tax group name 5. Change a contact's language to Arabic 6. Create an invoice with the Arabic contact and a tax from the same tax group 7. Preview or Print and observe that the tax group name is not translated to Arabic opw-4094196 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#177307
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#177854
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#177854
Steps to reproduce: ------------------- - Have xlrd >= 2.0 and openpyxl 3.1.2 - Using the base_import module, import an XLSX file with empty cells - You will notice that all empty cells are read as "None" - Click on test, will give this error : "Column debit contains incorrect values (value: None)" Cause: ----- Since (#169245) openpyxl is used instead of xlrd for parsing xlsx files, the empty cells are parsed as None, not as empty string (as it was in xlrd). then this None is cast to t
Original PR description
Steps to reproduce: ------------------- - Have xlrd >= 2.0 and openpyxl 3.1.2 - Using the base_import module, import an XLSX file with empty cells - You will notice that all empty cells are read as "None" - Click on test, will give this error : "Column debit contains incorrect values (value: None)" Cause: ----- Since (#169245) openpyxl is used instead of xlrd for parsing xlsx files, the empty cells are parsed as None, not as empty string (as it was in xlrd). then this None is cast to the string "None", causing issues. Fix: ----- An additional check added to check if the cell is empty (value is None) and set it as empty string. opw-4132402 Forward-Port-Of: odoo/odoo#177770
Currently, when various timestamps in Odoo are processed through the `DeserializeDate` function, the offset is being doubled by mistake. The Odoo timestamps are passed as strings which have already been converted to UTC. If a user inputs a `DateTime` on a pricelist for instance, that time will be converted to its UTC equivalent before being converted to a string. The issue arises when we try to parse that string in the frontend during a PoS session. Odoo will correctly parse the timestamp, howev
Original PR description
Currently, when various timestamps in Odoo are processed through the `DeserializeDate` function, the offset is being doubled by mistake. The Odoo timestamps are passed as strings which have already…
Currently, when various timestamps in Odoo are processed through the `DeserializeDate` function, the offset is being doubled by mistake. The Odoo timestamps are passed as strings which have already been converted to UTC. If a user inputs a `DateTime` on a pricelist for instance, that time will be converted to its UTC equivalent before being converted to a string. The issue arises when we try to parse that string in the frontend during a PoS session. Odoo will correctly parse the timestamp, however through the `DeserializeDate` function it calls the `FromSQL` function with the parameter `zone: 'default'` which makes Odoo process this timestamp as being in the `SystemZone` (which is used by default in Luxon) instead of correctly recognizing that it is already in UTC. Thus, it will offset it again, which causes the functionality to fail This commit allows the timezone in `DeserializeDate` to be passed as a parameter, so in these cases we can pass the correct timezone and avoid this issue. Task-ID: 4106252 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#177180 Forward-Port-Of: odoo/odoo#176866
It was possible to upload a file and decode it by attaching it to a message in the chatter (factur-x, ulb...), but not by attaching it directly to the invoice. This commit allows for the same behaviour in both ways. task-3997526 Forward-Port-Of: odoo/odoo#171393
Original PR description
It was possible to upload a file and decode it by attaching it to a message in the chatter (factur-x, ulb...), but not by attaching it directly to the invoice. This commit allows for the same behaviour in both ways. task-3997526 Forward-Port-Of: odoo/odoo#171393
Currently there might be a line break after the phone marker in the contact widget. It depends on the document layout and the length of the phone number. After this commit the line break does not happen anymore. (In commit cbcda0b222b17312b9e42e23801a330f0030033f line breaks inside phone numbers were removed.) To reproduce: 1. Ensure Purchase app is installed 2. Settings -> Configure Document Layout - layout: boxed - font: Oswald - paper format: A4 3. Edit some partner t
Original PR description
Currently there might be a line break after the phone marker in the contact widget. It depends on the document layout and the length of the phone number. After this commit the line break does not happen anymore. (In commit cbcda0b222b17312b9e42e23801a330f0030033f line breaks inside phone numbers were removed.) To reproduce: 1. Ensure Purchase app is installed 2. Settings -> Configure Document Layout - layout: boxed - font: Oswald - paper format: A4 3. Edit some partner to have a long phone number (E.g. via Purchase -> Orders (menu) -> Vendors) e.g. use: (870)-931-0505 12 12 12 12 4. Create a request for quotation / purchase order and select the partner from 3 as Vendor 5. Confirm the purchase order 6. Print the purchase order 7. There is a line break after the phone marker in the vendor address opw-3783870 opw-3970768 PR the mentioned commit belongs to: https://github.com/odoo/odoo/pull/166336 Forward-Port-Of: odoo/odoo#175693
#### Partner feedbacks - Add small box notification in settings when NAV 3.0 authentication succeeds. - Add warning if the user un-checks the 'NAV 3.0' checkbox in the Send & Print. - Amend module manifest to clarify that we are electronically reporting paper invoices. - Report the *date of payment*, not date of issue of advance invoices as `advancePaymentDate` when issuing the final invoice. In addition, advanceExchangeRate should be the HUF exchange rate used for the payment. - Add a wa
Original PR description
#### Partner feedbacks - Add small box notification in settings when NAV 3.0 authentication succeeds. - Add warning if the user un-checks the 'NAV 3.0' checkbox in the Send & Print. - Amend module…
#### Partner feedbacks - Add small box notification in settings when NAV 3.0 authentication succeeds. - Add warning if the user un-checks the 'NAV 3.0' checkbox in the Send & Print. - Amend module manifest to clarify that we are electronically reporting paper invoices. - Report the *date of payment*, not date of issue of advance invoices as `advancePaymentDate` when issuing the final invoice. In addition, advanceExchangeRate should be the HUF exchange rate used for the payment. - Add a warning if not all advance invoices are paid when issuing the final invoice. - Add more checks in tests that the invoice checks pass when opening the Send & Print wizard. - Make the 'HU Tax Reason' field invisible if the tax has VAT type. #### Bugfixes - connection testing should be done on res.config.settings `create()`, not on `set_values()` because the related fields are written during the create, which is called in a prior transaction to the set_values. This ensures that if the connection cannot be established, the UserError causes the rollback of the transaction before the values are written to res_company. - the parse_error_response method wasn't correctly parsing error results leading to empty error messages Many thanks to: - Eiler Attila (online-erp.hu) - Geza Nagy (oregional.hu) taskid: 3985127 Forward-Port-Of: odoo/odoo#177788 Forward-Port-Of: odoo/odoo#168932
Use the delivery date to fill the `FechaOperacion` and fall back to the invoice date if no delivery date is set. Steps: - Make an invoice with delivery_date != invoice_date != today - Send invoice to gouvernment - Download the xml generated - The field `FechaOperacion` is the invoice date instead of the delivery date opw-4072748 Forward-Port-Of: odoo/odoo#174677
Original PR description
Use the delivery date to fill the `FechaOperacion` and fall back to the invoice date if no delivery date is set. Steps: - Make an invoice with delivery_date != invoice_date != today - Send invoice to gouvernment - Download the xml generated - The field `FechaOperacion` is the invoice date instead of the delivery date opw-4072748 Forward-Port-Of: odoo/odoo#174677
**Current behavior:** In the purchase report pivot view, grouping by order does not display the order reference on the row's label. **Expected behavior:** Rows corresponding to a purchase order should be labeled with the order reference (name). **Steps to reproduce:** 1. In the Purchase app, go to Reporting -> Purchase 2. Switch to the pivot view 3. Expand the row to Add Custom Group -> Order 4. See that the reference does not get displayed **Cause of the issue:** When we s
Original PR description
**Current behavior:** In the purchase report pivot view, grouping by order does not display the order reference on the row's label. **Expected behavior:** Rows corresponding to a purchase order should be labeled with the order reference (name). **Steps to reproduce:** 1. In the Purchase app, go to Reporting -> Purchase 2. Switch to the pivot view 3. Expand the row to Add Custom Group -> Order 4. See that the reference does not get displayed **Cause of the issue:** When we select group by for the `order` option, the rows are aggregated via `count_distinct`, so the label for the pivot becomes '1' (as they are grouped by id which is unique). **Fix:** Make the order_id field in the view `type=row` instead of `type=measure` so that they do not get aggregated. opw-4075321 Forward-Port-Of: odoo/odoo#177761 Forward-Port-Of: odoo/odoo#176915
UBL rule DK-R-005 limits the options available for the payment means. Currently, we have a hard-coded value of 30 for every invoice, because it is not possible to deduce the right payment means code at the moment. In OIOUBL we hard-code this field to `unknown` as it has the same UBL rule. With this commit we can use a different value for DK partners. In the future we could try to populate it dynamically. See also: https://docs.peppol.eu/poacc/billing/3.0/rules/ubl-peppol/DK-R-005/ opw-
Original PR description
UBL rule DK-R-005 limits the options available for the payment means. Currently, we have a hard-coded value of 30 for every invoice, because it is not possible to deduce the right payment means code at the moment. In OIOUBL we hard-code this field to `unknown` as it has the same UBL rule. With this commit we can use a different value for DK partners. In the future we could try to populate it dynamically. See also: https://docs.peppol.eu/poacc/billing/3.0/rules/ubl-peppol/DK-R-005/ opw-4080715 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#177430
When editing a message, the mentions of the original message were lost. The reason is that the channel mentions were not stored with the message in the database. The fix is to parse the body directly before editing and get mentionedChannels from it. follow-up of task-4104895 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#176472
Original PR description
When editing a message, the mentions of the original message were lost. The reason is that the channel mentions were not stored with the message in the database. The fix is to parse the body directly before editing and get mentionedChannels from it. follow-up of task-4104895 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#176472