Wednesday, May 11, 2022
13 changes · master
New functionality added to Odoo
Payroll work entries can now be based on approved planning slots or actual attendance records instead of only fixed contract schedules. This helps businesses pay hourly workers and overtime more accurately while keeping contract changes reflected consistently in payroll.
Original PR description
Creates a link between the work entries and the planning and attendance apps. Currently work entries are generated by looking at the working schedule on the contract, however this does not allow for employers to pay their employees based on prestated hours. This modules extends the base work entries generation routine to allow for planning/attendances to represent work entries. The goal is also to keep the exact same behaviour as the regularly generated work entries for attendance. Meaning contract changes should affect work entries the same way when using either schedule types. Task ID: 2466871 See odoo/odoo#72552
Enhancements to existing features
This update removes unnecessary cleanup steps from automated tests in several Odoo apps. It reduces maintenance noise and prepares the platform for upcoming changes to the Discuss app testing environment, with no expected impact on everyday users.
Original PR description
*: account_invoice_extract, documents, voip. Since community#86338, widget destruction is registered in the start method. Thus, explicit calls to widget.destroy during tests are useless. This PR prepares the ground for the one introducing the new environment in the discuss app. Indeed, the former PR will use createWebClient instead of createView/Widget constructor thus, we won't be able to call destroy on the returned value anymore. In order to reduce the noise in the main PR, all the calls to widget.destroy have been removed. task-2582313 community: https://github.com/odoo/odoo/pull/91082
Resolved issues and error corrections
Worksheet template creation has been optimized to run faster and use fewer database queries. This reduces waiting time when creating templates, especially in environments using quality control worksheets or field service reports.
Original PR description
With quality_control_worksheet/industry_fsm_report installed, from - 329 entries - 162 queries - 2.85 seconds to - 219 entries - 121 queries - 1.62 seconds Note: This could be even reduced to 190 entries and 1.07 seconds on the second worksheet creation as the field_trigger method which is a lazy property is not re-evaluated. TaskID: 2846762
Miscellaneous changes
Step to reproduce: Install accounting with mexican localization Change the tax "IVA(O%) VENTAS" factor type to Exento Change the tax "RET ISR HONORARIOS 10%" tax type to sales and factor type to tasa Create an invoice with these two taxes used at the same time Current behavior: We have an error traslados missing child element traslado Expected behavior: No error when processing cfdi Solution: We need to check outside the translados element that there was at least one tax
Original PR description
Step to reproduce: Install accounting with mexican localization Change the tax "IVA(O%) VENTAS" factor type to Exento Change the tax "RET ISR HONORARIOS 10%" tax type to sales and factor type to tasa Create an invoice with these two taxes used at the same time Current behavior: We have an error traslados missing child element traslado Expected behavior: No error when processing cfdi Solution: We need to check outside the translados element that there was at least one tax without exento to avoid creating an empty translados opw-2796109 Forward-Port-Of: odoo/enterprise#26459
Accounting entries now include a standard way to identify the purpose of each line, such as payment, rounding, or display-only lines. This makes financial processing and reporting easier to filter, maintain, and extend across accounting-related features.
Original PR description
There is a few use case where we need to filter aml based on some specificities, such as liquidity/counterpart lines on payment, cash rounding lines, display lines,... This change aim to standardize this by adding a line_type field that would allow to specify the line purpose, making it easy to filter where needed but also to extend if needed. Task id #2747764
…ton_draft The problem is that you can not reset to draft when the transaction_id is still there, which is logical as we are still processing the transaction with Carvajal. However, when we get an error from Carvajal, we do not clean the transaction_id, while it should happen then and not (only) when we reset to draft as at that time, we can not do anything with it anymore anyways as it is rejected. And this way, we can also reset to draft at that point. opw-2838326 Forward-Por
Original PR description
…ton_draft The problem is that you can not reset to draft when the transaction_id is still there, which is logical as we are still processing the transaction with Carvajal. However, when we get an error from Carvajal, we do not clean the transaction_id, while it should happen then and not (only) when we reset to draft as at that time, we can not do anything with it anymore anyways as it is rejected. And this way, we can also reset to draft at that point. opw-2838326 Forward-Port-Of: odoo/enterprise#27087
…istration *: voip, web_studio. Adds an import to wait for the required components to be added to the messaging components registry before their parent use getMessagingComponent. Otherwise, any slight delay could lead to missing components. community: https://github.com/odoo/odoo/pull/90646 Forward-Port-Of: odoo/enterprise#27080 Forward-Port-Of: odoo/enterprise#27024
Original PR description
…istration *: voip, web_studio. Adds an import to wait for the required components to be added to the messaging components registry before their parent use getMessagingComponent. Otherwise, any slight delay could lead to missing components. community: https://github.com/odoo/odoo/pull/90646 Forward-Port-Of: odoo/enterprise#27080 Forward-Port-Of: odoo/enterprise#27024
Problem: Lines with groupby and children duplicate lines when unfold Solution: Removed groupby on parents Task-id: 2831954 Signed-off-by: Ruben Gomes <rugo@odoo.com> Forward-Port-Of: odoo/enterprise#27161 Forward-Port-Of: odoo/enterprise#26565
Original PR description
Problem: Lines with groupby and children duplicate lines when unfold Solution: Removed groupby on parents Task-id: 2831954 Signed-off-by: Ruben Gomes <rugo@odoo.com> Forward-Port-Of: odoo/enterprise#27161 Forward-Port-Of: odoo/enterprise#26565
Forward-Port-Of: odoo/enterprise#27137 Forward-Port-Of: odoo/enterprise#27038
Original PR description
Forward-Port-Of: odoo/enterprise#27137 Forward-Port-Of: odoo/enterprise#27038
…+ refunds Forward-Port-Of: odoo/enterprise#26903 Forward-Port-Of: odoo/enterprise#26860
Original PR description
…+ refunds Forward-Port-Of: odoo/enterprise#26903 Forward-Port-Of: odoo/enterprise#26860
In l10n_mx_report, when printing the xlsx for the DIOT report for a date range, it will take the lines for the period and all the following lines after the end of the range. This happens because there is no date_to in the context when reaching _query_get() in account_move.py This fix adds the ctx so that it can be used later, especially in the DIOT xlsx. This appeared in v14 and is present in v15 and saas-15.3 opw-2733346 opw-2709349 opw-2735298 Forward-Port-Of: odoo/enterprise#26631
Original PR description
In l10n_mx_report, when printing the xlsx for the DIOT report for a date range, it will take the lines for the period and all the following lines after the end of the range. This happens because there is no date_to in the context when reaching _query_get() in account_move.py This fix adds the ctx so that it can be used later, especially in the DIOT xlsx. This appeared in v14 and is present in v15 and saas-15.3 opw-2733346 opw-2709349 opw-2735298 Forward-Port-Of: odoo/enterprise#26631
A change introduced in https://github.com/odoo/odoo/pull/84644 removed the 'token' variable from a call to the `portal.message_thread` template, which created a bug where a portal user trying to leave a comment on a ticket would encounter an "Access Denied" error. This PR reverts that change. Related: https://github.com/odoo/odoo/pull/89629 Forward-Port-Of: odoo/enterprise#27142
Original PR description
A change introduced in https://github.com/odoo/odoo/pull/84644 removed the 'token' variable from a call to the `portal.message_thread` template, which created a bug where a portal user trying to leave a comment on a ticket would encounter an "Access Denied" error. This PR reverts that change. Related: https://github.com/odoo/odoo/pull/89629 Forward-Port-Of: odoo/enterprise#27142
Before this journal entries with an Avatax fiscal position (e.g. payments) ended up being sent to Avatax. This shouldn't happen because Avatax only processes invoices and the amount being sent is already registered via the invoice. task-2824272 Forward-Port-Of: odoo/enterprise#27125
Original PR description
Before this journal entries with an Avatax fiscal position (e.g. payments) ended up being sent to Avatax. This shouldn't happen because Avatax only processes invoices and the amount being sent is already registered via the invoice. task-2824272 Forward-Port-Of: odoo/enterprise#27125