Thursday, October 24, 2024
30 changes · 17.0
Enhancements to existing features
The account portal invoice table now includes explicit column header names. This makes the invoice page easier to maintain and customize safely, reducing the risk of future changes breaking related extensions.
Original PR description
In line with the approach outlined in [1], where element accessibility was improved by providing explicit names for easier selection and inheritance, this commit applies the same logic to the account portal invoices. By adding column header names, we ensure that these elements can be safely referenced without relying on positional selectors, thus avoiding potential issues when the element structure changes. [1] https://github.com/odoo/enterprise/pull/63957 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Resolved issues and error corrections
This update adds missing sample company data needed for point of sale testing. It prevents test failures in the Peruvian electronic invoicing setup, helping keep automated quality checks reliable.
Original PR description
How to reproduce: 1. install l10n_pe_edi_pos 2. run `test_pos_js` The following traceback is obtained: ``` QUnit test failed: point_of_sale > Chrome > mount the Chrome : message: "Promise rejected during "mount the Chrome": Cannot make the given value reactive" ``` It is actually raised because in l10n_pe_edi_pos, we try to access `company.account_fiscal_country_id.code` and the fiscal_country is undefined (`Cannot read properties of undefined (reading 'code')`). Adding demo data fixes the error. runbot-71686
Miscellaneous changes
This reverts commit bcaf8cb859dc2f7e975d180ba0fc49da20204557 as we were forcing values and it did not reflect the settings of fiscal positions. opw-4270399 Forward-Port-Of: odoo/odoo#185101
Original PR description
This reverts commit bcaf8cb859dc2f7e975d180ba0fc49da20204557 as we were forcing values and it did not reflect the settings of fiscal positions. opw-4270399 Forward-Port-Of: odoo/odoo#185101
This fix ensures Chilean accounting documents use the company linked to the transaction when retrieving tax groups, even if the user is currently working in another company. It helps avoid incorrect tax handling in multi-company setups and supports more reliable local compliance.
Original PR description
This is a complement of previous fix: https://github.com/odoo/odoo/commit/792773296fce27340bf866fef8a6f6e8969b682e Add the company of the move in the context as it is possible that the company of the move and the current company are different. opw-4227241 Related enterprise PR: https://github.com/odoo/enterprise/pull/71725 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Tasks will now only be visually marked as overdue when their deadline is actually earlier than the current date. This prevents newly created or future-dated tasks from appearing incorrectly flagged, reducing confusion for project users.
Original PR description
Steps to reproduce: - install project module. - open form view of any task - create new task and set value of deadline - deadline is getting text-decoration even if deadline is not passed. Sol: - Condition ensures date_deadline is not None and strictly less than current_date - This change improves the robustness of the condition by handling undefined date_deadline values. task: 3970136
The maintenance settings screen now makes it clearer that the worksheet option depends on an Enterprise feature. This helps avoid customer confusion when configuring maintenance workflows.
Original PR description
* Module maintenance worksheet is from enterprise, we should add widget upgrade_boolean for it to avoid misunderstanding from customer 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
This fixes an automated maintenance calendar test that could fail depending on the day of the week it ran. The calendar recurrence and drag-and-drop checks were adjusted to make test results consistent, helping prevent false failures in validation pipelines.
Original PR description
### Issue: `test_dblclick_event_from_calendar` tour test fails on Saturday ### Explanation: In the tour, we test an event with daily recurrence. Since the Weekly Calendar starts on Sunday and ends on Saturday, if an event starts on Saturday, the second occurrence of the event is on the next week and can not be reached. ### Fix: Moving to next week for the occurrence test, limiting recurrence to 8 days to remove useless rendering. Setting `drag_and_drop` tour in Monthly Calendar view to avoid issues caused by potential `drag_and_drop` behaviour changes. In Monthly Calendar view, some days from previous and following months are visible, with a maximum of 6 before (Feb 23, see Mar 2025) and 14 after (Mar 14, see Feb 2026). Initial date being set in the backend, it does not have to respect those limitations. Changes operated in the frontend are bound to these and must be set between 15 and 22 included with the current selector. runbot-error-65494
This fixes a typo in an error message shown when someone tries to delete a product that is still used in Point of Sale. The message now displays with proper spacing, making it clearer and more professional for users.
Original PR description
Description of the issue/feature this PR addresses: 1. Start a POS session 2. Go back to the backend 3. Try to delete a product that is used in the POS 4. Error with no space between two words Current behavior before PR: The current error message has a format issue with no space after 'a' Desired behavior after PR is merged: Correct formatting opw-4247374 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fix moves a Dutch accounting setup update to run after all related modules are fully loaded. It helps prevent migration errors and makes updates smoother for companies using the Netherlands localization.
Original PR description
We faced multiple times error because this update doing a try_loading is called in `post-` scripts (after the module is loaded) and not in `end-` scripts (when all modules are loaded). All l10n_* modules were changed in this PR: https://github.com/odoo/odoo/pull/183359 task-3794536 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes a typo in the warning shown when a user tries to delete a product that is still used in an open Point of Sale session. The change makes the message clearer and more professional without changing business processes or system behavior.
Original PR description
Description of the issue/feature this PR addresses: - There is an typo in error message of methods, called when trying to delete a product, which is already listed in pos(open/active) session. **step to reproduce error** - Install 'point_of_sale' and create a product e.g 'test' which must be also available in pos. - open pos session and search for that product. - come out of the session ( use backend menu option from pos UI, session should be active) - Try to delete this product i.e. 'test' 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
This fix prevents errors when deleting German localization invoices that have corrupted or empty PDF attachments. Users can now remove these problematic invoices without encountering a system traceback, reducing disruption during cleanup or correction work.
Original PR description
Before this commit: Steps 1) Switch to DE company 2) Upload invoice using corrupted PDF (size = 0 KB) 3) Delete that invoice => It shows an error with a traceback File "/data/build/odoo/addons/l10n_de/models/ir_attachment.py", line 17, in <lambda> and guess_mimetype(attachment.raw) in ( File "/data/build/odoo/odoo/tools/mimetypes.py", line 156, in _odoo_guess_mimetype if bin_data.startswith(signature): AttributeError: 'bool' object has no attribute 'startswith' After this commit: Invoices in l10n_de with corrupted attachments will be deleted without errors screen recording: https://drive.google.com/file/d/1TMjkwYbLZwEXyLfbSzjmDaO6jOrRk2RO/view?usp=sharing opw-4115496
Mobile event filters no longer break when an event tag contains spaces or special characters, such as "By class:". This ensures visitors can reliably filter event listings regardless of how tags are named.
Original PR description
Steps to reproduce : Create a tag with space and special character (eg "By class:") Got to the /events page in mobile Click on the filter Current behavior before PR: Error on querySelector because the special char is in the css class Desired behavior after PR is merged: filter works normally task-4113765
Invoice PDFs now keep the terms and conditions text properly separated from the totals section when no payment reference is present. This prevents confusing or unprofessional invoice layouts for customers and improves document readability.
Original PR description
**Issue:** When printing an invoice with 'Untaxed Amount' and 'Total' but without a payment reference, the terms and conditions text is incorrectly displayed on the same line as 'Untaxed Amount' and 'Total' sections. **Steps to reproduce:** 1- Go to the Accounting module. 2- Create a new invoice with taxed products and no payment reference. 3- Print the invoice. The terms and conditions text will appear misaligned (see attached screenshot for reference) **Before the fix**  **After the fix:**  OPW-4189931 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The Uruguayan e-Resguardo document type is updated so it is no longer treated as an invoice internally. This helps keep local electronic document handling accurate and avoids incorrect invoice-related behavior for this document type.
Original PR description
e-Resguardo document type must not have internal type **Current behavior before PR**: e-Resguardo document type has "invoice" internal type  **Desired behavior after PR is merged**: e-Resguardo document type do not have internal type **Task Adhoc side**: 43467 **Task Latam side**: 1280 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fix restores correct error handling for certain web interface actions so failures are not accidentally hidden. It helps ensure issues surface properly while avoiding duplicate or confusing error behavior for button actions.
Original PR description
In 865baf9ef154e2a36817e40a50e09d5e98cf95f9, makeAsyncHandler has been incorrectly modified so that the promise rejection is consumed by the catch, instead of letting it bubble up through a finally. Indeed, contrarily to makeButtonHandler, makeAsyncHandler doesn't create a new Promise object. This means that the finally is applied on the result itself. In makeButtonHandler, the then handler returns a new Promise that is different from result, but that will be rejected if result is rejected. This is why in this case we need to hide that extra rejection by swallowing it in the onRejected argument, instead of using a finally. Task-Id: None
Point of Sale now makes it easier to recognize orders created specifically to settle customer account balances. This helps staff distinguish settlement transactions from regular sales, reducing confusion during checkout and account management.
Original PR description
This commit introduces an easy way to recognize "orders" which are intended to settle customer accounts. opw-4185144 Community PR: https://github.com/odoo/odoo/pull/183682
This update resolves a bug that prevented the 'Data Merge: Find Duplicate Records' process from correctly identifying duplicate records when a model's company field wasn't directly stored. The fix ensures the system can now accurately match duplicates even when relying on related fields, improving data accuracy.
Original PR description
Steps ----- 1. Create a deduplication rule for a model with a non-stored company field (e.g. Document). Add a field to the deduplication rules. 2. Run the "Data Merge: Find Duplicate Records" scheduled action. ** ValueError: <class 'psycopg2.errors.UndefinedColumn'>: "column documents_document.company_id does not exist ** Change ----- Handle the case where the company field of the model is not stored but still accessible through its related field in another table. opw-4114062 Forward-Port-Of: odoo/enterprise#68816
This update fixes an inconsistency in how query counts are measured for the test_mail module. Previously, a specific setup caused inaccurate results, particularly in single-module builds. This change adds a reliable query counter, addressing a performance issue that has been resolved through an optimization in the ORM.
Original PR description
The query count in single module build is higher than the one with all modules installed. - test_mail_enterprise…
The query count in single module build is higher than the one with all modules installed. - test_mail_enterprise   - test_mail_enterprise + documents_project   In summary, a one2many fields document_ids on document_projects triggers an [orm optimisation](https://github.com/odoo/odoo/pull/111651/files) leading to 10 less queries. In 16.0 the query count adapted in an all-enterprise build fails in single module In 17.0 a regression of performance was missed because a margin is added on a bunch of query count that didn't break in the all-enterprise build This pr proposes to add a field with the corresponding optimization in the test module in stable, to have reliable query counter. This field will be moved to the document module in master. RunbotError-65777 Forward-Port-Of: odoo/enterprise#72598
This update resolves an issue where clicking 'Insert in spreadsheet' in pivot views incorrectly redirected users to the dashboard without saving. The fix, implemented starting with saas-17.4, completely removes the 'Dashboards' tab from the pivot view, eliminating the error. This ensures users can properly access spreadsheet functionality.
Original PR description
Steps to reproduce: - install Documents and CRM - login as Marc Demo - go to any pivot view - click on "Insert in spreadsheet" - select the Dashboards tab and confirm => boom In this version, the fix is sub-optimal. The user will be redirected to the dashboard, but nothing happens. It's fixed properly starting with saas-17.4 because the code changed and it's mush easier and safer to fix. The Dashboard tab won't appear at all. Task: 4273554
This update resolves a problem preventing the Social Marketing tour from functioning correctly. The fix addresses an issue with accessing a key input field and updates the tour's triggering mechanism for compatibility across Odoo versions. This ensures a smoother onboarding experience for new users.
Original PR description
Fixed onboarding Social Marketing tour which is not working properly. Reason ====== We're not getting this `'textarea[name="message"]` for some reasons, & there is no `name` attribute in textarea. Also, we removed `extra_tringger` in later version, and we can use `run: 'edit` instead so removed that & used common classes that works on all version. Task-4210376 Forward-Port-Of: odoo/enterprise#71016
Steps to reproduce: - Drop the "Team" snippet and toggle it to grid mode. - Change the grid items padding with the "Padding (Y, X)" option. => The `o_we_padding_highlight` class used to show the padding preview is also added on the inner row of the grid items. This happens because the `data-apply-to` attribute of this option targets the `.row` elements in general, instead of only the grid mode one (so having the `o_grid_mode` class). This commit fixes this issue by changing this attribut
Original PR description
Steps to reproduce: - Drop the "Team" snippet and toggle it to grid mode. - Change the grid items padding with the "Padding (Y, X)" option. => The `o_we_padding_highlight` class used to show the padding preview is also added on the inner row of the grid items. This happens because the `data-apply-to` attribute of this option targets the `.row` elements in general, instead of only the grid mode one (so having the `o_grid_mode` class). This commit fixes this issue by changing this attribute, by patching the template in JS as a stable fix. Note that in above versions, the padding option changed so this fix will not be needed (but other grid options will need a similar fix). task-4247543 Forward-Port-Of: odoo/odoo#183219
A traceback occurs from version 18.0 when the user creates a new link tracker. To reproduce this issue in 18.0: 1) Install website, link tracker and enable debug mode 2) Tries to create a new link tracker record from the link tracker Error:- ``` TypeError: Cannot mix str and bytes arguments (got (False, 'False')) ``` The onchange sets computes to False by default when they're requested, and apparently does not recompute them if they don't depend on anything. Because of that
Original PR description
A traceback occurs from version 18.0 when the user creates a new link tracker. To reproduce this issue in 18.0: 1) Install website, link tracker and enable debug mode 2) Tries to create a new link tracker record from the link tracker Error:- ``` TypeError: Cannot mix str and bytes arguments (got (False, 'False')) ``` The onchange sets computes to False by default when they're requested, and apparently does not recompute them if they don't depend on anything. Because of that the `short_url_host` value will be False and this leads to a traceback when the compute method of `short_url` triggers. Ref of the breaking commit:- https://github.com/odoo/odoo/pull/170548/commits/20d2f122568feead98df18706ca0a4691c8393c5 sentry-5969318187 Forward-Port-Of: odoo/odoo#182898
The event is create with a date_begin and date_end calling datetime.now consecutively. This can lead to a situation where the date_end is before the date_begin in verry rare case (not monotonic). This commit fix this by calling datetime.now only once and using the same value for both date_begin and date_end. runbot error [56986](https://runbot.odoo.com/web#id=56986&cids=1&menu_id=424&action=573&model=runbot.build.error&view_type=form) Forward-Port-Of: odoo/odoo#184990
Original PR description
The event is create with a date_begin and date_end calling datetime.now consecutively. This can lead to a situation where the date_end is before the date_begin in verry rare case (not monotonic). This commit fix this by calling datetime.now only once and using the same value for both date_begin and date_end. runbot error [56986](https://runbot.odoo.com/web#id=56986&cids=1&menu_id=424&action=573&model=runbot.build.error&view_type=form) Forward-Port-Of: odoo/odoo#184990
The test_sync_recorder was breaking for strange reason because of extra elements in the stack A first attempt was made trying to remove last elements but in some case a `_remove` or `signal_handler` can appear in the middle. It looks to complex to adapt the test to work in all those cases. Moving it to a non standard test looks like the simplest solution for now. runbot error [73473](https://runbot.odoo.com/web#id=73473&cids=1&menu_id=424&action=573&model=runbot.build.error&view_type=form)
Original PR description
The test_sync_recorder was breaking for strange reason because of extra elements in the stack A first attempt was made trying to remove last elements but in some case a `_remove` or `signal_handler` can appear in the middle. It looks to complex to adapt the test to work in all those cases. Moving it to a non standard test looks like the simplest solution for now. runbot error [73473](https://runbot.odoo.com/web#id=73473&cids=1&menu_id=424&action=573&model=runbot.build.error&view_type=form) Forward-Port-Of: odoo/odoo#185023
Fixed onboarding Email Marketing tour which is not working properly. Reason ====== We're not getting this `'input[name="subject"]',` trigger for some reasons, & there is no `name` attribute with input. we do have `id` in input, but in v16 we got id as `subject` and v17+ gets `subject_0` so that can't be used. Also, the next trigger should be after user click on input field not when they write. One more point, sometimes it got stuck after selecting a theme and did not shows the pointer
Original PR description
Fixed onboarding Email Marketing tour which is not working properly. Reason ====== We're not getting this `'input[name="subject"]',` trigger for some reasons, & there is no `name` attribute with input. we do have `id` in input, but in v16 we got id as `subject` and v17+ gets `subject_0` so that can't be used. Also, the next trigger should be after user click on input field not when they write. One more point, sometimes it got stuck after selecting a theme and did not shows the pointer. We changed button text to `Send to All` from `Ok` in v17 Fixed/Improved that & used common classes that works on all version. Task-4210376 Forward-Port-Of: odoo/odoo#182034
When upgrading a module where a model has been removed entirely, the ORM does a clean up for 'ir.model.fields.selection' records. However, in this case it doesn't work, because the records reference a model that no longer belongs to the registry (if there are no migration scripts). This commit simply makes the cleanup ignore such a case. It makes sense, because the whole table will be deleted anyway (if there are no migration scripts). STEPS - install a module that defines a model with
Original PR description
When upgrading a module where a model has been removed entirely, the ORM does a clean up for 'ir.model.fields.selection' records. However, in this case it doesn't work, because the records reference a model that no longer belongs to the registry (if there are no migration scripts). This commit simply makes the cleanup ignore such a case. It makes sense, because the whole table will be deleted anyway (if there are no migration scripts). STEPS - install a module that defines a model with a selection field - rename or remove the model - upgrade the module This commit fixes #179392. It was inspired by #104624. opw-3024537 Forward-Port-Of: odoo/odoo#184764
Steps to reproduce: - Create a Sale Order for a storable product and confirm it - Create another user with the following permissions: - Sales > User: Own Documents Only - Inventory > User - With that user, create a new Sale Order for the same product and confirm it. - Click the forecast icon and open the report. Issue: An AccessError will be triggered, as that user doesn't have the rights to access the SO lines of the first SO since it wasn't created by them. While it's correct
Original PR description
Steps to reproduce: - Create a Sale Order for a storable product and confirm it - Create another user with the following permissions: - Sales > User: Own Documents Only - Inventory > User - With that user, create a new Sale Order for the same product and confirm it. - Click the forecast icon and open the report. Issue: An AccessError will be triggered, as that user doesn't have the rights to access the SO lines of the first SO since it wasn't created by them. While it's correct that this user shouldn't be able to access the sale order, we still want them to be able to access the forecast report and see their use, even though they can't click on them and see the SO content. Same thing should apply for draft SO, as they indicate potential future state of the stock as well. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#182914
Before this commit we are not able to move expense to a reconciled account in a future period because posting future entries are delayed so we can't reconciled journal items on the fly. * create new company 'test' * switch on it * install French accounting (l10n_fr) * check 'Show Full Accounting Features' to gives access to accounting feature on your user access tab * create vendor bill and post it * go to the 'Journal Items' tab and click on cut-off button and set following fields in
Original PR description
Before this commit we are not able to move expense to a reconciled account in a future period because posting future entries are delayed so we can't reconciled journal items on the fly. * create new company 'test' * switch on it * install French accounting (l10n_fr) * check 'Show Full Accounting Features' to gives access to accounting feature on your user access tab * create vendor bill and post it * go to the 'Journal Items' tab and click on cut-off button and set following fields in the wizard: * *Recognition Date*: next month * *Accrued Account*: '486000 Charges constatées d'avance' * Adjusting Amount: as you want 50% for example * *Journal* : Miscellaneous Operations * click on create journal entries button Journal entries should be created. Fixes #94390 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#184793 Forward-Port-Of: odoo/odoo#94395
The test depended on a module that was not in the depends. Forward-Port-Of: odoo/odoo#184578
Original PR description
The test depended on a module that was not in the depends. Forward-Port-Of: odoo/odoo#184578
This pr is created to help de user to know the origin of the afip error 10016. The error 10016 can be caused by different origins, so here we give the user more precision about the origin. The objective of this pr is to be able to differentiate what is the origin of error 10016 and to be able to give a more precise message to the client. 1) If the last afip invoice validated has a higher date than the date of the invoice that is being validated then the message shown to the user is '10016-
Original PR description
This pr is created to help de user to know the origin of the afip error 10016. The error 10016 can be caused by different origins, so here we give the user more precision about the origin. The…
This pr is created to help de user to know the origin of the afip error 10016.
The error 10016 can be caused by different origins, so here we give the user more precision about the origin. The objective of this pr is to be able to differentiate what is the origin of error 10016 and to be able to give a more precise message to the client.
1) If the last afip invoice validated has a higher date than the date of the invoice that is being validated then the message shown to the user is '10016-1': 'The invoice date cannot be after the last invoice validated in AFIP.'
2) If the last afip invoice number is higher than the current invoice number being validated in Odoo, then the message shown to the user is '10016-2': 'There may have been a mismatch in the numbering of this type of document between Odoo and AFIP.'
3) If any other reason cause the error '10016' then the message shown to the user is:
* Please note that if you are trying to validate an invoice with a date other than today, you must verify if it falls within the date range according to the AFIP concept or document type:
a) If it is Product: N+5 or N-5 with N being today's date.
b) If it is Services or Products and services: N+10 or N-10 with N being today's date.
c) If it is a MiPyme Invoice: N-5 0 N+1 with N being today's date. For Debit Note or Credit Note only N-5"
Task Adhoc side: 37771
Task latam side: 1194
Forward-Port-Of: odoo/enterprise#61313