Daily updates from Odoo
Tuesday, May 31, 2022
16 changes · master
Enhancements to existing features
The update changes how chatter areas are managed internally across several Odoo apps, removing an outdated registration method. This helps keep messaging behavior more consistent and easier to maintain without changing day-to-day user workflows.
Original PR description
*: documents, stock_barcode, web_studio. No container should be registered as messaging component. ChatterContainer is the last one registering itself as such. This PR solves this issue. community: https://github.com/odoo/odoo/pull/92541
This update adjusts internal payment-related test tools to stay compatible with recent changes in the shared Odoo codebase. It helps keep automated checks reliable for payment flows, including SEPA direct debit and subscription payments, without changing day-to-day user functionality.
Original PR description
COM PR: https://github.com/odoo/odoo/pull/90716
Belgian reporting checks were updated to align with revised tax names, helping keep report validation accurate. Studio also now recognizes the tax tag widget, making it easier to configure tax-related fields consistently.
Original PR description
This PR: - updates the tests for Belgian reports to fit the new tax names - adds the new `many2many_tags_tax` widget to Studio Community PR: https://github.com/odoo/odoo/pull/91667
Resolved issues and error corrections
This change corrects internal timing issues that could cause referral point totals or project-related checks to use outdated information. It helps keep employee referral rewards and project data processing accurate after background email cleanup changes.
Original PR description
# hr_referral: invalidate the cache after creating hr.referral.points Now that the <mail.mail> are removed in a CRON, one test in hr_referral failed. The reason is that the cache of `earned_points` need to be invalidated after creating <hr.referral.points>. Before, after the deletion of the <mail.mail>, the cache was removed and that's why it worked. # project_enterprise: flush before doing SQL query Now that the <mail.mail> are removed in a CRON, one test in project failed. The reason is that we do not flush the model before doing SQL queries on them. Before, after the deletion of the <mail.mail>, everything was flushed and that's why it worked. Task-2587345
Peruvian electronic invoices already include the invoice amount written in words for SUNAT. This fix prevents users from adding the same note a second time, avoiding SUNAT rejections caused by duplicated information.
Original PR description
Since https://github.com/odoo/enterprise/pull/17188, the invoice XML that we send to SUNAT is automatically generated with a `<Note>` that contains the invoice amount in words: `<cbc:Note languageLocaleID="1000">NUEVE MIL CUATROCIENTOS CUARENTA Y 00/100 GOLD</cbc:Note>` SUNAT returns an error if the user manually introduces a duplicate note by setting the `l10n_pe_edi_legend` field to `1000`. See https://github.com/odoo/enterprise/pull/23465 where this was discovered.
Miscellaneous changes
Translations from non-standard modules on the website are not properly loaded, thus no translation is done even though translated terms are valid (e.g. signing a document shared). Testing [2]. Step to reproduce the issue: 1) Install the sign module & Install French language (or any execpt English) 2) Disable the English language 3) Go to Sign and Share on document 4) Open the link You will see that the "Click to start" is not translated. Some other strings too. Solution: The app
Original PR description
Translations from non-standard modules on the website are not properly loaded, thus no translation is done even though translated terms are valid (e.g. signing a document shared). Testing [2]. Step…
Translations from non-standard modules on the website are not properly loaded, thus no translation is done even though translated terms are valid (e.g. signing a document shared). Testing [2]. Step to reproduce the issue: 1) Install the sign module & Install French language (or any execpt English) 2) Disable the English language 3) Go to Sign and Share on document 4) Open the link You will see that the "Click to start" is not translated. Some other strings too. Solution: The appeared since commit [1]. In there, we changed the argument key for additional modules while it was not changed on the backend resulting in the module translation not loaded. Furthermore, in the backend the additional modules were appended as if they were a list while it is a string. [1]: https://github.com/odoo/odoo/commit/8cc066173dfb61bd95b8e1f0716f71f4e251810a [2]: https://github.com/odoo/odoo/pull/91478 opw-2842699 Forward-Port-Of: odoo/enterprise#27864 Forward-Port-Of: odoo/enterprise#27646
The display of the journals audit report can be improved, because currently some text does not align right like it should (mainly monetary fields). This commit addresses this issue by: modifying the html classes accordingly to ensure the text aligns right. See https://github.com/odoo/odoo/pull/90610 for more details task id=2824121 Forward-Port-Of: odoo/enterprise#26983
Original PR description
The display of the journals audit report can be improved, because currently some text does not align right like it should (mainly monetary fields). This commit addresses this issue by: modifying the html classes accordingly to ensure the text aligns right. See https://github.com/odoo/odoo/pull/90610 for more details task id=2824121 Forward-Port-Of: odoo/enterprise#26983
When using a fiscal position along with the l10n module for the same country, the tax report of that foreign country is also available in the tax report menu. However, they are ordered by country_id and if the other tax report is before the UK tax report, _get_options() will say that the tax lines of the foreign country are the ones to send to the HMRC. This fix forces the use of the UK tax report as a reference for which lines to use. opw-2845739 Forward-Port-Of: odoo/enterprise#2759
Original PR description
When using a fiscal position along with the l10n module for the same country, the tax report of that foreign country is also available in the tax report menu. However, they are ordered by country_id and if the other tax report is before the UK tax report, _get_options() will say that the tax lines of the foreign country are the ones to send to the HMRC. This fix forces the use of the UK tax report as a reference for which lines to use. opw-2845739 Forward-Port-Of: odoo/enterprise#27591
Entries in the filters dropdown lists can overflow when the list is larger than the screen size allows. Especially the journal and user defined filters are prone to overflowing. This commit still allows the end user to select any entry by scrolling the list whenever this is the case. The css rules introduced in [commit 1] to fix a similar issue with the currency filter are simply generalized to all account reports filter dropdown lists. Note: A more general fix might still be warranted. So
Original PR description
Entries in the filters dropdown lists can overflow when the list is larger than the screen size allows. Especially the journal and user defined filters are prone to overflowing. This commit still…
Entries in the filters dropdown lists can overflow when the list is larger than the screen size allows. Especially the journal and user defined filters are prone to overflowing. This commit still allows the end user to select any entry by scrolling the list whenever this is the case. The css rules introduced in [commit 1] to fix a similar issue with the currency filter are simply generalized to all account reports filter dropdown lists. Note: A more general fix might still be warranted. Some minor problems still remain with this solution. For example, a hard-coded 100px is subtracted to avoid overlapping the control panel. However, when the list of filter dropdowns wraps, any scrollable dropdown in the first row will not properly align with the bottom of the viewport. Additionally, dropdowns are rendered slightly different on mobile. Though, at least all filter dropdowns will now be usable by the end user in all cases. [commit 1]: https://github.com/odoo/enterprise/commit/4927d8dd350ee1a74d89928115f354c13107729a opw-2792463 Forward-Port-Of: odoo/enterprise#27556 Forward-Port-Of: odoo/enterprise#26342
Some tests that are run before those located in `project_enterprise/tests/test_auto_shift_dates.py` seem to indeterministically cache information on groups `.` and `base.group_system`. This impacts the variability of the query counters in the tests, which prevents to set them properly. The purpose of this commit is to prevent this instability during the tests. This commit reaches that goal by: - Calling `has_group()` on both groups in the setUp of the tests so that it will be cached.
Original PR description
Some tests that are run before those located in `project_enterprise/tests/test_auto_shift_dates.py` seem to indeterministically cache information on groups `.` and `base.group_system`. This impacts the variability of the query counters in the tests, which prevents to set them properly. The purpose of this commit is to prevent this instability during the tests. This commit reaches that goal by: - Calling `has_group()` on both groups in the setUp of the tests so that it will be cached. - Using `@users` to ensure that we are taking ir.rules into account (as the default __system__) won't. Forward-Port-Of: odoo/enterprise#27233 Forward-Port-Of: odoo/enterprise#27026
…ross Forward-Port-Of: odoo/enterprise#27839
Original PR description
…ross Forward-Port-Of: odoo/enterprise#27839
In order to prevent the signature dialog from opening multiple times when clicking multiple times, a debounce method was added. At the time this was the best option we could find, but turns out the debounce was making the dialog take too long to be opened. This commit removes the debounce and uses a different approach to prevent multiple dialogs from opening. A variable is used to store if the dialog is opened and when the dialog is destroyed, we set it to false. This prevents the dialog f
Original PR description
In order to prevent the signature dialog from opening multiple times when clicking multiple times, a debounce method was added. At the time this was the best option we could find, but turns out the debounce was making the dialog take too long to be opened. This commit removes the debounce and uses a different approach to prevent multiple dialogs from opening. A variable is used to store if the dialog is opened and when the dialog is destroyed, we set it to false. This prevents the dialog from opening if there is already a dialog opened. Also, as fonts are now cached from 15.3, it was decided to also cache the fonts in sign requests without sign items. task-2819572 Forward-Port-Of: odoo/enterprise#26175
Steps to reproduce: - Create a user/employee - Give Timesheet rights: approver - Create a timesheet for the user/employee Issue: When connected with this user, he can self-approved its own timesheets Cause: It currently specifically designed that way: "Approver: in this access right, the user can't validate all timesheets, he can validate the timesheets where he is the manager or timesheet responsible of the employee who is assigned to this timesheets or the user is the owner of the
Original PR description
Steps to reproduce: - Create a user/employee - Give Timesheet rights: approver - Create a timesheet for the user/employee Issue: When connected with this user, he can self-approved its own timesheets Cause: It currently specifically designed that way: "Approver: in this access right, the user can't validate all timesheets, he can validate the timesheets where he is the manager or timesheet responsible of the employee who is assigned to this timesheets or the user is the owner of the project. Furthermore, the user can validate his own timesheets." Nonethless, according and to the team and the PO (aju) it has to be changed. => An approver can not self approved his/her own timesheets. Solution: Restrict the domain to take the lines where the employee_id is not the same as the one from the user validating. opw-2836385 Forward-Port-Of: odoo/enterprise#27772 Forward-Port-Of: odoo/enterprise#27438
In menu `Subscriptions > Reporting > Revenue KPIs > detailed analysis`, the credit note amounts are summed to the invoice amounts. Fix it by checking `move_type`. This will not change value for exising records, but least fix the sign for the new ones. opw-2836785 Forward-Port-Of: odoo/enterprise#27695 Forward-Port-Of: odoo/enterprise#27440
Original PR description
In menu `Subscriptions > Reporting > Revenue KPIs > detailed analysis`, the credit note amounts are summed to the invoice amounts. Fix it by checking `move_type`. This will not change value for exising records, but least fix the sign for the new ones. opw-2836785 Forward-Port-Of: odoo/enterprise#27695 Forward-Port-Of: odoo/enterprise#27440
Step to reproduce: -install accounting with german localization -activate multi-currency in settings -create an invoice with a currency different than EUR -Go to reporting>general ledger and download datev ZIP Current behavior: The currency in the file is EUR Expected behavior: The currency is the one of the invoice opw-2842120 Forward-Port-Of: odoo/enterprise#27109
Original PR description
Step to reproduce: -install accounting with german localization -activate multi-currency in settings -create an invoice with a currency different than EUR -Go to reporting>general ledger and download datev ZIP Current behavior: The currency in the file is EUR Expected behavior: The currency is the one of the invoice opw-2842120 Forward-Port-Of: odoo/enterprise#27109
This is a side-effect of commit [1]. If not TtlAmt element is provided, we should not automatically return sign * amount * rate but check also if journal currency is set and if the rate must be inverted, to keep the logic introduced with the commit [2]. We should also change the default return to amount instead of entry_amount, as it will cause issues in case of batch entry. [1]:https://github.com/odoo/enterprise/commit/29b00fad23a07504e14805c3ab4a9d997bf03386 [2]:https://github.com/odo
Original PR description
This is a side-effect of commit [1]. If not TtlAmt element is provided, we should not automatically return sign * amount * rate but check also if journal currency is set and if the rate must be inverted, to keep the logic introduced with the commit [2]. We should also change the default return to amount instead of entry_amount, as it will cause issues in case of batch entry. [1]:https://github.com/odoo/enterprise/commit/29b00fad23a07504e14805c3ab4a9d997bf03386 [2]:https://github.com/odoo/enterprise/commit/df63265fe2b310ca20b92097383228e78ee1da58 opw-2761903 opw-2834885 opw-2855805 opw-2853041 Forward-Port-Of: odoo/enterprise#27825 Forward-Port-Of: odoo/enterprise#27657