Thursday, April 13, 2023
33 changes · master
Enhancements to existing features
Task lists for main tasks, sub-tasks, and blocked-by items now use the same layout. This makes project information easier to compare and ensures future list changes apply consistently across related task views.
Original PR description
Purpose of this commit have consistent list views between project.task and the sub-tasks / blocked by o2m so that when a change is done in one place it also impacts the other places. So, in this commit add/update sub-task and blocked by page list views to make them identical. task-3165202
The timesheet unit timer display has been adjusted so its toggle button takes up less space. This provides a cleaner, more compact layout for users entering or reviewing timesheets.
Original PR description
We have added the o_field_timesheet_uom class in the timesheet_uom_timer widget,this class reduced the width of the toggle button. task-3251667
Payroll salary attachment records no longer mark a file upload field as tracked, because Odoo does not record changes to binary files in the chatter. This avoids misleading configuration and keeps payroll record tracking aligned with what the system can actually display.
Original PR description
before this commit, tracking is enable for the binary field, but odoo is not tracking binary fields to the chatter. after this commit, the tracking attribute is removed from the binary field w.r.t: https://github.com/odoo/odoo/commit/8506b9d62680f5e4d4cbd06359045e33920e5b66
Resolved issues and error corrections
This change fixes a small issue that could affect the emoji picker when replying to social stream comments. It ensures the picker receives the correct page element, improving reliability without changing the user workflow.
Original PR description
`useRef()` hook should only be used in `setup()` of component. The `add()` function of emoji picker can be used anywhere. This commit fixes the issue by limiting use of `add()` to pass Object whose `el` is an element. We should pass the ref immediately rather than the refName. https://github.com/odoo/odoo/pull/118293
Features or functions removed from Odoo
The Studio navigation bar no longer includes the shortcut to Notes. This simplifies the Studio interface by removing an entry point that is no longer needed, with minimal impact on day-to-day use.
Original PR description
This commit simply removes the notes shortcut of the studio navbar. opw-3259540
Code cleanup and technical improvements
Several enterprise apps were adjusted to stay compatible with an underlying interface change for on-screen popovers. This keeps features such as follow-ups, appointments, documents, knowledge, project planning, Gantt views, and Studio approvals working consistently without changing the user-facing workflow.
Original PR description
odoo/odoo#118066
Miscellaneous changes
Some customers in Austria are exporting their data using the DateV export available in `l10n_de_reports`. We can show the button for all DACH countries (countries where DateV is active) In the future, we shoud get this logic out of the German module, and make sure that it works for all of these countries. Forward-Port-Of: odoo/enterprise#38502
Original PR description
Some customers in Austria are exporting their data using the DateV export available in `l10n_de_reports`. We can show the button for all DACH countries (countries where DateV is active) In the future, we shoud get this logic out of the German module, and make sure that it works for all of these countries. Forward-Port-Of: odoo/enterprise#38502
It's possible to open a "Bar" without setting up the floors and tables. In this situation, we still want to see that is being sent to the preparations display. This commit fixes that behavior. First, we fix the traceback caused by sending undefined 'pos_order_id' in creating the preparation display order records. Then, when fetching the display orders, we also fetch those that are not linked to pos.order. Forward-Port-Of: odoo/enterprise#39705
Original PR description
It's possible to open a "Bar" without setting up the floors and tables. In this situation, we still want to see that is being sent to the preparations display. This commit fixes that behavior. First, we fix the traceback caused by sending undefined 'pos_order_id' in creating the preparation display order records. Then, when fetching the display orders, we also fetch those that are not linked to pos.order. Forward-Port-Of: odoo/enterprise#39705
Steps to reproduce the bug: - Go to “Master Production schedule” - Set the number of records on a page to 2 (so you will have several pages) - Hover over "replenish" button Problem: Traceback is triggered: “Cannot read properties of null (reading 'getElementsByClassName')” When the mouse pointer enter or leave, the main "REPLENSIH" button, it triggers an event that fetch elements of the rows based on a specific class attribute: https://github.com/odoo/enterprise/blob/3b6aed1e5cab06720
Original PR description
Steps to reproduce the bug: - Go to “Master Production schedule” - Set the number of records on a page to 2 (so you will have several pages) - Hover over "replenish" button Problem: Traceback is…
Steps to reproduce the bug: - Go to “Master Production schedule” - Set the number of records on a page to 2 (so you will have several pages) - Hover over "replenish" button Problem: Traceback is triggered: “Cannot read properties of null (reading 'getElementsByClassName')” When the mouse pointer enter or leave, the main "REPLENSIH" button, it triggers an event that fetch elements of the rows based on a specific class attribute: https://github.com/odoo/enterprise/blob/3b6aed1e5cab06720c7f2f2120a9589b12a1dd34/mrp_mps/static/src/components/line.js#L163-L164 https://github.com/odoo/enterprise/blob/3b6aed1e5cab06720c7f2f2120a9589b12a1dd34/mrp_mps/static/src/components/line.js#L170-L171 As we have changed the number of records to 2, the other lines are no longer in view and will no longer refer to this specific class, so when we try to access them with `getElementsByClassName` it's throw a TypeError: cannot read properties of null. opw-3245457 Forward-Port-Of: odoo/enterprise#39567
On uninstall of sale_planning, planning slots linked to an SO line would just have their SO line set to null, resulting in a planning slot with neither start/end datetimes nor an SO line. Upon reinstalling sale_planning, setting up the `check_datetimes_set_or_plannable_slot` constraint would then fail, as the previously created slots would be in an invalid state. Cascade the deletion of SO lines into the planning slots, instead of just setting the FK to NULL. Forward-Port-Of: odoo/enterp
Original PR description
On uninstall of sale_planning, planning slots linked to an SO line would just have their SO line set to null, resulting in a planning slot with neither start/end datetimes nor an SO line. Upon reinstalling sale_planning, setting up the `check_datetimes_set_or_plannable_slot` constraint would then fail, as the previously created slots would be in an invalid state. Cascade the deletion of SO lines into the planning slots, instead of just setting the FK to NULL. Forward-Port-Of: odoo/enterprise#39682 Forward-Port-Of: odoo/enterprise#39614
When one doesn't set a due date for a document request the sent mail has this kind of message : (Planned on ) This commit fix that by removing the sentence when there is no due date. Task-3231376 Forward-Port-Of: odoo/enterprise#39386
Original PR description
When one doesn't set a due date for a document request the sent mail has this kind of message : (Planned on ) This commit fix that by removing the sentence when there is no due date. Task-3231376 Forward-Port-Of: odoo/enterprise#39386
Before this commit, one couldn't log out when on the portal share page, this was due to the missing of bootstrap assets such ass dropdown.js and popper.js One couldn't upload a document with a request a file shared page. Task-3231376 Forward-Port-Of: odoo/enterprise#38238
Original PR description
Before this commit, one couldn't log out when on the portal share page, this was due to the missing of bootstrap assets such ass dropdown.js and popper.js One couldn't upload a document with a request a file shared page. Task-3231376 Forward-Port-Of: odoo/enterprise#38238
The credit limit information and credit limit warning in the PoS were displaying when the credit limit was not active in the global settings and when the credit limit was 0 (usually meaning infinite in other places in Odoo). This was confusing or abnormal. Now the credit limit is displaying if the credit limit global setting is active AND the partner credit limit is bigger than 0 AND the partner overdue its credit limit. Forward-Port-Of: odoo/enterprise#39345
Original PR description
The credit limit information and credit limit warning in the PoS were displaying when the credit limit was not active in the global settings and when the credit limit was 0 (usually meaning infinite in other places in Odoo). This was confusing or abnormal. Now the credit limit is displaying if the credit limit global setting is active AND the partner credit limit is bigger than 0 AND the partner overdue its credit limit. Forward-Port-Of: odoo/enterprise#39345
This fixes the EDI format compatibility validation on journals in other locations. Also pass the journal country code validation to the journal EC types implementation validation, copying the way other locations do. Forward-Port-Of: odoo/enterprise#37933
Original PR description
This fixes the EDI format compatibility validation on journals in other locations. Also pass the journal country code validation to the journal EC types implementation validation, copying the way other locations do. Forward-Port-Of: odoo/enterprise#37933
To reproduce ============ - on any app that has a notebook - on studio make one of the pages invisible - try to make this page visible again (impossible) Problem ======= When setting the page invisible the checkbox is not checked, so clicking on it again will trigger action to make the page invisible. The issue comes from the fact that the `checked` value of this checkbox is binded to `widget.state.attrs.invisible` but from 16, the invisible modifier is not included in `attrs` directly
Original PR description
To reproduce ============ - on any app that has a notebook - on studio make one of the pages invisible - try to make this page visible again (impossible) Problem ======= When setting the page invisible the checkbox is not checked, so clicking on it again will trigger action to make the page invisible. The issue comes from the fact that the `checked` value of this checkbox is binded to `widget.state.attrs.invisible` but from 16, the invisible modifier is not included in `attrs` directly but in `attrs.modifiers`. Solution ======== use `widget.state.attrs.modifiers.invisible` opw-3233079 Forward-Port-Of: odoo/enterprise#39711 Forward-Port-Of: odoo/enterprise#38489
Purpose: - Currently, when unfolding an article in the sidebar, a "404 not found" message is added under the row of the unfolded article if this article is not accessible by the user anymore or if it has been deleted. Now, an AccessError will be shown to the user, so that he knows why he cannot unfold the article, and the article will be removed from the sidebar. Task-3266638 Forward-Port-Of: odoo/enterprise#39454
Original PR description
Purpose: - Currently, when unfolding an article in the sidebar, a "404 not found" message is added under the row of the unfolded article if this article is not accessible by the user anymore or if it has been deleted. Now, an AccessError will be shown to the user, so that he knows why he cannot unfold the article, and the article will be removed from the sidebar. Task-3266638 Forward-Port-Of: odoo/enterprise#39454
Add a `file -> Download as JSON` top menu to easily download the json content for manual edition some users may require. Forward-Port-Of: odoo/enterprise#39536 Forward-Port-Of: odoo/enterprise#38956
Original PR description
Add a `file -> Download as JSON` top menu to easily download the json content for manual edition some users may require. Forward-Port-Of: odoo/enterprise#39536 Forward-Port-Of: odoo/enterprise#38956
Have a button in a form view, with studio_approval=True on it to make sure the action won't be executed if the user doesn't have the right to do it. Create a new record, and click on that button. Before this commit, the call to check the approvals was passed without a resId, which did not crash the first time, but the return value was wrong as the record was not yet created. After this commit, we make sure we save the record before checking the approvals and before executing the wanted
Original PR description
Have a button in a form view, with studio_approval=True on it to make sure the action won't be executed if the user doesn't have the right to do it. Create a new record, and click on that button. Before this commit, the call to check the approvals was passed without a resId, which did not crash the first time, but the return value was wrong as the record was not yet created. After this commit, we make sure we save the record before checking the approvals and before executing the wanted action. opw-3254791 Forward-Port-Of: odoo/enterprise#39282
steps: helpdesk > configuration > stages > select any stage cause: text and the kanban label were not properly aligned issue: ps-0 was not giving space between the text and the kanban label fix: improved it with ps-2 to get space between the text and the kanban label task-3141892 Forward-Port-Of: odoo/enterprise#39554 Forward-Port-Of: odoo/enterprise#36041
Original PR description
steps: helpdesk > configuration > stages > select any stage cause: text and the kanban label were not properly aligned issue: ps-0 was not giving space between the text and the kanban label fix: improved it with ps-2 to get space between the text and the kanban label task-3141892 Forward-Port-Of: odoo/enterprise#39554 Forward-Port-Of: odoo/enterprise#36041
The xmlid for the replacement contract type was not correct. Forward-Port-Of: odoo/enterprise#39616
Original PR description
The xmlid for the replacement contract type was not correct. Forward-Port-Of: odoo/enterprise#39616
The refusal notification was triggered for every applicant being archived, which whould fail when there was no referral user. Fixes #38554 task-3270054 Forward-Port-Of: odoo/enterprise#39625
Original PR description
The refusal notification was triggered for every applicant being archived, which whould fail when there was no referral user. Fixes #38554 task-3270054 Forward-Port-Of: odoo/enterprise#39625
The _validate_session() method in the l10n_de_pos_cert module was overridden without checking for a dictionary return value from the super method. This could cause unexpected behavior or errors when a redirection or a wizard was returned. For example, after calling the super function, it was possible that all orders were in the "paid" state and the session validation was not completed. This would cause the orders to be an empty recordset and generate errors when generating a template. Aft
Original PR description
The _validate_session() method in the l10n_de_pos_cert module was overridden without checking for a dictionary return value from the super method. This could cause unexpected behavior or errors when a redirection or a wizard was returned. For example, after calling the super function, it was possible that all orders were in the "paid" state and the session validation was not completed. This would cause the orders to be an empty recordset and generate errors when generating a template. After this commit it checks for a dictionary return value and returns it immediately if one is found, preventing the rest of the code from executing. This ensures that the code is only executed when it is appropriate to do so. opw-3265441 Forward-Port-Of: odoo/enterprise#39647
Current behaviour: The implementation of the `fetch_mail` function interogates the email server used for the EDI based on the IMAP uids. When first setting up the incoming email server record, the `l10n_cl_last_uid` used to track the last maximum uid that was processesed is set to 1. In pratice this leads to the function searching the IMAP server for mails from 1:*, i.e. a list of ALL IMAP uids is returned and a `for` loop is used to fetch one email at a time and validate the email attach
Original PR description
Current behaviour: The implementation of the `fetch_mail` function interogates the email server used for the EDI based on the IMAP uids. When first setting up the incoming email server record, the…
Current behaviour:
The implementation of the `fetch_mail` function interogates
the email server used for the EDI based on the IMAP uids. When first
setting up the incoming email server record, the `l10n_cl_last_uid` used
to track the last maximum uid that was processesed is set to 1.
In pratice this leads to the function searching the IMAP server for mails
from 1:*, i.e. a list of ALL IMAP uids is returned and a `for` loop is used
to fetch one email at a time and validate the email attachements for invoice
data. `l10n_cl_last_uid` gets updated outside the for loop to the last
processed uid in the current run.
The problem arises when the client connects to a new email server already
containing thousand of emails. In that case, while trying to process all
emails, the process will time out on the standard cpu limit (900s). Thus
the `for` loop never finishes and `l10n_cl_last_uid` never updates. At each
new run, the function begins from uid=1 again and timing out again.
After this fix:
We add a conservative default batch size (hardcoded to 50), so that the
`for` loop will only loop over the next 50 queued emails. Given an average
processing time of 2-3 seconds for each fetched email, this should guarantee
that the process never times out on current hardware and default settings.
As the default recurrence for the fetchmail cron job is "every 5 minutes",
we can expect that in most real life scenarios the clients DB should sync
in a matter of days maximum.
We also add a `server.write({'l10n_cl_last_uid': new_max_uid})` to the
try block relating to the email processing. This will keep track more often
of the last max processed IMAP uid in case the job is aborted for some other
unforseen reason.
opw-3225345
Forward-Port-Of: odoo/enterprise#39577ProgrammingError: can't adapt type 'pos.category' is generated when we follow below steps this is because the in search domain category_ids is required numbers(ids) but in function 'preparation_displays' was passed object. Steps to reproduce: 1) Install 'point_of_sale' module > Activate 'Preparation Display' from Configuration > Settings 2) Open pos session having preparation display like 'Bar'. 3) Create and validate a order > Close the session. 4) Click on 'Orders' > 'Preparation Disp
Original PR description
ProgrammingError: can't adapt type 'pos.category' is generated when we follow below steps this is because the in search domain category_ids is required numbers(ids) but in function 'preparation_displays' was passed object.
Steps to reproduce:
1) Install 'point_of_sale' module > Activate 'Preparation Display' from
Configuration > Settings
2) Open pos session having preparation display like 'Bar'. 3) Create and validate a order > Close the session. 4) Click on 'Orders' > 'Preparation Display' and select 'Open Display' according
to order.
5) Click on order item and the error will be generated in backend.
See:

By applying this, `categories.ids` will be passed instead of `category`.
sentry - 4063535802
Forward-Port-Of: odoo/enterprise#39485In https://github.com/odoo/enterprise/pull/35050 we created hooks throughout the checkout process in order to easily pass values to localization-specific templates. (for example, `_cart_values()`). Now that several localizations are customizing the checkout process (in particular Chile, see https://github.com/odoo/enterprise/pull/38737) all the hooks need to be called (via inheritance) meaning that they all need to call `super()`. So this fixes the few hooks that don't yet call super(). F
Original PR description
In https://github.com/odoo/enterprise/pull/35050 we created hooks throughout the checkout process in order to easily pass values to localization-specific templates. (for example, `_cart_values()`). Now that several localizations are customizing the checkout process (in particular Chile, see https://github.com/odoo/enterprise/pull/38737) all the hooks need to be called (via inheritance) meaning that they all need to call `super()`. So this fixes the few hooks that don't yet call super(). Forward-Port-Of: odoo/enterprise#39428