Daily updates from Odoo
Wednesday, June 12, 2024
21 changes · master
Enhancements to existing features
Spreadsheet pivot side panels now reflect updates without waiting for deferred processing. This improves responsiveness and keeps displayed pivot information aligned with user actions.
Original PR description
This commit adapts the tests of the side panels because the update is now not defered. Task: 3953753
This update improves how Odoo filters records in several enterprise apps, allowing the system to stop searching once it has found enough matching items. This can make everyday actions feel faster and reduce unnecessary processing, with no expected change to user workflows.
Original PR description
https://github.com/odoo/odoo/pull/168300
Resolved issues and error corrections
The shop floor screen now shows the 'no content' message only in the relevant disabled work order area instead of covering the whole display. This keeps the employee panel visible and avoids clutter on smaller screens.
Original PR description
Before this commit, the 'no content' message was showing in the entire display, taking the employee panel account. Now, it is fixed, the message just stay at the disabled workorders, and when the screen is less than md, the message is hidded. rebased branch: https://github.com/odoo/enterprise/pull/64435 task: 3794286
Miscellaneous changes
[ADD] l10n_us_account: Auto load the localization pack and related reports automatically Problem: Users, especially newer ones, don't have the experience; or don't know how to install modules manually to their database. This will create the incorrect idea that Odoo doesn't fulfill the minimum requirements to operate in the US. - Examples of those uninstalled requirements are ABA routing for payments, correct layout for checks, 1099 reports, and Avatax for tax calculation. Desired behav
Original PR description
[ADD] l10n_us_account: Auto load the localization pack and related reports automatically Problem: Users, especially newer ones, don't have the experience; or don't know how to install modules…
[ADD] l10n_us_account: Auto load the localization pack and related reports automatically Problem: Users, especially newer ones, don't have the experience; or don't know how to install modules manually to their database. This will create the incorrect idea that Odoo doesn't fulfill the minimum requirements to operate in the US. - Examples of those uninstalled requirements are ABA routing for payments, correct layout for checks, 1099 reports, and Avatax for tax calculation. Desired behavior:- Auto load the following when creating odoo US database - US Accounting: l10n_us_account - United States Localization: l10n_us - US Accounting Reports: l10n_us_reports - 1099 Reporting: l10n_us_1099 - US Checks Layout: l10n_us_check_printing - NACHA Payments: l10n_us_payment_nacha - Avatax: account_avatax Solution: Create new module l10n_us_account to separate the accounting dependent stuff and auto load it and l10n_us which is going to load the mentioned packages above for US-db. Task-3865230 Community PR: https://github.com/odoo/odoo/pull/161709 Forward-Port-Of: odoo/enterprise#60644
When trying to reconcile to debit or credit lines with different currencies, we get a singleton error on `wizard.reco_currency_id` in `_compute_is_write_off_required` opw-3833477 Forward-Port-Of: odoo/enterprise#64418 Forward-Port-Of: odoo/enterprise#64011
Original PR description
When trying to reconcile to debit or credit lines with different currencies, we get a singleton error on `wizard.reco_currency_id` in `_compute_is_write_off_required` opw-3833477 Forward-Port-Of: odoo/enterprise#64418 Forward-Port-Of: odoo/enterprise#64011
- move link to Last Statemement to Invoicing Enterprise - move link to Unreconciled Payments to Invoicing - remove Import File links - standardize the "x to reconcile" secondary button - remove new transaction links and buttons - adapt tours to use the new secondary reconcile button - ensure there is always an unconfigured bank journal button for the account_accountant_tour - reposition miscellaneous journal onboarding - change the soda upload link to a secondary button - small modifica
Original PR description
- move link to Last Statemement to Invoicing Enterprise - move link to Unreconciled Payments to Invoicing - remove Import File links - standardize the "x to reconcile" secondary button - remove new transaction links and buttons - adapt tours to use the new secondary reconcile button - ensure there is always an unconfigured bank journal button for the account_accountant_tour - reposition miscellaneous journal onboarding - change the soda upload link to a secondary button - small modification to the tax return link text - add an upload button to the bank recon kanban & list view (statement import module) - enable drag and drop on the bank recon kanban & list view (statement import module) - add an upload button, and some text to the bank recon's no content helper (statement import module) part of task-3636384 Forward-Port-Of: odoo/enterprise#63933
With [1], the time range menu dropdown has been replaced by two date pickers allowing to select any time range. Here we reintroduce that time range menu but it will now also contain the two date pickers. In that way, standard time ranges like "Today", "This week",... can easily be selected but we keep the same possibilities as before. A new arch attribute "default_range" with possible values "day", "week", "month", "quarter", "year" has been introduced. Set it will make the gantt view pres
Original PR description
With [1], the time range menu dropdown has been replaced by two date pickers allowing to select any time range. Here we reintroduce that time range menu but it will now also contain the two date…
With [1], the time range menu dropdown has been replaced by two date pickers allowing to select any time range. Here we reintroduce that time range menu but it will now also contain the two date pickers. In that way, standard time ranges like "Today", "This week",... can easily be selected but we keep the same possibilities as before. A new arch attribute "default_range" with possible values "day", "week", "month", "quarter", "year" has been introduced. Set it will make the gantt view present initially a period of the selected type centered on the chosen initial date (default now). We have also improved a bit the set of buttons and added some hotkeys. The order buttons appear to have litle value so they have been removed. We have make the planning gantt view use the default_range "week" and its button "Copy previous week" be only available when the range and the scale are set to "week". Task Id: `3950898` [1]: https://github.com/odoo/enterprise/pull/55618 Co-authored-by: Bruno Boi <boi@odoo.com> Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com> Forward-Port-Of: odoo/enterprise#63523
Purpose ======= Do not crash when grouping by a property, instead we want to disable the group by like it has been done for the gantt view. Clean a test about the group by in the gantt view. Task-3876726 Forward-Port-Of: odoo/enterprise#64408 Forward-Port-Of: odoo/enterprise#62551
Original PR description
Purpose ======= Do not crash when grouping by a property, instead we want to disable the group by like it has been done for the gantt view. Clean a test about the group by in the gantt view. Task-3876726 Forward-Port-Of: odoo/enterprise#64408 Forward-Port-Of: odoo/enterprise#62551
This commit adds the missing neutralization necessary for the l10n_co_dian 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 usef
Original PR description
This commit adds the missing neutralization necessary for the l10n_co_dian 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/57925 Forward-Port-Of: odoo/enterprise#63734
In `pos_restaurant`, the user will see the upcoming appointment for each table underneath it. The text should be styled differently based on the situation. Late arrivals should be shown in red; future appointments should be shown with decreased opacity. During the refactoring in bb06fde, a bug was introduced that made the time computation invalid. This commit addresses the issue. Task: 3978801 Forward-Port-Of: odoo/enterprise#64218
Original PR description
In `pos_restaurant`, the user will see the upcoming appointment for each table underneath it. The text should be styled differently based on the situation. Late arrivals should be shown in red; future appointments should be shown with decreased opacity. During the refactoring in bb06fde, a bug was introduced that made the time computation invalid. This commit addresses the issue. Task: 3978801 Forward-Port-Of: odoo/enterprise#64218
Current behavior: When an iot device is linked to the PoS and invoice report, you had an error because action service and iot_websocket service where not available. Steps to reproduce: - Install pos_iot - Set an iot_device printer on the pos session - Set an iot_device on the report of the invoice - Open session, make an order and invoice it - You get an error opw-3792576 Forward-Port-Of: odoo/enterprise#63280 Forward-Port-Of: odoo/enterprise#61697
Original PR description
Current behavior: When an iot device is linked to the PoS and invoice report, you had an error because action service and iot_websocket service where not available. Steps to reproduce: - Install pos_iot - Set an iot_device printer on the pos session - Set an iot_device on the report of the invoice - Open session, make an order and invoice it - You get an error opw-3792576 Forward-Port-Of: odoo/enterprise#63280 Forward-Port-Of: odoo/enterprise#61697
Commit 36b238b934f1b7e4ddf1dfd6089d36ea0b8ac7eb introduced a new transparent way to save payment methods on a subscription. This new checkbox causes various bugs in the payment flow when paying an invoice linked to a subscription: - Stripe inline form was not updated when the save my payment method was checked; - Adyen implementation skips the override of `_initiatePaymentFlow` in `sale_subscription` to update the transaction route; - The token inline form is only shown for Demo and Raz
Original PR description
Commit 36b238b934f1b7e4ddf1dfd6089d36ea0b8ac7eb introduced a new transparent way to save payment methods on a subscription. This new checkbox causes various bugs in the payment flow when paying an invoice linked to a subscription: - Stripe inline form was not updated when the save my payment method was checked; - Adyen implementation skips the override of `_initiatePaymentFlow` in `sale_subscription` to update the transaction route; - The token inline form is only shown for Demo and Razorpay; - The checkbox of the automated payment sought may be that of another payment method. This commit addresses all the previously mentioned issues. opw-3893592 opw-3946899 Forward-Port-Of: odoo/enterprise#63788
When a new contract is created (or if we change the vehicle_id on an existing one, it'll take the default value on the contract, or the previous contract value as default values for the cost Forward-Port-Of: odoo/enterprise#64026
Original PR description
When a new contract is created (or if we change the vehicle_id on an existing one, it'll take the default value on the contract, or the previous contract value as default values for the cost Forward-Port-Of: odoo/enterprise#64026
Problem --------- When doing the Send & Print on one invoice, or when multiple invoices are selected and the "Download" option is ticked, the PDF generation of the invoices is made synchronously. Generating a simple invoice takes ~2 seconds. When you're doing the mass Send&Print for 10+ invoices, you can have your screen loading for >20seconds just to get 10+pages of PDF. Objective --------- Start digging into that part to see if optimisation can be done to reduce that loading time for
Original PR description
Problem --------- When doing the Send & Print on one invoice, or when multiple invoices are selected and the "Download" option is ticked, the PDF generation of the invoices is made synchronously.…
Problem --------- When doing the Send & Print on one invoice, or when multiple invoices are selected and the "Download" option is ticked, the PDF generation of the invoices is made synchronously. Generating a simple invoice takes ~2 seconds. When you're doing the mass Send&Print for 10+ invoices, you can have your screen loading for >20seconds just to get 10+pages of PDF. Objective --------- Start digging into that part to see if optimisation can be done to reduce that loading time for UX improvements. Solution --------- Rather than calling wkhtmltopdf once per invoice, we allow the creation of all invoices' PDF together through one single call to the library. The PDF containing all the invoices will then be split and return as a dictionary. To do so we decoupled the `_render_qweb_pdf` function: - `_render_qweb_pdf` returns a aggregate of all the PDF - `_pre_render_qweb_pdf` returns the dictionary of all PDF split Furthermore, this commit batches some of the ORM calls; namely, attachments creation and cache invalidations. Results --------- | # Input data | Before PR | After PR | |:-------------:|:----------:|:---------:| | 1 | 3.3 s | 3.3 s | | 5 | 13.9 s | 4.4 s | | 10 | 27.5 s | 5.4 s | | 20 | 55.16 s | 8.4 s | odoo-167729 task-3695628 Forward-Port-Of: odoo/enterprise#63706
plan_id coming from '/shop/cart/update' is always a string so plan is never found using browse fix is to cast the plan_id before browsing opw-3921644 Forward-Port-Of: odoo/enterprise#64021
Original PR description
plan_id coming from '/shop/cart/update' is always a string so plan is never found using browse fix is to cast the plan_id before browsing opw-3921644 Forward-Port-Of: odoo/enterprise#64021
Fix display and functionality of tax type filter - Corrected the display of dropdown items to show tax type names instead of object references. - Updated the `onSelected` event handler to ensure the tax filter is correctly applied when a dropdown item is selected. opw-3976746 Forward-Port-Of: odoo/enterprise#64252
Original PR description
Fix display and functionality of tax type filter - Corrected the display of dropdown items to show tax type names instead of object references. - Updated the `onSelected` event handler to ensure the tax filter is correctly applied when a dropdown item is selected. opw-3976746 Forward-Port-Of: odoo/enterprise#64252
Currently, an error is generated when run 'Mail: Fetchmail Service' scheduled action. Step to produce: - Install the 'l10n_cl_edi' module. - And manually trigger the 'Mail: Fetchmail Service' scheduled action. Stacktrace ``` TypeError: FetchmailServer.fetch_mail() got an unexpected keyword argument 'raise_exception' File "odoo/tools/safe_eval.py", line 383, in safe_eval return unsafe_eval(c, globals_dict, locals_dict) File "ir.actions.server(128,)", line 1, in <module>
Original PR description
Currently, an error is generated when run 'Mail: Fetchmail Service' scheduled action. Step to produce: - Install the 'l10n_cl_edi' module. - And manually trigger the 'Mail: Fetchmail Service'…
Currently, an error is generated when run 'Mail: Fetchmail Service' scheduled action.
Step to produce:
- Install the 'l10n_cl_edi' module.
- And manually trigger the 'Mail: Fetchmail Service' scheduled action.
Stacktrace
```
TypeError: FetchmailServer.fetch_mail() got an unexpected keyword argument 'raise_exception'
File "odoo/tools/safe_eval.py", line 383, in safe_eval
return unsafe_eval(c, globals_dict, locals_dict)
File "ir.actions.server(128,)", line 1, in <module>
File "addons/mail/models/fetchmail.py", line 186, in _fetch_mails
return self.search([('state', '=', 'done'), ('server_type', '!=', 'local')]).fetch_mail(raise_exception=False)
ValueError: <class 'TypeError'>: "FetchmailServer.fetch_mail() got an unexpected keyword argument 'raise_exception'" while evaluating
'model._fetch_mails()'
File "odoo/addons/base/models/ir_cron.py", line 388, in _callback
self.env['ir.actions.server'].browse(server_action_id).run()
File "home/odoo/src/custom/trial/saas_trial/models/sentry.py", line 33, in run
res = super().run()
File "odoo/addons/base/models/ir_actions.py", line 972, in run
res = runner(run_self, eval_context=eval_context)
File "odoo/addons/base/models/ir_actions.py", line 802, in _run_action_code_multi
safe_eval(self.code.strip(), eval_context, mode="exec", nocopy=True, filename=str(self)) # nocopy allows to return 'action'
File "odoo/tools/safe_eval.py", line 397, in safe_eval
raise ValueError('%s: "%s" while evaluating\n%r' % (ustr(type(e)), ustr(e), expr))
```
The issue arises during the execution of the 'Mail: Fetchmail Service' scheduled action because the 'fetch_mail()' method call without argument, as we can see at [1], And this argument is added from this PR https://github.com/odoo/odoo/pull/152637.
link [1]: https://github.com/odoo/enterprise/blob/ba99dd4c236353c43376210a9aabcb0af5bd0299/l10n_cl_edi/models/fetchmail_server.py#L51
To resolve the issue, Add a default keyword argument at [2] to prevent an issue.
link [2]: https://github.com/odoo/enterprise/blob/ba99dd4c236353c43376210a9aabcb0af5bd0299/l10n_cl_edi/models/fetchmail_server.py#L51
sentry-5284073241
Forward-Port-Of: odoo/enterprise#64326
Forward-Port-Of: odoo/enterprise#61836Since the recent chart options refactoring, the title of the chart is not longer a string but an object with different style-related keys and the title string is set in the key `text`. The getter `getOdooChartDIsplayName` was not adapted to this change. This commit adapts the tests in Enterprise. task-3978637 Forward-Port-Of: odoo/enterprise#64196
Original PR description
Since the recent chart options refactoring, the title of the chart is not longer a string but an object with different style-related keys and the title string is set in the key `text`. The getter `getOdooChartDIsplayName` was not adapted to this change. This commit adapts the tests in Enterprise. task-3978637 Forward-Port-Of: odoo/enterprise#64196
By default, tables automatically adjust their width to accommodate the content of their cells, That causes table row to grow in size and make "X" button invisible. Here I'm constraining table layout so it doesn't matter how long the content of columns is [Reproduce] - Install documents - Add tag with a very long name - Go to all Documents, Select a document, Add the tag on a doc - BUG: "X" button is not visible* opw-3937326 BEFORE / AFTER https://github.com/odoo/enterprise/assets
Original PR description
By default, tables automatically adjust their width to accommodate the content of their cells, That causes table row to grow in size and make "X" button invisible. Here I'm constraining table layout so it doesn't matter how long the content of columns is [Reproduce] - Install documents - Add tag with a very long name - Go to all Documents, Select a document, Add the tag on a doc - BUG: "X" button is not visible* opw-3937326 BEFORE / AFTER https://github.com/odoo/enterprise/assets/33809926/5f2fc861-cd68-4478-8b8b-b8843b7d4944 Forward-Port-Of: odoo/enterprise#63279
Steps to reproduce: - Install Planning - Click on Schedule -> By Resource - Select multiple slots without a resource - Select a resource to add Issues: A traceback is shown because this line in the write function wasn't coded to work with recordset. https://github.com/odoo/enterprise/blob/70f0ce78ac5f976f93abd0b9ee239a998d6d7445/planning/models/planning.py#L803-L806 opw-3948517 Forward-Port-Of: odoo/enterprise#64217 Forward-Port-Of: odoo/enterprise#63450
Original PR description
Steps to reproduce: - Install Planning - Click on Schedule -> By Resource - Select multiple slots without a resource - Select a resource to add Issues: A traceback is shown because this line in the write function wasn't coded to work with recordset. https://github.com/odoo/enterprise/blob/70f0ce78ac5f976f93abd0b9ee239a998d6d7445/planning/models/planning.py#L803-L806 opw-3948517 Forward-Port-Of: odoo/enterprise#64217 Forward-Port-Of: odoo/enterprise#63450
Steps to reproduce ================== - Enable debug mode - Go to accounting app - reporting - balance sheet - three wheels on top right - click on the icon to show new columns -> Invalid portal target Cause of the issue ================== The uniqueRendererClass is used to target a portal for the dropdown, but that class isn't applied in the AccountReportListRenderer. https://github.com/odoo/odoo/pull/160566 opw-3974195 Forward-Port-Of: odoo/enterprise#64316
Original PR description
Steps to reproduce ================== - Enable debug mode - Go to accounting app - reporting - balance sheet - three wheels on top right - click on the icon to show new columns -> Invalid portal target Cause of the issue ================== The uniqueRendererClass is used to target a portal for the dropdown, but that class isn't applied in the AccountReportListRenderer. https://github.com/odoo/odoo/pull/160566 opw-3974195 Forward-Port-Of: odoo/enterprise#64316