Daily updates from Odoo
Navigate
Branch
Thursday, August 1, 2024
52 changes
15 changes
Enhancements to existing features
User availability is now updated only when it actually changes or when a websocket disconnects, instead of refreshing every minute. This lowers server load while keeping chat and presence statuses accurate across devices.
Original PR description
*: hr_holidays, mail. Before this PR, the main tab updated the user presence every minute. As a result of this update, it would also receive the IM statuses it was interested in. However, this approach puts significant pressure on the gevent worker, especially when it handles more databases than the registry can hold. To address this issue, this PR improves the way presences are updated: - Presences are sent and broadcasted when they change (e.g. away => online). - When a websocket disconnects, the user is considered disconnected. If other devices receive this notification, they will update the user presence immediately. These changes greatly reduce traffic caused by presence updates while keeping the IM statuses reliable.
Resolved issues and error corrections
This update fixes an issue in Point of Sale where certain exempt fields were incorrectly connected during loading. It helps prevent potential data handling problems and improves reliability when the POS starts up.
Original PR description
Before this commit, exempted fields were being connected upon loading, which could lead to issues. opw-4088809 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Miscellaneous changes
Steps to reproduce: - Sell any item in POS (Pick item > Payment > Bank > Validate) - Print receipt with 0 margin (current default) on external printer - Leftmost part of the receipt is truncated Why is this an issue: Frankly, since this issue only occurs on external printers and we haven't had complaints from people using Odoo supported devices (by that I mean connected to an IoT box) this could be considered not to be our problem. The receipt margins have been made smaller since 15.0 tho
Original PR description
Steps to reproduce: - Sell any item in POS (Pick item > Payment > Bank > Validate) - Print receipt with 0 margin (current default) on external printer - Leftmost part of the receipt is truncated Why…
Steps to reproduce: - Sell any item in POS (Pick item > Payment > Bank > Validate) - Print receipt with 0 margin (current default) on external printer - Leftmost part of the receipt is truncated Why is this an issue: Frankly, since this issue only occurs on external printers and we haven't had complaints from people using Odoo supported devices (by that I mean connected to an IoT box) this could be considered not to be our problem. The receipt margins have been made smaller since 15.0 though so there could be more people with this issue. I've tried printing one here and it is very slightly cut off, but that might depend on the device. What this fix does: This fix aims to reestablish margins as close to the way they were in 15.0 as possible (Don't want to go overboard and cut off the right) As it was in this commit b29c4a6113a002528aeed1fa59e823172bfce841 opw-3996929 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173669
When the event is deleted and the user tries to download tickets for that event, a traceback will appear. Steps to reproduce the error: - Go to Website > Events > Open any event > register > confirm registration of the ticket - Go to Events > Open that event > delete attendees > delete that event - Download tickets of that event Traceback: ``` TypeError: unsupported operand types(s) or combination of types: 'str' and 'event.event' File "odoo/http.py", line 2248, in __call__ r
Original PR description
When the event is deleted and the user tries to download tickets for that event, a traceback will appear. Steps to reproduce the error: - Go to Website > Events > Open any event > register > confirm…
When the event is deleted and the user tries to download tickets for that event,
a traceback will appear.
Steps to reproduce the error:
- Go to Website > Events > Open any event > register > confirm registration of the ticket
- Go to Events > Open that event > delete attendees > delete that event
- Download tickets of that event
Traceback:
```
TypeError: unsupported operand types(s) or combination of types: 'str' and 'event.event'
File "odoo/http.py", line 2248, in __call__
response = request._serve_db()
File "odoo/http.py", line 1823, in _serve_db
return self._transactioning(_serve_ir_http, readonly=ro)
File "odoo/http.py", line 1843, 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 1821, in _serve_ir_http
return self._serve_ir_http(rule, args)
File "odoo/http.py", line 1828, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 1966, in dispatch
return 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 756, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "addons/event/controllers/main.py", line 50, in event_my_tickets
if not consteq(tickets_hash, hash_truth):
```
https://github.com/odoo/odoo/blob/7b9df7c95c5f6a96d4d00c5d64e394141124752b/addons/event/controllers/main.py#L50 Here, when user deletes the event, 'event_sudo' will be empty,
So, eventually 'hash_truth' will be empty.
So it will lead to the above traceback.
sentry-5499927956
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#169921Before this commit, it was possible to add a pricelist in a different currency than the config currency, which is not supported. opw-4073993 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#175103
Original PR description
Before this commit, it was possible to add a pricelist in a different currency than the config currency, which is not supported. opw-4073993 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#175103
**Before this PR:** In link tracker form, if there is no campaign/medium/source, 'No matches found' message is directly displayed and the text-box for input disappears quickly. **Specifications:** We need to keep the input text-box open to be able to create new records on the fly. **Technical Reason:** defined 'formatNoMatches' as false to keep text-box open. **After this PR:** Text-box for input will remain open and will not disappear. Task-4065969 Forward-Port-Of: odoo/odoo#17
Original PR description
**Before this PR:** In link tracker form, if there is no campaign/medium/source, 'No matches found' message is directly displayed and the text-box for input disappears quickly. **Specifications:** We need to keep the input text-box open to be able to create new records on the fly. **Technical Reason:** defined 'formatNoMatches' as false to keep text-box open. **After this PR:** Text-box for input will remain open and will not disappear. Task-4065969 Forward-Port-Of: odoo/odoo#174360
Before this commit, scanning a barcode on the payment screen would mistakenly capture the barcode value as the payment amount. This could lead to incorrect payment amounts being recorded if not noticed by the cashier. opw-4079147 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#175048 Forward-Port-Of: odoo/odoo#174992
Original PR description
Before this commit, scanning a barcode on the payment screen would mistakenly capture the barcode value as the payment amount. This could lead to incorrect payment amounts being recorded if not noticed by the cashier. opw-4079147 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#175048 Forward-Port-Of: odoo/odoo#174992
Prior to this commit, enabling limited product loading could result in the discount product not being loaded. opw-4057657 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#174957 Forward-Port-Of: odoo/odoo#173600
Original PR description
Prior to this commit, enabling limited product loading could result in the discount product not being loaded. opw-4057657 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#174957 Forward-Port-Of: odoo/odoo#173600
v2.3.0 of Owl added the .translate modifier to props, allowing them to be translated. This commit updates the script that generates the .pot files (the list of source terms to translate) in order to take into account props with the .translate modifier. Task-3980675 Forward-Port-Of: odoo/odoo#174865 Forward-Port-Of: odoo/odoo#174697
Original PR description
v2.3.0 of Owl added the .translate modifier to props, allowing them to be translated. This commit updates the script that generates the .pot files (the list of source terms to translate) in order to take into account props with the .translate modifier. Task-3980675 Forward-Port-Of: odoo/odoo#174865 Forward-Port-Of: odoo/odoo#174697
Description of the issues this commit addresses: As from the first of september 2024, Finland will raise 24% taxes to 25.5%, those rates are currently not available in Odoo. --- Desired behavior after this commit is merged: New 25.5% taxes are available in Finland OSS tax mapping is done for other countries to Finland The mapping from Finland to other countries is deliberately left for later as we don't want the mapping to 25.5% to tkae place before the 09/01/24. --- task-4010
Original PR description
Description of the issues this commit addresses: As from the first of september 2024, Finland will raise 24% taxes to 25.5%, those rates are currently not available in Odoo. --- Desired behavior after this commit is merged: New 25.5% taxes are available in Finland OSS tax mapping is done for other countries to Finland The mapping from Finland to other countries is deliberately left for later as we don't want the mapping to 25.5% to tkae place before the 09/01/24. --- task-4010731 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#174805 Forward-Port-Of: odoo/odoo#171414
Before this commit the qweb profiler was broken. Steps to reproduce: - enable profiling and record qweb and it's directive for 5 minutes. - then go to Settings > Configure Document Layout > click on save. - then go to Settings > Techincal > Profiling and open profile - /web/dataset/call_kw/base.document.layout/onchange? Observed behavior: qweb profiler css is not appropriate. Expected behavior: qweb profiler should be visible with proper css. Task-3700415 --- I confirm I h
Original PR description
Before this commit the qweb profiler was broken. Steps to reproduce: - enable profiling and record qweb and it's directive for 5 minutes. - then go to Settings > Configure Document Layout > click on save. - then go to Settings > Techincal > Profiling and open profile - /web/dataset/call_kw/base.document.layout/onchange? Observed behavior: qweb profiler css is not appropriate. Expected behavior: qweb profiler should be visible with proper css. Task-3700415 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#161685
The aim of this commit is to fix runbot build error. Before the commit: The test could fail if the EUR currency was inactive After the commit: The test activate the currency first --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173764
Original PR description
The aim of this commit is to fix runbot build error. Before the commit: The test could fail if the EUR currency was inactive After the commit: The test activate the currency first --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173764
We use a "distant_display" if no display is connected to the IoT, in order to use the customer display on another computer. We don't need to send it to the database though, as it could confuse users. Task: 4061443 Forward-Port-Of: odoo/odoo#175191
Original PR description
We use a "distant_display" if no display is connected to the IoT, in order to use the customer display on another computer. We don't need to send it to the database though, as it could confuse users. Task: 4061443 Forward-Port-Of: odoo/odoo#175191
Commit [1] replaced the dialogs from legacy to OWL ones, but also created a deadlock by not resolving the promise set by the dialog. This commit fixes that by properly resolving the promise regardless of the user's answer. [1]: https://github.com/odoo/odoo/commit/00c9a7919768df71e79b5d34e21064729443c5fe Forward-Port-Of: odoo/odoo#175095
Original PR description
Commit [1] replaced the dialogs from legacy to OWL ones, but also created a deadlock by not resolving the promise set by the dialog. This commit fixes that by properly resolving the promise regardless of the user's answer. [1]: https://github.com/odoo/odoo/commit/00c9a7919768df71e79b5d34e21064729443c5fe Forward-Port-Of: odoo/odoo#175095
return emtpy translations list when the field is not translatable to be consistent with the api's definition 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#175224 Forward-Port-Of: odoo/odoo#175110
Original PR description
return emtpy translations list when the field is not translatable to be consistent with the api's definition 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#175224 Forward-Port-Of: odoo/odoo#175110
28 changes
Enhancements to existing features
Gantt popover footers now handle replacement customizations consistently with form dialog behavior. This makes it easier for businesses using tailored Gantt views, such as time off planning, to get predictable footer layouts and actions.
Original PR description
This commit adapts the code which allows to use the replace attribute in gantt popover footer custom archs to align with the behavior of the same functionality made in the form view dialog through https://github.com/odoo/odoo/pull/171537 task-4010906
Website Studio screens and page setup have been made easier to use, with more relevant forms and sensible default values. This helps users configure website pages more smoothly and supports more flexible Studio behavior behind the scenes.
Customers viewing shared project or field service tasks now see address information in a way that matches the internal view. Closed tasks also show the deadline, making shared task details more consistent and easier to understand.
Original PR description
This commit improve project sharing project task form view. - Show customer address in project sharing task from like it displayed in backend. - Display deadline field for close task in project sharing to be consistant. task-3764775
The Knowledge app search controls now look more like clear, tappable buttons on smaller screens. This improves readability and makes mobile use easier for users working with Knowledge articles.
Original PR description
This commit adapts the ControlPanel buttons' styling (Knowledge search) to look like actual buttons and improves their readability for smaller screens. task-3336242
Spreadsheet actions can now keep more of their page state synchronized with the browser URL. This helps browser back, forward, and reload actions behave more consistently when users work with spreadsheets.
Original PR description
Since [1] a new prop (a function called updateResId) was give to the controllers components of the window actions to update the resId on the action state and url, when needed. For instance, the form…
Since [1] a new prop (a function called updateResId) was give to the controllers components of the window actions to update the resId on the action state and url, when needed. For instance, the form view after saving a new record, will update the state and the url with the newly created id. Since [2], the prop was also given to the controllers components of the client actions to update the resId. There is a need to update more than the resId. This PR will introduce a new prop with the aim to update the action state (updateActionState). This props will allow the controller components to update the state and push the new state to the router (updating the url). In practical, this allows to push a new state in the url, keeping the action service in sync. This synchronization between the router and the action service allows the browser back/forward/reload to work as expected. [1]: https://github.com/odoo/odoo/commit/c63d14a0485a553b74a8457aee158384e9ae6d3f [2]: https://github.com/odoo/odoo/commit/3ad4fd65387f60b524e5f786556963ead8ae9dfe
Users can now share error details directly from the error dialog when Documents is installed. The system creates a support document, generates a share link, copies it automatically, and shows it next to the share button to speed up support requests.
Original PR description
This commit adds to the error_dialog the possibility to share the error by creating a new text document on the fly in the automatically generated support folder and then generating a share link for this document. A new share button is therefore added to the error_dialog's footer as soon as documents is installed and the generated share link is directly copied upon pressing the button as well as displayed next to the button afterwards. task-3883329
Barcode screens now use clearer wording for scrap actions and wrong-product scan messages, reducing confusion for warehouse staff. Batch transfer creation is also simplified by removing an unnecessary label option and showing more useful partner and batch information.
Original PR description
In this PR: --------------------------- - In the scrap view, the 'Confirm' button has been rephrased as the 'Scrap' button. - After grouping by warehouse, the '+ Warehouse' button, which appeared, has been removed. - Selection for creating batch transfers has been improved: - Removed the 'Assign Label' option. - Partner and batch information have been added. - The notification message for scanning the wrong product has been rephrased. task-id : 3801674
On mobile devices, navigation breadcrumbs are moved from the control panel into the top navigation bar. This frees up valuable screen space, reducing layout wrapping and making key controls easier to use on smaller screens.
Original PR description
*: spreadsheet_edition Ususally, the Breadcrumbs representing the different steps of the user's navigation is displayed in the ControlPanel. But, even while simplified for smaller screens, this layout takes a lot of screen realestate on smartphone-like screen sizes. To reclaim this space in the ControlPanel and avoid as much as possible the ControlPanel to wrap on multiple lines, this commit applies the required adaptation in enterprise. task-3336242
The manufacturing shop floor test flow was improved to make sure a wizard closes properly during automated checks. This helps reduce false test failures and keeps quality checks more dependable without changing day-to-day user behavior.
Original PR description
In this commit: ===================== - Improve test tour by ensuring that wizard is closed. task-3815521
Resolved issues and error corrections
This fixes the layout of call-to-action sections on Helpdesk website pages when more than one button is shown. The buttons now align properly, avoiding a broken or awkward appearance for visitors and helping keep support pages polished.
Original PR description
| Master | This PR | |--------|--------| | <img alt="image" src="https://github.com/user-attachments/assets/8f19044a-0c85-4973-938b-c7bdacfddf4c"> | <img alt="image" src="https://github.com/user-attachments/assets/90bceac9-428d-4f1f-81b1-252e86fd1524"> | | <img alt="image" src="https://github.com/user-attachments/assets/d86944db-03a8-4caa-b198-d21bebccba55"> | <img alt="image" src="https://github.com/user-attachments/assets/fc238783-d22c-44d0-adb4-36800001384d"> | Commit[1], which is part of the Odoo 18 snippets redesign aimed to align all the occurrences of the `s_call_to_action` snippet across the front-end. It appears that this commit did not take into account the fact that a second button can be xpath next to the first one. To ensure this scenario does not cause any issue, we restore the flex layout already existing before. Commit[1]: 53c0592f367572db5ceff49db2f4363b7306a102 task-4086686
This fix makes more labels, prompts, and messages across several Odoo apps available for translation. It improves usability for businesses operating in multiple languages by ensuring interface text can be localized consistently.
Original PR description
Community: https://github.com/odoo/odoo/pull/174914
The payroll test for Australian employee termination payments now uses a fixed date so the employee's age stays consistent. This prevents test results from changing over time due to age-based withholding rules, improving reliability without affecting business operations.
Original PR description
Termination test failed because the employee's age was over 60 now, which gets a lower withholding rate. This commit sets a freezetime so a fixed age is used.
The WhatsApp module now correctly includes a missing dependency needed for its routing-related functionality. This helps prevent installation or runtime issues caused by unavailable supporting functions.
Original PR description
The `http_routing` module is missing from whatsapp dependency, therefore it doesn't import the function `_slugify`
Code cleanup and technical improvements
The Knowledge app now uses the updated Unsplash connection introduced by a related platform refactor. This keeps cover image selection aligned with the latest editor support while preserving existing user behavior.
Original PR description
The PR odoo/odoo#172938 refactor the web_unsplash module to support both `web_editor` and `html_editor`. This commit changes the import accordingly.
Miscellaneous changes
By default, we send date_order to Avatax when asking to calculate taxes. Avatax calculates the right taxes for that point in time. For non-recurring orders this is ok, but subscriptions are paid multiple times and date_order will remain the confirmation date of the subscription. This leads to confusion as taxes change over time (e.g. tax laws change or an exemption certificate is added with an effective date after date_order). Because customers are charged based on invoices we always charge t
Original PR description
By default, we send date_order to Avatax when asking to calculate taxes. Avatax calculates the right taxes for that point in time. For non-recurring orders this is ok, but subscriptions are paid multiple times and date_order will remain the confirmation date of the subscription. This leads to confusion as taxes change over time (e.g. tax laws change or an exemption certificate is added with an effective date after date_order). Because customers are charged based on invoices we always charge them correctly, but the subscription total may not match what they're being charged. To solve this, always send the current date for subscriptions. This way customers can accurately see what they'll be charged in the portal. task-4078473 Forward-Port-Of: odoo/enterprise#67743
This commit implements the functionality to support exporting libros XLSX with some line using a tax of type Prorrata. Prorrata is a fiscal system here in Spain, in which companies who have activities where they can deduct IVA, and activities where they don´t have that right, the fiscal Agency gives you a formula you can use to simplify the process, and deduct the percentage you get from that formula from the IVA amount of an invoice. For example, on an invoice with tax 21% IVA, from that amo
Original PR description
This commit implements the functionality to support exporting libros XLSX with some line using a tax of type Prorrata. Prorrata is a fiscal system here in Spain, in which companies who have…
This commit implements the functionality to support exporting libros XLSX with some line using a tax of type Prorrata. Prorrata is a fiscal system here in Spain, in which companies who have activities where they can deduct IVA, and activities where they don´t have that right, the fiscal Agency gives you a formula you can use to simplify the process, and deduct the percentage you get from that formula from the IVA amount of an invoice. For example, on an invoice with tax 21% IVA, from that amount we can apply the prorrata percentage, and get a deductable and non deductable amount. The deductable amount should go to the normal IVA account, and the non deductable should go to the same account as the tax base. To simulate Prorrata tax in Odoo, we can create a new tax with only partial of the tax percentage is applied an account, tax grid, and checked in 'use in tax closing'. When we create invoice/bill with this tax, only those partial amount should be included in the tax_deductible field of the libros XLSX. Before this commit: tax_deductible amount include the full tax amount. After this commit: tax_deductible amount only include the tax amount if the line have a tax grid. task-id: 3955233 Forward-Port-Of: odoo/enterprise#67193
This commit fixes an issue with the garbage collecting of knowledge articles. Old articles weren't being unlinked after they due date was passed. This is caused by a missing context key `active_test` which enables us to search articles that could be archived. Since `to_delete` articles are considered as archived, the original search never found any article to remove. Now, the context is added enabling the autovacuum to do its job and remove old useless articles. task-4047720 Forward-P
Original PR description
This commit fixes an issue with the garbage collecting of knowledge articles. Old articles weren't being unlinked after they due date was passed. This is caused by a missing context key `active_test` which enables us to search articles that could be archived. Since `to_delete` articles are considered as archived, the original search never found any article to remove. Now, the context is added enabling the autovacuum to do its job and remove old useless articles. task-4047720 Forward-Port-Of: odoo/enterprise#67739 Forward-Port-Of: odoo/enterprise#66586
Termination test failed because the employee's age was over 60 now, which gets a lower withholding rate. This commit sets a freezetime so a fixed age is used. Forward-Port-Of: odoo/enterprise#67766
Original PR description
Termination test failed because the employee's age was over 60 now, which gets a lower withholding rate. This commit sets a freezetime so a fixed age is used. Forward-Port-Of: odoo/enterprise#67766
task-4045835 Forward-Port-Of: odoo/enterprise#66822
Original PR description
task-4045835 Forward-Port-Of: odoo/enterprise#66822
Steps to reproduce ================== - Install account_accountant,web_studio - Go to Accounting > Configuration > Account Groups - Open studio - Switch to the form view - Show invisible elements - Add a new field before the invisible Company field => Error: Xpath resolved to nothing or multiple nodes Cause of the issue ================== The xpath props of the StudioHook is the string "null" The fields of this view are defined inside an InnerGroup but there is no OuterGrou
Original PR description
Steps to reproduce ================== - Install account_accountant,web_studio - Go to Accounting > Configuration > Account Groups - Open studio - Switch to the form view - Show invisible elements -…
Steps to reproduce
==================
- Install account_accountant,web_studio
- Go to Accounting > Configuration > Account Groups
- Open studio
- Switch to the form view
- Show invisible elements
- Add a new field before the invisible Company field
=> Error: Xpath resolved to nothing or multiple nodes
Cause of the issue
==================
The xpath props of the StudioHook is the string "null"
The fields of this view are defined inside an InnerGroup but there is no OuterGroup.
```xml
<form><sheet>
<group>
<field .../>
...
</group>
</sheet></form>
```
In the form compiler, when a group does not contain another group, it is an InnerGroup
The form editor compiler uses some `interestingSelector` to compute xpaths.
It assumed that an InnerGroup was always inside an OuterGroup
Solution
========
Since the `:has` selector has not been widely supported for long enough,
we do the equivalent of `:not(field) group:not(:has(> group)) > *` in
javascript to match any group that has no direct group as a child.
opw-4046558
Forward-Port-Of: odoo/enterprise#67734
Forward-Port-Of: odoo/enterprise#67151## Issue: - For an inventory operation, if a product quantity is less than 1 (eg. 0.5), the "+" button in the Barcode app will display "+1" instead of "+ 0.5". ## Steps To Reproduce: - In Inventory, create a transfer (Receipts) with a product where the quantity is 0.5 and "Mark As Todo". - In the Barcode app, go to that operation and notice that the "Add Quantity" button shows "+1" instead of "+0.5". ## Solution: - I modified the `getIncrementQuantity` function to change the minimum qu
Original PR description
## Issue: - For an inventory operation, if a product quantity is less than 1 (eg. 0.5), the "+" button in the Barcode app will display "+1" instead of "+ 0.5". ## Steps To Reproduce: - In Inventory, create a transfer (Receipts) with a product where the quantity is 0.5 and "Mark As Todo". - In the Barcode app, go to that operation and notice that the "Add Quantity" button shows "+1" instead of "+0.5". ## Solution: - I modified the `getIncrementQuantity` function to change the minimum quantity from 1 to 0. This ensures that for product quantities less than 1, the "+" button in the Barcode app will display the correct increment. OPW-3880380 Forward-Port-Of: odoo/enterprise#65081 Forward-Port-Of: odoo/enterprise#62770
When a customer adds an empty internal note and tries to order the product, a traceback will appear. Steps to reproduce the error: - Open PoS restaurant session - Add any product > Order - Add same product again > Add an empty internal note - Order Traceback: ``` KeyError: (3, 'pou', '[]') File "odoo/http.py", line 2248, in __call__ response = request._serve_db() File "odoo/http.py", line 1823, in _serve_db return self._transactioning(_serve_ir_http, readonly=ro)
Original PR description
When a customer adds an empty internal note and tries to order the product, a traceback will appear. Steps to reproduce the error: - Open PoS restaurant session - Add any product > Order - Add same…
When a customer adds an empty internal note and tries to order the product,
a traceback will appear.
Steps to reproduce the error:
- Open PoS restaurant session
- Add any product > Order
- Add same product again > Add an empty internal note
- Order
Traceback:
```
KeyError: (3, 'pou', '[]')
File "odoo/http.py", line 2248, in __call__
response = request._serve_db()
File "odoo/http.py", line 1823, in _serve_db
return self._transactioning(_serve_ir_http, readonly=ro)
File "odoo/http.py", line 1843, 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 1821, in _serve_ir_http
return self._serve_ir_http(rule, args)
File "odoo/http.py", line 1828, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 2053, 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 756, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "addons/web/controllers/dataset.py", line 38, in call_kw
return self._call_kw(model, method, args, kwargs)
File "addons/web/controllers/dataset.py", line 34, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "odoo/api.py", line 458, in call_kw
result = getattr(recs, name)(*args, **kwargs)
File "home/odoo/src/enterprise/saas-17.2/pos_restaurant_preparation_display/models/preparation_display_order.py", line 33, in process_order
res = super().process_order(order_id, cancelled, note_history)
File "home/odoo/src/enterprise/saas-17.2/pos_preparation_display/models/preparation_display_order.py", line 28, in process_order
data = order._process_preparation_changes(cancelled, note_history)
File "home/odoo/src/enterprise/saas-17.2/pos_preparation_display/models/pos_order.py", line 95, in _process_preparation_changes
quantity_data[key_new]["display"] += old_quantity["display"]
```
https://github.com/odoo/enterprise/blob/4077a5e39fba7197d32d5db05171ad9c8f98c392/pos_preparation_display/models/pos_order.py#L95
Here when customer adds an empty internal note, ```quantity_data``` will become empty,
So, it will lead to the above traceback.
sentry-5494183916
Forward-Port-Of: odoo/enterprise#67717
Forward-Port-Of: odoo/enterprise#66145We notice that get_today_call_activities is a very frequent call that spend a lot of time runing sql queries. during 1h30 it was called 20515 times for an average of 719ms of sql times on odoo.com database. It was cause by _format_call_activities which can be called with many hundreds of activities before this commit for each activity _mail_get_partners and mail_partner_format were called once per activity. It take 581s for all the internal user of odoo.com database after this comm
Original PR description
We notice that get_today_call_activities is a very frequent call that spend a lot of time runing sql queries. during 1h30 it was called 20515 times for an average of 719ms of sql times on odoo.com database. It was cause by _format_call_activities which can be called with many hundreds of activities before this commit for each activity _mail_get_partners and mail_partner_format were called once per activity. It take 581s for all the internal user of odoo.com database after this commit the method _mail_get_partners and mail_partner_format are called for an entire batch as it's intended. The same computation for internal user takes now 84s Forward-Port-Of: odoo/enterprise#67539 Forward-Port-Of: odoo/enterprise#67289
When a sales order has it's tax calculated externally (e.g avatax), but a preceding_subtotal is present on a selected product tax group (case of internal tax computation). The frontend will raise an error when trying to display the tax_totals. Steps to reproduce: 1. Go to general setting > enable avatax > save. 2. Go to accounting > configuration > tax groups > set preceding subtotal column (hidden) of a chosen tax groups. 3. Go to sales > New 4. In the quotation form > select a product a
Original PR description
When a sales order has it's tax calculated externally (e.g avatax), but a preceding_subtotal is present on a selected product tax group (case of internal tax computation). The frontend will raise an…
When a sales order has it's tax calculated externally (e.g avatax), but a preceding_subtotal is present on a selected product tax group (case of internal tax computation). The frontend will raise an error when trying to display the tax_totals.
Steps to reproduce:
1. Go to general setting > enable avatax > save.
2. Go to accounting > configuration > tax groups > set preceding subtotal column (hidden) of a chosen tax groups.
3. Go to sales > New
4. In the quotation form > select a product and set its tax to the previously chosen tax groups.
5. In the Other Info tab of the form > set fiscal position as avatax.
6. Finish the quotation creation > save.
7. You can open it in the order lines tab and see the error being raised.
cause:
As the taxes are calculated externally (i.e avatax). sale_external_tax module "will create a single tax group" (cf _compute_tax_totals doc). But the subtotals_order is not overwritten. In the fronted side, the TaxTotalsComponent will try to display each subtotal values, with preceding_subtotal label as keys stored in subtotals_order, but only one tax groups is present with a default subtotal label ('Untaxed Amount'). Resulting to reads in groups_by_subtotal dict with None result thus raising "Uncaught Promise > Invalid loop expression: "undefined" is not iterable".
solution:
Overwrite subtotals_order with a single default value 'Untaxed Amount'
opw-4009957
Forward-Port-Of: odoo/enterprise#66821## Issue Shop Floor can show performance issues even with the default limit of 40. This is mostly due to the `operation_note` fetched for the work orders. Moreover, as it's a HTML field, it has to be sanitized by the ORM - which is slow considering users tend to put base64 encoded images in it. ## Analysis It is not necessary to fetch the `operation_note` for all displayed work orders as it's only shown when an user will click on the *Worksheet* button or a *Quality Check* button. ## S
Original PR description
## Issue Shop Floor can show performance issues even with the default limit of 40. This is mostly due to the `operation_note` fetched for the work orders. Moreover, as it's a HTML field, it has to be…
## Issue Shop Floor can show performance issues even with the default limit of 40. This is mostly due to the `operation_note` fetched for the work orders. Moreover, as it's a HTML field, it has to be sanitized by the ORM - which is slow considering users tend to put base64 encoded images in it. ## Analysis It is not necessary to fetch the `operation_note` for all displayed work orders as it's only shown when an user will click on the *Worksheet* button or a *Quality Check* button. ## Solution In case there is no PDF or Slide, the *Worksheet* button is only displayed when there's an `operation_note`. Therefore, we introduce a `has_operation_note` field to keep that behavior (refer to the Community commit). When a user clicks on a *Worksheet*/*Quality Check* button, we fetch the `operation_note` from the backend and cache it so we don't need to send another request later on. ## Benchmarks Benchmarks are done calling `web_search_read` on a database containing base64 images. | Displayed MO | Before | After | Speed up | |-------------|---------|--------| --------| | 40 | 8.19 s | 400 ms | ~95% | 100 | 23.9 s / MemoryError | 900 ms | ~96% ## References opw-3983324 -- I confirm I have signed the CLA and read the PR guidelines at [www.odoo.com/submit-pr](http://www.odoo.com/submit-pr) Forward-Port-Of: odoo/enterprise#67602 Forward-Port-Of: odoo/enterprise#66176
before commit: while going to edit the report(Shipping Labels and Shipping Documents) this traceback is raised.For preventing from the error adding in rename_black_list to prevent from editing and not showing in editor [these two reports ]( https://github.com/odoo/enterprise/blob/17.0/delivery_iot/report/delivery_carrier_reports.xml#L5-L6) ``` Traceback (most recent call last): File "/data/build/odoo/odoo/http.py", line 1770, in _serve_db return service_model.retrying(self._serve_ir
Original PR description
before commit: while going to edit the report(Shipping Labels and Shipping Documents) this traceback is raised.For preventing from the error adding in rename_black_list to prevent from editing and…
before commit:
while going to edit the report(Shipping Labels and Shipping Documents) this traceback is raised.For preventing from the error adding in rename_black_list to prevent from editing and not showing in editor [these two reports ]( https://github.com/odoo/enterprise/blob/17.0/delivery_iot/report/delivery_carrier_reports.xml#L5-L6)
```
Traceback (most recent call last):
File "/data/build/odoo/odoo/http.py", line 1770, in _serve_db
return service_model.retrying(self._serve_ir_http, self.env)
File "/data/build/odoo/odoo/service/model.py", line 133, in retrying
result = func()
File "/data/build/odoo/odoo/http.py", line 1797, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "/data/build/odoo/odoo/http.py", line 2001, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "/data/build/odoo/addons/website/models/ir_http.py", line 235, in _dispatch
response = super()._dispatch(endpoint)
File "/data/build/odoo/odoo/addons/base/models/ir_http.py", line 222, in _dispatch
result = endpoint(**request.params)
File "/data/build/odoo/odoo/http.py", line 725, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "/data/build/enterprise/web_studio/controllers/report.py", line 474, in load_report_editor
report_qweb = self._get_report_qweb(report)
File "/data/build/enterprise/web_studio/controllers/report.py", line 612, in _get_report_qweb
main_qweb.xpath("//*[@id='wrapwrap']")[0]
IndexError: list index out of range
```
Forward-Port-Of: odoo/enterprise#62515Before the **PR**: Salvage value of asset was not being computed correctly. After the **PR**: Salvage value is now being computed correctly. **task**-4075459 Forward-Port-Of: odoo/enterprise#67524
Original PR description
Before the **PR**: Salvage value of asset was not being computed correctly. After the **PR**: Salvage value is now being computed correctly. **task**-4075459 Forward-Port-Of: odoo/enterprise#67524
This PR adds a wizard in the POS to select a `l10n_pe_edi_refund_reason` when refunding an invoice/boleta (e.g. "Anulación de la operación", "Anulación de la operación"...). NB: according to PO feedback, it is not possible to refund several invoices/boletas at once (but it is possible to refund one invoice/boleta with multiple credit notes). task-3801234 https://github.com/odoo/odoo/pull/169597 Forward-Port-Of: odoo/enterprise#67568 Forward-Port-Of: odoo/enterprise#64761
Original PR description
This PR adds a wizard in the POS to select a `l10n_pe_edi_refund_reason` when refunding an invoice/boleta (e.g. "Anulación de la operación", "Anulación de la operación"...). NB: according to PO feedback, it is not possible to refund several invoices/boletas at once (but it is possible to refund one invoice/boleta with multiple credit notes). task-3801234 https://github.com/odoo/odoo/pull/169597 Forward-Port-Of: odoo/enterprise#67568 Forward-Port-Of: odoo/enterprise#64761
9 changes
Enhancements to existing features
This update improves the performance of how article names are displayed in the Knowledge module by optimizing the underlying data retrieval process. The change ensures that the system fetches all necessary information efficiently, reducing unnecessary database queries and improving overall application responsiveness.
Original PR description
This commit is a backport of a04d119. The _compute_display_name needed more fields inside its depends to make it efficient. This commit handles this issue and updates the associated query counters. task-4061715
Resolved issues and error corrections
Fixed an issue where the message prompting users to buy extra credits was displaying as raw HTML code instead of a properly formatted message with a clickable link. This improves the user experience by ensuring the message appears clean and professional in the system.
Original PR description
The message to buy extra credits is escaped and instead of displaying the message with a link it displays the message with a html and a url, not very human user like. We have to unescape the < and > symbols so that the frontend can properly display the message Ticket [link](https://www.odoo.com/web#model=project.task&id=3864033) opw-3864033 Forward-Port-Of: odoo/enterprise#63364
This fix corrects an issue where depreciation entries for assets created in a subsidiary company were incorrectly assigned to the parent company instead of the subsidiary. When users create an asset in a subsidiary company and view the posted depreciation entries, they will now correctly see entries assigned to the subsidiary company rather than the parent company.
Original PR description
When creating an asset from sub company when both sub company and parent company are selected, the asset's depreciation moves have the parent company instead of the child one. Steps: - Have a parent company P and a child company C - With companies set to P + C, and company set to C - Create an asset and compute board - Click on "Posted Entries" smart button -> Entries have P as company instead of C opw-4059496
This fix prevents the Kenya localization module upgrade from failing when certain tax configurations are missing. Previously, the automatic installation of the Kenya EDI module could break the entire upgrade process for customers who don't use this feature. Now the system gracefully handles missing taxes, allowing upgrades to complete successfully while users can optionally reload taxes later if needed.
Original PR description
At the moment, if any of the taxes for which l10n_ke_edi_oscu adds tax types doesn't exist, the upgrade to 17.0 fails, because l10n_ke_edi_oscu is set to auto_install. We don't want this upgrade to fail, especially given that this might affect customers who have no intention of using l10n_ke_edi_oscu. Solution: we simply don't set the tax type on those taxes which don't exist. If the user wants to use l10n_ke_edi_oscu properly, they should re-load the taxes via the Reload button in the Accounting settings.
This fix ensures that when starting a work order in manufacturing, the system properly validates whether the employee attempting to start the work is authorized to work on that specific work center. Previously, unauthorized employees could start work orders without triggering an error, which could lead to compliance and operational issues. Now the system correctly prevents unauthorized employees from starting work orders.
Original PR description
Steps to reproduce the bug:
- Log in as Mitchell Admin.
- Go to Work Centers > Assembly Line 1 > Select Mark Demo in the allowed employees.
- Create a storable product P1 with BoM:
- Components: Select any product.
- Operation: OP1 in Assembly Line 1.
- Create a manufacturing order to produce one unit of P1.
- Try to start the work order with Mitchell from the form view.
Problem:
No user error is triggered when it should be.
opw-4045726This fix ensures users must select at least one printer before printing reports through the IoT system. Previously, users could click Print without selecting a device, which would result in nothing being printed and the system remembering this preference, preventing future print attempts. Now, if no printer is selected, the system displays a notification and prevents the print action.
Original PR description
Currently, when printing reports using the iot, if we don't select a device when the wizard prompts ut to do so, nothing will be printed and it will be saved in the browser storage that no printer…
Currently, when printing reports using the iot, if we don't select a device when the wizard prompts ut to do so, nothing will be printed and it will be saved in the browser storage that no printer should print this report. Steps to reproduce: ------------------- * Connect the IOT to the db * In developper mode go to: **Settings** > **Technical** > **Actions** > **Reports** * Select `PDF Quote` for example and associate a printer * Go to the **Sale** App and select any quotation * Select the gear icon * Select **Print** > `PDF Quote` * Select `Print` without selecting a printer > Observation: Nothing is printed * Select **Print** > `PDF Quote` > Observation: Nothing is printed and the prompt does not appear Why the fix: ------------ The idea behind this fix is to make it mandatory to choose at least one of the devices on the wizard prompt. If at least one printer is selected we continue with the printing. If not, we put a notification on screen and don't do anything else. opw-4019575 Current behavior with the fix: -------------------------------------- 
This fix corrects an issue where archived price lists were being included in rental product pricing calculations, which could result in incorrect prices being displayed or used. By excluding archived price lists, the system now shows only active pricing information and ensures accurate rental price quotes.
Original PR description
The product_pricing_ids didn't exclude archived pricelist which could lead to wrong price. While also displaying unnecessary data. opw-4053690
This update fixes a test in the Field Service Sales module by ensuring the pricing list is properly activated before creating a sales order. This resolves a test failure and ensures the system correctly links pricing information to sales orders during testing.
Original PR description
Fixed `test_industry_fsm_at_install` by activating the pricelist before creating the sale order to ensure a proper link. task-4070526
This update fixes a bug where old articles marked for deletion were not being automatically removed from the system. The issue was caused by a missing setting that prevented the system from finding archived articles. With this fix, the automatic cleanup process now works correctly and removes old, unused articles as intended.
Original PR description
This commit fixes an issue with the garbage collecting of knowledge articles. Old articles weren't being unlinked after they due date was passed. This is caused by a missing context key `active_test` which enables us to search articles that could be archived. Since `to_delete` articles are considered as archived, the original search never found any article to remove. Now, the context is added enabling the autovacuum to do its job and remove old useless articles. task-4047720 Forward-Port-Of: odoo/enterprise#66586