Monday, September 9, 2024
46 changes · saas-17.4
Resolved issues and error corrections
This fix stops successful report image conversions from being treated as problems just because they produced warning messages. It helps keep system logs cleaner and makes real conversion errors easier to spot.
Original PR description
There may have warnings on stderr, even in case of success.
This fixes an issue where duplicate device session records could cause an error when a user changed their language. The change helps keep user settings updates reliable even when multiple devices share the same session details.
Original PR description
[FIX] base: deletion of duplicate device session Steps: - Have 2 devices log with the same last_activity, platform, browser, ip, session, user - Try to change the language of the user Actual result: - Missing record The record does not exist or has been deleted. (Record: res.device(X,), user: Y) Expected result: - No error, SQL view have distinct setup See: https://github.com/odoo/odoo/pull/162168 https://github.com/odoo/odoo/pull/177233 opw-4148761 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fix makes user device records return consistent identifiers during the same operation. It prevents intermittent errors where a device record appeared to disappear, improving reliability when editing user information.
Original PR description
Issue: ------ Within the same transaction, the ids of the `res.device` model (non-materialised view) may not be consistent. This inconsistency triggers the error: ``` Record does not exist or has…
Issue:
------
Within the same transaction, the ids of the `res.device` model (non-materialised view) may not be consistent. This inconsistency triggers the error:
```
Record does not exist or has been deleted.
```
This behaviour can occur during an onchange on the `res.user` model, for example. We will determine the ids of the `device_ids` linked to the user with the following query (A):
```
SELECT id, user_id FROM res_device WHERE user_id=<user_id> ORDER BY id
```
We will obtain the ids of the devices linked to the user. However, for a given device, it is possible to perform a fetch to retrieve the field values. A query (B) of the following form is used:
```
SELECT <field_to_fetch> FROM res_device WHERE id=<id>
```
Unfortunately, it can happen that the id is no longer present in the `res_device` table. If we look at the query plans (in the appendices), postgresql takes the decision to remove the `user_id` from the `DISTINCT ON` clause when it is used in a `WHERE` clause (which influences the internal logic of Postgresql).
In practice, we sometimes get different results because of the sorting, which can be indeterministic depending on (d.session_identifier, d.platform, d.browser, d.last_activity DESC). In fact, there is a scenario (multiple workers) in which a device will create two logs with the same `last_activity`.
Solution:
---------
Add the `id` to the `ORDER BY` to obtain a deterministic sort.
Appendices:
-----------
Query A:
```
explain select id, user_id from res_device where user_id=2;
QUERY PLAN
-------------------------------------------------------------------------------------------
Subquery Scan on res_device (cost=39.39..42.13 rows=125 width=8)
-> Unique (cost=39.39..40.88 rows=125 width=233)
-> Sort (cost=39.39..39.76 rows=149 width=233)
Sort Key: d.session_identifier, d.platform, d.browser, d.last_activity DESC
-> Seq Scan on res_device_log d (cost=0.00..34.01 rows=149 width=233)
Filter: ((NOT revoked) AND (user_id = 2))
```
Query B:
```
explain select id, user_id from res_device;
QUERY PLAN
------------------------------------------------------------------------------------------------------
Subquery Scan on res_device (cost=39.29..42.52 rows=128 width=8)
-> Unique (cost=39.29..41.24 rows=128 width=233)
-> Sort (cost=39.29..39.68 rows=156 width=233)
Sort Key: d.user_id, d.session_identifier, d.platform, d.browser, d.last_activity DESC
-> Seq Scan on res_device_log d (cost=0.00..33.61 rows=156 width=233)
Filter: (NOT revoked)
```The Point of Sale code was updated to remove an outdated date-handling method that is no longer used by the current payment flow. This reduces maintenance risk and helps keep payment-related behavior consistent without changing the cashier experience.
Original PR description
This commit removes the `getUTCString` method from PoS, as it is no longer relevant to the current implementation. opw-4109126 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fixes an issue where saving or cancelling an edited chatter note required two clicks. Users can now complete message edits immediately, reducing confusion and extra clicks in daily communication workflows.
Original PR description
Problem: Elements inside `CANCEL_OR_SAVE_EDIT_TEXT` are created twice, which interferes with event handling. To fix this, the element is now created in the setup method. Steps to reproduce: - Open the chatter. - Log a note. - Edit the note. - Now, if you click Save or Cancel, both actions will only work on the second click. opw-4119283 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The accounting journal setup now shows wording that matches the type of journal being configured. For miscellaneous journals, email-based creation is labeled as creating entries instead of invoices, reducing confusion for users.
Original PR description
When going on a misc journal, the title of the group is "create invoices upon emails" but in the case of a misc journal we don't want to create an invoice but an entry. We will duplicate the group and change the invisible conditions to make it work. task: 4160550 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Description of the issue/feature this PR addresses: When we try to send an invitation email with the pr_BR template it crashes because it tries to access the `signup_url` through `object`, but instead it should be accessed through `object.partner_id._get_signup_url()` Current behavior before PR: When you try to send an invitation email with language Portuguese (BR) / Português (BR) under Localization, it crashes. Desired behavior after PR is merged: When you try to send an invitation em
Original PR description
Description of the issue/feature this PR addresses: When we try to send an invitation email with the pr_BR template it crashes because it tries to access the `signup_url` through `object`, but instead it should be accessed through `object.partner_id._get_signup_url()` Current behavior before PR: When you try to send an invitation email with language Portuguese (BR) / Português (BR) under Localization, it crashes. Desired behavior after PR is merged: When you try to send an invitation email with language Portuguese (BR) / Português (BR) under Localization, it works. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Miscellaneous changes
Since the canned response settings is introduced in Discuss, the usage of canned responses is not limited to livechat only, so that the /help message should be available in the Disucss as well. after:  --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#179502
Original PR description
Since the canned response settings is introduced in Discuss, the usage of canned responses is not limited to livechat only, so that the /help message should be available in the Disucss as well. after:  --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#179502
Problem: While merging two partners in the contact app using the _update_foreign_keys method, the foreign keys are merged using SQL instead of ORM. The issue is that the partner_share field is computed based on the user_ids field and is stored. If we update using SQL, it will not trigger the _compute_partner_share method, which will set the latest value. Other problems might arise for fields that are computed based on foreign keys updated using SQL during a merge. Steps to reproduce: I
Original PR description
Problem: While merging two partners in the contact app using the _update_foreign_keys method, the foreign keys are merged using SQL instead of ORM. The issue is that the partner_share field is computed based on the user_ids field and is stored. If we update using SQL, it will not trigger the _compute_partner_share method, which will set the latest value. Other problems might arise for fields that are computed based on foreign keys updated using SQL during a merge. Steps to reproduce: In a new database, create a basic contact (individual, with name and email). Merge this contact with another contact who has document access (e.g., Marc Demo). Go to any product page. Add a log note and tag the new contact. The contact will receive an email without the "View product" button. opw-3864317 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#175966
Since the refactor https://github.com/odoo/odoo/pull/110188, the welcome page had several bugs: 1) The `fa-microphone-slash` icon was displayed when the microphone was on instead of when the microphone was mute. 2) The localStorage keys `discuss_call_preview_join_mute` and `discuss_call_preview_join_video` were set with booleans, while the localStorage stores as strings, which made them always truthy as soon as they were set. 3) The microphone preview was not working as the `srcObject`
Original PR description
Since the refactor https://github.com/odoo/odoo/pull/110188, the welcome page had several bugs: 1) The `fa-microphone-slash` icon was displayed when the microphone was on instead of when the…
Since the refactor https://github.com/odoo/odoo/pull/110188, the welcome page had several bugs: 1) The `fa-microphone-slash` icon was displayed when the microphone was on instead of when the microphone was mute. 2) The localStorage keys `discuss_call_preview_join_mute` and `discuss_call_preview_join_video` were set with booleans, while the localStorage stores as strings, which made them always truthy as soon as they were set. 3) The microphone preview was not working as the `srcObject` of the audio element was `undefined` because we were using `this.audioStream` instead of `this.state.audioStream`. 4) Before the refactor, the preview was automatically started when opening the welcome page, this commit restores this behavior: https://github.com/odoo/odoo/blob/16.0/addons/mail/static/src/models/discuss_public_view.js#L46-L49 5) Streams (tracks) were not closed after leaving the welcome view, nor was it checked whether they were still needed after the `getUserMedia` promise. Forward-Port-Of: odoo/odoo#178563 Forward-Port-Of: odoo/odoo#177525
Steps to reproduce the bug: 1. Install the Sales and Loyalty apps. 2. Create a sales order for 'client x' and assign a loyalty reward to it. 3. Invoice the sales order with a down payment. 4. Navigate to the Helpdesk app and create a ticket for 'client x'. 5. Create a task for the ticket and check the Sales order item list. Issue: The sales order item list incorrectly includes down payments and loyalty rewards due to an imprecise domain. Solution: Adding a domain function that we ca
Original PR description
Steps to reproduce the bug: 1. Install the Sales and Loyalty apps. 2. Create a sales order for 'client x' and assign a loyalty reward to it. 3. Invoice the sales order with a down payment. 4. Navigate to the Helpdesk app and create a ticket for 'client x'. 5. Create a task for the ticket and check the Sales order item list. Issue: The sales order item list incorrectly includes down payments and loyalty rewards due to an imprecise domain. Solution: Adding a domain function that we can override computed field where it's necessary, to filter the sale_order_line records accurately. opw-4001226 enterprise pr : https://github.com/odoo/enterprise/pull/66388 Forward-Port-Of: odoo/odoo#179288 Forward-Port-Of: odoo/odoo#173667
In makeAsyncHandler and makeButtonHandler have been modified in commit fcb16a3b1bd373726ffb54f0fbe41fb6d1784769 to remove guardedCatch. However, in both cases, if result is rejected, Promise.resolve(result) will (quite unexpectedly because of the name of the method) be rejected too. Calling finally on this promise will indeed call the callback, but it will still let the exception bubble up, eventually resulting in a second unhandledrejection for the same original exception. With this commi
Original PR description
In makeAsyncHandler and makeButtonHandler have been modified in commit fcb16a3b1bd373726ffb54f0fbe41fb6d1784769 to remove guardedCatch. However, in both cases, if result is rejected,…
In makeAsyncHandler and makeButtonHandler have been modified in commit fcb16a3b1bd373726ffb54f0fbe41fb6d1784769 to remove guardedCatch. However, in both cases, if result is rejected, Promise.resolve(result) will (quite unexpectedly because of the name of the method) be rejected too. Calling finally on this promise will indeed call the callback, but it will still let the exception bubble up, eventually resulting in a second unhandledrejection for the same original exception. With this commit, we instead call then(callback, callback) on that Promise, so that the rejection is caught and callback is indeed called in both cases. To reproduce this issue in saas-17.4, raise a UserError in the route /website_sale/should_show_product_configurator and add a Drawer to your cart: the exception message is displayed twice. This reproduction doesn't work in 17.0 because the promise is a dialog.opened() that crashes and never resolves, masking the issue (but there is a hint of this, because the loading effect is also never removed from the button (meaning that the callback of makeButtonHandler is never called). Many thanks to MCM to help me understand what was happening here. Forward-Port-Of: odoo/odoo#179563 Forward-Port-Of: odoo/odoo#179512
Before this commit, copying an automation rule did not copy its actions. After, it will. Task: 4055597 Forward-Port-Of: odoo/odoo#179546 Forward-Port-Of: odoo/odoo#179350
Original PR description
Before this commit, copying an automation rule did not copy its actions. After, it will. Task: 4055597 Forward-Port-Of: odoo/odoo#179546 Forward-Port-Of: odoo/odoo#179350
When the user changes the language in My Profile and tries to save, a traceback will appear. Steps to reproduce the error: - Install ```account_accountant``` and ```hr``` module - Activate multi languages - Go to accounting > Dashboard > New Invoice - Click on the profile icon > My Profile > Change language > Save Traceback: ``` ValueError: too many values to unpack (expected 1) File "odoo/models.py", line 5851, in ensure_one _id, = self._ids ValueError: Expected singleton:
Original PR description
When the user changes the language in My Profile and tries to save, a traceback will appear. Steps to reproduce the error: - Install ```account_accountant``` and ```hr``` module - Activate multi…
When the user changes the language in My Profile and tries to save,
a traceback will appear.
Steps to reproduce the error:
- Install ```account_accountant``` and ```hr``` module
- Activate multi languages
- Go to accounting > Dashboard > New Invoice
- Click on the profile icon > My Profile > Change language > Save
Traceback:
```
ValueError: too many values to unpack (expected 1)
File "odoo/models.py", line 5851, in ensure_one
_id, = self._ids
ValueError: Expected singleton: account.move('n', 'e', 'w')
File "odoo/http.py", line 2254, in __call__
response = request._serve_db()
File "odoo/http.py", line 1829, in _serve_db
return self._transactioning(_serve_ir_http, readonly=ro)
File "odoo/http.py", line 1849, in _transactioning
return service_model.retrying(func, env=self.env)
File "odoo/service/model.py", line 134, in retrying
result = func()
File "odoo/http.py", line 1827, in _serve_ir_http
return self._serve_ir_http(rule, args)
File "odoo/http.py", line 1834, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 2059, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "odoo/addons/base/models/ir_http.py", line 220, in _dispatch
result = endpoint(**request.params)
File "odoo/http.py", line 740, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "addons/web/controllers/action.py", line 96, in load_breadcrumbs
display_names.append(Model.browse(record_id).display_name)
File "odoo/fields.py", line 1202, in __get__
record.ensure_one()
File "odoo/models.py", line 5854, in ensure_one
raise ValueError("Expected singleton: %s" % self)
```
https://github.com/odoo/odoo/blob/59985860264f7fbd2726a51ff15d7e5101ae8234/addons/web/controllers/action.py#L97
Here, when the user changes the language and tries to save the record.
we received record_id as ('n', 'e', 'w'),
when it tries to access display_name
So it will lead to the above traceback.
This issue is similar to https://github.com/odoo/odoo/pull/163087
sentry-5135218331
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#167492### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a backorder - Create a product P (no need for a bom) - Create and confirm a manufacturing order for 2 units of the product - Go to the barcode module > operations > manufacturing > the MO - Register only one unit of P and produce #### > A backorder is automatically created but you are redirected to t
Original PR description
### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a…
### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a backorder - Create a product P (no need for a bom) - Create and confirm a manufacturing order for 2 units of the product - Go to the barcode module > operations > manufacturing > the MO - Register only one unit of P and produce #### > A backorder is automatically created but you are redirected to the backend. #### Note: If you were in "ask" on create backorder or if your product had a bom and you did not register the quantities of consumed components, a pop up would appear and resolving the pop up would redirect you to the kanban view of mrp.production in the barcode module. ### Cause of the issue: The issue was originally solved by commit d90acab by overriding the `action_backorder` however, since commit 1e5c82f the action_backorder is no more part of the flow in "always" backorder. opw-3890886 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#178674 Forward-Port-Of: odoo/odoo#178492
[FIX] project: restrict access to project in email sent Before this commit, when the `Project Stages` feature is enabled and the user set an email template on a project stage, if the user moves a project to that stage with the email template, an email is sent to the customer (if set on the project) and the customer can click on the project name to see all tasks inside that project even if the project is private. This commit makes sure the project name displayed in the template is only
Original PR description
[FIX] project: restrict access to project in email sent Before this commit, when the `Project Stages` feature is enabled and the user set an email template on a project stage, if the user moves a…
[FIX] project: restrict access to project in email sent Before this commit, when the `Project Stages` feature is enabled and the user set an email template on a project stage, if the user moves a project to that stage with the email template, an email is sent to the customer (if set on the project) and the customer can click on the project name to see all tasks inside that project even if the project is private. This commit makes sure the project name displayed in the template is only clickable is the project visibility is 'portal' (`Invited portal users and all internal users`). Steps to reproduce: ------------------ 1. Install project 2. Go to Project > Configuration > Settings 3. Enable Project Stages feature 4. Set email template to project stage 5. Create a project with a customer set and project visibility is not set to "Invited portal users and all internal users". 6. Move the project to the project stage with the email template set. Current behavior: ---------------- An email is sent based on the email template set but the project name is clickable to allow the customer to see the tasks of the project in the portal even if the project is not public. Expected behavior: ----------------- The project name should not be clickable inside the email sent when the project visibility is not "Invited portal users and all internal users". Close #175396 Forward-Port-Of: odoo/odoo#178260 Forward-Port-Of: odoo/odoo#178171
### Description of the issue/feature this PR addresses: Wrong account on tax definition. Taxes should not have related payable and receivable accounts. ### Current behavior before PR: VAT 0% Exempt taxes has a payable account, this not valid one and will result on error when creating an invoice with that tax. We resolve the problem by changing the account used on the tax definition with new accounts, one for Sales (Current liabilities) and another for Purchase (Current Aseste), the sam
Original PR description
### Description of the issue/feature this PR addresses: Wrong account on tax definition. Taxes should not have related payable and receivable accounts. ### Current behavior before PR: VAT 0% Exempt taxes has a payable account, this not valid one and will result on error when creating an invoice with that tax. We resolve the problem by changing the account used on the tax definition with new accounts, one for Sales (Current liabilities) and another for Purchase (Current Aseste), the same way is made for the VAT 22% and VAT 10%) ### Desired behavior after PR is merged: Taxes has the proper account and we are able to create invoices/bills with tax 0% without problem ADHOC ticket 76475 - task 34060 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#170773
Steps to reproduce ================== - Go to Sales > Quotation - Open any record - Open studio - Switch to the x2many list view - Insert a new html field - Exist studio - Type some text in the html field - Select a portion of it - Click on the bold button => Nothing happens Solution ======== Don't unselect the current row when clicking inside the editor toolbar opw-4064662 Forward-Port-Of: odoo/odoo#178189 Forward-Port-Of: odoo/odoo#175880
Original PR description
Steps to reproduce ================== - Go to Sales > Quotation - Open any record - Open studio - Switch to the x2many list view - Insert a new html field - Exist studio - Type some text in the html field - Select a portion of it - Click on the bold button => Nothing happens Solution ======== Don't unselect the current row when clicking inside the editor toolbar opw-4064662 Forward-Port-Of: odoo/odoo#178189 Forward-Port-Of: odoo/odoo#175880
Following commit https://github.com/odoo/odoo/pull/171765/files# multi-currencies are not supported anymore by our edi engine. Using a currency other than euro leads to an invalid XML file. Steps to reproduce: 1. install Italian E-invoicing 2. make sure your have access to another currency, along with EUR 3. create a partner outside of Europe (e.g. US-based - using USD) 4. create an invoice for that partner 5. confirm + send and print the invoice (generate XML file) 6. go to https
Original PR description
Following commit https://github.com/odoo/odoo/pull/171765/files# multi-currencies are not supported anymore by our edi engine. Using a currency other than euro leads to an invalid XML file. Steps to reproduce: 1. install Italian E-invoicing 2. make sure your have access to another currency, along with EUR 3. create a partner outside of Europe (e.g. US-based - using USD) 4. create an invoice for that partner 5. confirm + send and print the invoice (generate XML file) 6. go to https://www.fatturacheck.it/ to verify the XML 7. Error 2.2.2.5 should be returned opw-4038850 opw-4129380 opw-4123758 opw-4095910 Forward-Port-Of: odoo/odoo#175996
We don't need `point_of_sale` module on the IoT Box: we only need configuration files in it. We don't load it anymore to prevent from having error messages on service start. We also added a new alias to simplify pip usage and removed unused pyotp package. Forward-Port-Of: odoo/odoo#179308
Original PR description
We don't need `point_of_sale` module on the IoT Box: we only need configuration files in it. We don't load it anymore to prevent from having error messages on service start. We also added a new alias to simplify pip usage and removed unused pyotp package. Forward-Port-Of: odoo/odoo#179308
Issue : 17.0 When a global discount is applied on a sale order with tax included in the price, the discount was incorrectly calculated based on the tax-excluded price. This resulted in inaccurate discount amounts and incorrect tax calculations. steps to reproduce: - Create a tax with included in price (e.g. 10% incl). - Create a sale order with the 10% incl tax. - Now, apply a global discount (e.g. 10%) Cause : When applying a global discount, the system incorrectly calculates the d
Original PR description
Issue : 17.0 When a global discount is applied on a sale order with tax included in the price, the discount was incorrectly calculated based on the tax-excluded price. This resulted in inaccurate discount amounts and incorrect tax calculations. steps to reproduce: - Create a tax with included in price (e.g. 10% incl). - Create a sale order with the 10% incl tax. - Now, apply a global discount (e.g. 10%) Cause : When applying a global discount, the system incorrectly calculates the discount based on the tax-excluded price rather than the unit price. Fix : Ensure the total amount is calculated useing price_unit(price_unit) instead of subtotal. This corrects the discount application and maintains accurate pricing. opw-4018841 Forward-Port-Of: odoo/odoo#174678
Steps to reproduce: * install `l10n_mx` * Create a partner * duplicate it * upload an invoice/bill xml with the duplicated partner Issue: A new duplication of the partner will be created Cause: If no partner is found, we will create another one https://github.com/odoo/enterprise/blob/c66a452661c1e5ff9f837e7e1e21e068fec4c124/l10n_mx_edi/models/account_move.py#L2524-L2545 Solution: The VAT should be a sufficiently distinctive criterion to link a partner Ticket [link](https://www
Original PR description
Steps to reproduce: * install `l10n_mx` * Create a partner * duplicate it * upload an invoice/bill xml with the duplicated partner Issue: A new duplication of the partner will be created Cause: If no partner is found, we will create another one https://github.com/odoo/enterprise/blob/c66a452661c1e5ff9f837e7e1e21e068fec4c124/l10n_mx_edi/models/account_move.py#L2524-L2545 Solution: The VAT should be a sufficiently distinctive criterion to link a partner Ticket [link](https://www.odoo.com/odoo/project/967/tasks/4124253) opw-4124253 Forward-Port-Of: odoo/odoo#178078
Steps to reproduce the bug: - Turn on the Cookies from setting for the website. - Go to front end, click on editor, go to theme tab. - Click on any Font Family, and select add a google font. - After adding, save. - Add a "Title" block, go to "mobile view", and add a text highlight. - Save the page. - Bug: If you switch between mobile and desktop views, the highlights are not updated (because the SVGs are fixed and get added to the view of the page). The bug occurred because some opti
Original PR description
Steps to reproduce the bug: - Turn on the Cookies from setting for the website. - Go to front end, click on editor, go to theme tab. - Click on any Font Family, and select add a google font. - After adding, save. - Add a "Title" block, go to "mobile view", and add a text highlight. - Save the page. - Bug: If you switch between mobile and desktop views, the highlights are not updated (because the SVGs are fixed and get added to the view of the page). The bug occurred because some options, like the popup, trigger a resize after a delay before the page is saved. This causes the highlights to be added back to the DOM after the "TextHighlight" widget has been destroyed. To fix this, we prevent adding highlights if the "TextHighlight" widget has been destroyed. opw-4081390 Forward-Port-Of: odoo/odoo#178022
### Issue: Previous fix: odoo/odoo@4c0f03c7a1d1ec1f99dbc8b2202454e4398e386b In CH tax report, tax amounts from Payments of Expenses paid by company are not shown when using taxes with Cash Basis. ### Explanation: The CH report uses tags to fetch taxes. With previous fix, those tags were still not passed through. ### Fix reasoning: We will use the same condition for the `include_caba_tags` parameter as for the `caba_no_transition_account` context key for consistency. opw-394636
Original PR description
### Issue: Previous fix: odoo/odoo@4c0f03c7a1d1ec1f99dbc8b2202454e4398e386b In CH tax report, tax amounts from Payments of Expenses paid by company are not shown when using taxes with Cash Basis. ### Explanation: The CH report uses tags to fetch taxes. With previous fix, those tags were still not passed through. ### Fix reasoning: We will use the same condition for the `include_caba_tags` parameter as for the `caba_no_transition_account` context key for consistency. opw-3946362 Forward-Port-Of: odoo/odoo#179295 Forward-Port-Of: odoo/odoo#177246
Current behavior before PR: 1. When we attempt to paste an H1 element into a P element, the H1 element gets converted to a P element. 2. When pasting from GDocs, nested UL or OL is a direct child of its parent UL or OL, rather than being child of LI with class `oe-nested`. 3. Copy/pasting multiple paragraphs into a list does not convert it to list. 4. When pasting content that begins with a list and includes other tags below it into a new list, only the list is pasted, resulting in a loss
Original PR description
Current behavior before PR: 1. When we attempt to paste an H1 element into a P element, the H1 element gets converted to a P element. 2. When pasting from GDocs, nested UL or OL is a direct child of…
Current behavior before PR: 1. When we attempt to paste an H1 element into a P element, the H1 element gets converted to a P element. 2. When pasting from GDocs, nested UL or OL is a direct child of its parent UL or OL, rather than being child of LI with class `oe-nested`. 3. Copy/pasting multiple paragraphs into a list does not convert it to list. 4. When pasting content that begins with a list and includes other tags below it into a new list, only the list is pasted, resulting in a loss of the other content. 5. Copy/pasting one list over another bullets does not get transformed. 6. When copying a checklist from Google Docs, the check options are pasted as images. Desired behavior after PR is merged: 1. When we attempt to paste an H1 element onto a P element, the H1 element will remain as an H1 element. 2. When pasting from GDocs, nested UL or OL are contained within an LI element with class `oe-nested`. 3. Copy/pasting multiple paragraphs into a list gets converted to list. 4. Pasting content with a list and other tags should no longer result in the loss of content. 5. Copy/pasting one list over another bullets get transformed. 6. Check options copied as image from Google Docs will no longer be pasted as images; instead the images should be removed and class `o_checklist` should be add to the closest list. task-2956048 Co-authored-by: Deependra Solanki <deso@odoo.com> --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#179159 Forward-Port-Of: odoo/odoo#115019
Version: 16 Description of the issue/feature this PR addresses: A third party check received in a customer payment with journal with type "Cash" and Incoming payment method "New Third Party Checks" is not on hand in menu "Accounting / Customers / Third Party Checks" if journal doesn't has "Existing Third Party Checks" incoming payment method. Steps to reproduce: 1) Log in with admin on runbot odoo enterprise 16 instance and install l10n_latam_check (Third Party and Deferred/Electroni
Original PR description
Version: 16 Description of the issue/feature this PR addresses: A third party check received in a customer payment with journal with type "Cash" and Incoming payment method "New Third Party Checks"…
Version: 16 Description of the issue/feature this PR addresses: A third party check received in a customer payment with journal with type "Cash" and Incoming payment method "New Third Party Checks" is not on hand in menu "Accounting / Customers / Third Party Checks" if journal doesn't has "Existing Third Party Checks" incoming payment method. Steps to reproduce: 1) Log in with admin on runbot odoo enterprise 16 instance and install l10n_latam_check (Third Party and Deferred/Electronic Checks Management) module. 2) Go to "Accounting / Configuration /Accounting / Journals" and create a new journal of type "Cash" and add incoming payment method "New Third Party Checks".  3) Create a new customer payment with journal created on step 2 and "New Third Party Checks" payment method and confirm.  4) Go to menu Third Party Checks and the check received on step 3 is not on hand.  Current behavior before PR: A third party check received in a customer payment with journal with type "Cash" and Incoming payment method "New Third Party Checks" is not on hand on tree view in "Accounting / Customers / Third Party Checks" if the journal doesn't has "Existing Third Party Checks" incoming payment method. Desired behavior after PR is merged: A third party check received in a customer payment with journal with type "Cash" and Incoming payment method "New Third Party Checks" is on hand on tree view in "Accounting / Customers / Third Party Checks" if the journal doesn't has "Existing Third Party Checks" incoming payment method. Ticket Adhoc side: 77887 Task Latam side: 1234 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#174283
Partners can have multiple Bank accounts in an active database, some being even added automatically on Bank reconciliation. But usually, only some specific accounts that are used for outgoing payments will be marked as "trusted". Currently, when you select a Vendor on a draft Vendor Bill, the first account of the partner is taken, whether or not the account is trusted. This Pr will give priority to the accounts that are trusted. task: 4166740 --- I confirm I have signed the CLA a
Original PR description
Partners can have multiple Bank accounts in an active database, some being even added automatically on Bank reconciliation. But usually, only some specific accounts that are used for outgoing payments will be marked as "trusted". Currently, when you select a Vendor on a draft Vendor Bill, the first account of the partner is taken, whether or not the account is trusted. This Pr will give priority to the accounts that are trusted. task: 4166740 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#179365
### Steps to reproduce the issue: 1. Create two Taxes, one with Fixed "Tax Computation" and one with Percentage of Price. 2. Set "Included in Price" to True and and "Affect Base of Subsequent Taxes" to False for both. 3. Create an Invoice with one line, add both Taxes to it, make sure each Tax has a different amount. 4. Change the order of the Taxes in the Taxes menu 5. Refresh the Invoice Line (e.g.: remove and put back one of the taxes) 6. The amount of the "percent" Tax has changed al
Original PR description
### Steps to reproduce the issue: 1. Create two Taxes, one with Fixed "Tax Computation" and one with Percentage of Price. 2. Set "Included in Price" to True and and "Affect Base of Subsequent Taxes"…
### Steps to reproduce the issue: 1. Create two Taxes, one with Fixed "Tax Computation" and one with Percentage of Price. 2. Set "Included in Price" to True and and "Affect Base of Subsequent Taxes" to False for both. 3. Create an Invoice with one line, add both Taxes to it, make sure each Tax has a different amount. 4. Change the order of the Taxes in the Taxes menu 5. Refresh the Invoice Line (e.g.: remove and put back one of the taxes) 6. The amount of the "percent" Tax has changed along with the Untaxed Amount of the Invoice ### Explanation: In `_prepare_taxes_computation`, taxes are preprocessed with a priority set on fixed taxes, then taxes with `price_include` set to True, both in descending order and lastly, taxes with `price_include` set to False in ascending order. In `_propagate_extra_taxes_base`, the currently preprocessed tax is also added to the base of other taxes depending on the specifications of those taxes. When `price_include` is set to True, taxes are never being added to the base of the ones with a higher sequence, it should only be the case if `include_base_amount` is set to True as well. ### Fix reasoning: The computation should be consistent regardless of the order of the taxes, as they are not supposed to have an influence on each other. The special modes computation are changed accordingly. The change to the `total_included` special mode for non `_original_price_include` batches fixes an inconsistency when all taxes are excluded, added a test for it. opw-4068781 Forward-Port-Of: odoo/odoo#176150
Add support for E-Invoicing in Vietnam by allowing to connect Odoo with SInvoice by Viettel. Task id # 3631616 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#160079
Original PR description
Add support for E-Invoicing in Vietnam by allowing to connect Odoo with SInvoice by Viettel. Task id # 3631616 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#160079
**Steps:** - Create a few products and e-commerce categories - Go to the shop page - Hover on the eCommerce categories created - A bit displacement is seen in the margin **Issue:** - The margin is given to adjust the height of the scrollbar on hover but it's applied even when scrollbar is not present (when handful of categories are there) resulting in a displacement. **Fix:** - Disabling the margin on hover when there are less categories that is when scrollbar is not present **Aff
Original PR description
**Steps:** - Create a few products and e-commerce categories - Go to the shop page - Hover on the eCommerce categories created - A bit displacement is seen in the margin **Issue:** - The margin is given to adjust the height of the scrollbar on hover but it's applied even when scrollbar is not present (when handful of categories are there) resulting in a displacement. **Fix:** - Disabling the margin on hover when there are less categories that is when scrollbar is not present **Affected version:** 17.0~master opw-4088697 Forward-Port-Of: odoo/odoo#179047 Forward-Port-Of: odoo/odoo#178545
If we have two bills with the same bill ref and two different partner, one with NIF and the other without it, the schedule action to process SII response might fail since the code expect a NIF in the SII response when there is not (bill with partner without NIF). Technical example: ```py >>> partner_info # Candidate invoice in odoo {'IDOtro': {'ID': 'NO_DISPONIBLE', 'IDType': '06', 'CodigoPais': 'ES'}} >>> respl_partner_info # SII response {'NIF': '12345678K', 'IDOtro': None} ``` This
Original PR description
If we have two bills with the same bill ref and two different partner, one with NIF and the other without it, the schedule action to process SII response might fail since the code expect a NIF in the…
If we have two bills with the same bill ref and two different partner, one with NIF and the other without it, the schedule action to process SII response might fail since the code expect a NIF in the SII response when there is not (bill with partner without NIF).
Technical example:
```py
>>> partner_info # Candidate invoice in odoo
{'IDOtro': {'ID': 'NO_DISPONIBLE', 'IDType': '06', 'CodigoPais': 'ES'}}
>>> respl_partner_info # SII response
{'NIF': '12345678K', 'IDOtro': None}
```
This causes a rollback and no bills at all are processed in Odoo's side.
Steps to reproduce:
1/ Create a l10n_es company with l10n_es_edi_sii in test mode
2/ Create a bill with a bill reference 10001, some lines (ex: negative lines)
that will trigger an error from SII and a partner with a NIF
3/ Copy the partner and remove the NIF
4/ Copy the first bill, keep the same bill reference and change the partner to
copied one
5/ Post both bills
6/ Trigger the schedule action "EDI : Perform web services operations" => Traceback with
ValueError: <class 'AttributeError'>: "'NoneType' object has no attribute 'ID'" while evaluating
Now, a default value is set when the key is not found in respl_partner_info.IDOtro .
opw-4102638
Forward-Port-Of: odoo/odoo#177902Description: - This PR introduces an Rs. 1 tolerance for amount matching to prevent unnecessary bill creation for minor discrepancies (e.g., paisa differences). It also improves bill reference number matching by handling special characters and comparing numerically as text. Impact: - Reduces unnecessary bill creation. - Enhances accuracy in matching bill reference numbers. Task ID: 3975209 Forward-Port-Of: odoo/enterprise#66121
Original PR description
Description: - This PR introduces an Rs. 1 tolerance for amount matching to prevent unnecessary bill creation for minor discrepancies (e.g., paisa differences). It also improves bill reference number matching by handling special characters and comparing numerically as text. Impact: - Reduces unnecessary bill creation. - Enhances accuracy in matching bill reference numbers. Task ID: 3975209 Forward-Port-Of: odoo/enterprise#66121
Before this commit: When a user with Billings rights scans a QR code using the vendor QR scan feature, an ir.act.window access error appears. After this commit: We fix the access error. And the QR scan feature works correctly as intended. Forward-Port-Of: odoo/enterprise#69700
Original PR description
Before this commit: When a user with Billings rights scans a QR code using the vendor QR scan feature, an ir.act.window access error appears. After this commit: We fix the access error. And the QR scan feature works correctly as intended. Forward-Port-Of: odoo/enterprise#69700
Steps to reproduce the bug: 1. Install the Sales and Loyalty apps. 2. Create a sales order for 'client x' and assign a loyalty reward to it. 3. Invoice the sales order with a down payment. 4. Navigate to the Helpdesk app and create a ticket for 'client x'. 5. Create a task for the ticket and check the Sales order item list. Issue: The sales order item list incorrectly includes down payments and loyalty rewards due to an imprecise domain. Solution: Adding a domain function that we ca
Original PR description
Steps to reproduce the bug: 1. Install the Sales and Loyalty apps. 2. Create a sales order for 'client x' and assign a loyalty reward to it. 3. Invoice the sales order with a down payment. 4. Navigate to the Helpdesk app and create a ticket for 'client x'. 5. Create a task for the ticket and check the Sales order item list. Issue: The sales order item list incorrectly includes down payments and loyalty rewards due to an imprecise domain. Solution: Adding a domain function that we can override computed field where it's necessary, to filter the sale_order_line records accurately. opw-4001226 odoo pr : https://github.com/odoo/odoo/pull/173667 Forward-Port-Of: odoo/enterprise#69516 Forward-Port-Of: odoo/enterprise#66388
The problem was that the button tag doesn't support drag & drop functionality in Firefox (https://bugzilla.mozilla.org/show_bug.cgi?id=568313). Steps to reproduce (On firefox): - Open Sign up - Open template - Try to drag and drop new compoent - You can only drag and drop through the text inside opw-4085496 Forward-Port-Of: odoo/enterprise#67772
Original PR description
The problem was that the button tag doesn't support drag & drop functionality in Firefox (https://bugzilla.mozilla.org/show_bug.cgi?id=568313). Steps to reproduce (On firefox): - Open Sign up - Open template - Try to drag and drop new compoent - You can only drag and drop through the text inside opw-4085496 Forward-Port-Of: odoo/enterprise#67772
### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a backorder - Create a product P (no need for a bom) - Create and confirm a manufacturing order for 2 units of the product - Go to the barcode module > operations > manufacturing > the MO - Register only one unit of P and produce #### > A backorder is automatically created but you are redirected to t
Original PR description
### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a…
### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a backorder - Create a product P (no need for a bom) - Create and confirm a manufacturing order for 2 units of the product - Go to the barcode module > operations > manufacturing > the MO - Register only one unit of P and produce #### > A backorder is automatically created but you are redirected to the backend. ### Note: If you were in "ask" on create backorder or if your product had a bom and you did not register the quantities of consumed components, a pop up would appear and resolving the pop up would redirect you to the kanban view of mrp.production in the barcode module. ### Cause of the issue: The issue was originally solved by commit d90acab by overriding the `action_backorder` however, since commit 1e5c82f the action_backorder is no more part of the flow in "always" flows. opw-3890886 Forward-Port-Of: odoo/enterprise#69229 Forward-Port-Of: odoo/enterprise#69169
Forward-Port-Of: odoo/enterprise#69591
Original PR description
Forward-Port-Of: odoo/enterprise#69591
This commit adds the missing neutralization necessary for the l10n_uy_edi module introduced in [1] The purpose of the standard neutralization framework is to allow us to create database copies that will not interact with external systems in ways that could impact the production database (or if it is not possible to prevent the interactions, make sure that they are benign or won't result in actual changes), or impact the customers of the operator of the production database. This is ma
Original PR description
This commit adds the missing neutralization necessary for the l10n_uy_edi module introduced in [1] The purpose of the standard neutralization framework is to allow us to create database copies that will not interact with external systems in ways that could impact the production database (or if it is not possible to prevent the interactions, make sure that they are benign or won't result in actual changes), or impact the customers of the operator of the production database. This is mainly useful to allow safe support investigation on database duplicates. [1] https://github.com/odoo/enterprise/pull/51266 Forward-Port-Of: odoo/enterprise#69555
The CAR (Código de Anotación de Registro) is an alphanumeric identifier composed of payment voucher data. It includes: - RUC number of the issuer: 11 numeric digits. - Type of payment voucher: 2 numeric digits. - Payment voucher series: 4 alphanumeric digits. - Payment voucher number: 10 alphanumeric digits.  Previously, support for SIRE reports was added. This change updates the general ledger t
Original PR description
The CAR (Código de Anotación de Registro) is an alphanumeric identifier composed of payment voucher data. It includes: - RUC number of the issuer: 11 numeric digits. - Type of payment voucher: 2…
The CAR (Código de Anotación de Registro) is an alphanumeric identifier composed of payment voucher data. It includes: - RUC number of the issuer: 11 numeric digits. - Type of payment voucher: 2 numeric digits. - Payment voucher series: 4 alphanumeric digits. - Payment voucher number: 10 alphanumeric digits.  Previously, support for SIRE reports was added. This change updates the general ledger to ensure compatibility. Adjusted the format of the 'book' field to include zero-padded and truncated document types, series, and folio numbers. Legal reference: https://www.sunat.gob.pe/legislacion/superin/2021/anexo-112-2021.pdf  Resolutions: [Resolución de Superintendencia N.° 112-2021](https://drive.google.com/file/d/19iWgqTeTn5WNIg3RpfAyHtF6xSIFL2rH/view?usp=sharing) Forward-Port-Of: odoo/enterprise#68808 Forward-Port-Of: odoo/enterprise#67911
Steps to reproduce: [l10n_be] - Create a customer from Spain with the following VAT: A12345674 - Create an invoice with the customer - Go to EC Sales report Issue: The country code used in the report is "A1" Solution: Instead of inferring the country code from the VAT, we use the country code per se; to be a bit more defensive we fall back on the initial flow in case there is no country code. opw-4080828 Forward-Port-Of: odoo/enterprise#69125
Original PR description
Steps to reproduce: [l10n_be] - Create a customer from Spain with the following VAT: A12345674 - Create an invoice with the customer - Go to EC Sales report Issue: The country code used in the report is "A1" Solution: Instead of inferring the country code from the VAT, we use the country code per se; to be a bit more defensive we fall back on the initial flow in case there is no country code. opw-4080828 Forward-Port-Of: odoo/enterprise#69125
Issue ----- [website_sale_renting] In case there is already a rental product in the cart, it is still possbile to open the date range picker by clicking the calendar button and selecting a new period, which will have no effect as the rental period can only be changed from the cart. Change ----- Disable the date picker but keep the calendar button as it contains a help message. opw-4076088 Forward-Port-Of: odoo/enterprise#67645
Original PR description
Issue ----- [website_sale_renting] In case there is already a rental product in the cart, it is still possbile to open the date range picker by clicking the calendar button and selecting a new period, which will have no effect as the rental period can only be changed from the cart. Change ----- Disable the date picker but keep the calendar button as it contains a help message. opw-4076088 Forward-Port-Of: odoo/enterprise#67645
This PR fixes a wrong documentation link in the helpdesk team form view. Task-4102472 Forward-Port-Of: odoo/enterprise#68101
Original PR description
This PR fixes a wrong documentation link in the helpdesk team form view. Task-4102472 Forward-Port-Of: odoo/enterprise#68101
Steps to reproduce: - Subscriptions > New > Set recurrence - Set 'Date of next invoice' in the future - Renew This should raise a ValidationError because renewing a subscription which was never started (no invoice) is invalid, as specified in the error message "You cannot upsell or renew a subscription that has not been invoiced yet". opw-4116538 Forward-Port-Of: odoo/enterprise#69361
Original PR description
Steps to reproduce: - Subscriptions > New > Set recurrence - Set 'Date of next invoice' in the future - Renew This should raise a ValidationError because renewing a subscription which was never started (no invoice) is invalid, as specified in the error message "You cannot upsell or renew a subscription that has not been invoiced yet". opw-4116538 Forward-Port-Of: odoo/enterprise#69361
Description: - This accommodates scenarios where the main customer raises a ticket for a delivery partner. Changes: - Code modification for improved flexibility in handling cases where the main customer raises a ticket for the delivery partner. task-3623707 Forward-Port-Of: odoo/enterprise#69610 Forward-Port-Of: odoo/enterprise#52864
Original PR description
Description: - This accommodates scenarios where the main customer raises a ticket for a delivery partner. Changes: - Code modification for improved flexibility in handling cases where the main customer raises a ticket for the delivery partner. task-3623707 Forward-Port-Of: odoo/enterprise#69610 Forward-Port-Of: odoo/enterprise#52864
In this pr: https://github.com/odoo/odoo/pull/171795 we added some computed fields which caused an increase on the query count of the l10n_au_hr_payroll_account module, this commit will increase that. task: 4127269 Forward-Port-Of: odoo/enterprise#69703
Original PR description
In this pr: https://github.com/odoo/odoo/pull/171795 we added some computed fields which caused an increase on the query count of the l10n_au_hr_payroll_account module, this commit will increase that. task: 4127269 Forward-Port-Of: odoo/enterprise#69703
Scanned barcodes were not saved (setting field in record do not register the change). Continue Production did not take advantage of saveModel parameter of doActionAndClose Forward-Port-Of: odoo/enterprise#69623 Forward-Port-Of: odoo/enterprise#69544
Original PR description
Scanned barcodes were not saved (setting field in record do not register the change). Continue Production did not take advantage of saveModel parameter of doActionAndClose Forward-Port-Of: odoo/enterprise#69623 Forward-Port-Of: odoo/enterprise#69544