Friday, September 10, 2021
34 changes · master
Enhancements to existing features
This change improves Odoo's internal testing tools by allowing certain test forms to skip required-field checks when needed. It helps developers create more accurate automated tests for specific scenarios without affecting day-to-day users.
Original PR description
…emulator 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
Resolved issues and error corrections
Duplicating a manufacturing work order no longer reuses the original analytic accounting line links, preventing incorrect accounting references. The update also keeps work order analytic line names and references aligned when a production order is renamed.
Original PR description
Both mo_analytic_account_line_id and wc_analytic_account_line_id are copied when duplicate the workorder. This is not correct. Task-2638896 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Miscellaneous changes
- Create a product with Category configured with: * Costing Method: First In First Out (FIFO) * Inventory Valuation: Automated - Create a PO to buy 1 unit and receive the product - Create a SO to sell 1 unit and deliver the product - Return the product - Re-deliver the product - Create invoice for SO but don't post it - Connect with an user with "Accounting: Accountant" rights only - Post the invoice An access error will be triggered when trying to access stock valuation layer.
Original PR description
- Create a product with Category configured with: * Costing Method: First In First Out (FIFO) * Inventory Valuation: Automated - Create a PO to buy 1 unit and receive the product - Create a SO to sell 1 unit and deliver the product - Return the product - Re-deliver the product - Create invoice for SO but don't post it - Connect with an user with "Accounting: Accountant" rights only - Post the invoice An access error will be triggered when trying to access stock valuation layer. opw-2623376 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 Forward-Port-Of: odoo/odoo#75507
Projects marked as on hold now appear blue in the kanban progress bar, matching the status dot shown on each project card. This removes a visual inconsistency and makes project status easier to understand at a glance.
Original PR description
Currently, projects that are 'on hold' stage are represented in grey in the kanban progress bar while the colored dot on their card is in blue. In this commit, we change the color of the 'on hold' stage into 'info' instead of 'muted'. After this projects that are 'on hold' are display blue in the kanban progress bar as well. Task-Id:2633273 PR: #75850 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
The planning form layout has been corrected so Sales Order and Hours Recorded buttons appear on the same line. This makes the form cleaner and easier to scan without changing business logic or workflows.
Original PR description
project_timesheet_forecast , planning_sale Currently, SO and Hours Recorded stat buttons arrive in different lines in the planning form view. It has been done in the same line. Task-ID : 2638500
…tracks Currently, when there is a YouTube URL configured on the track, we automatically set the layout of the track page as "widescreen". This implies that we hide some menus and adapt the layout to display the full video player. However, in the XML template of the track view, we only display the video player if there is a YouTube URL configured AND one or more of those conditions is respected: - The track is configured as a "YouTube Replay" - The track is "coming soon" (< 30 min
Original PR description
…tracks Currently, when there is a YouTube URL configured on the track, we automatically set the layout of the track page as "widescreen". This implies that we hide some menus and adapt the layout to display the full video player. However, in the XML template of the track view, we only display the video player if there is a YouTube URL configured AND one or more of those conditions is respected: - The track is configured as a "YouTube Replay" - The track is "coming soon" (< 30 minutes) - The track is live - The track is done This is done to match the two behaviors and get a consistent display. Task-2643147 Forward-Port-Of: odoo/odoo#76248
**[IMP] web: Manage 'no_open' options for x2many fields** options="{'no_open': '1'}" is managed for many2one fields. This commit aims to do the same for x2many fields. **[FIX] account_edi: Prevent opening the EDI documents in any case** Also, remove the duplicated 'edi_document_ids' field inside the view. 'edi_document_ids' is now in debug mode for payments. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#75529
Original PR description
**[IMP] web: Manage 'no_open' options for x2many fields**
options="{'no_open': '1'}" is managed for many2one fields.
This commit aims to do the same for x2many fields.
**[FIX] account_edi: Prevent opening the EDI documents in any case**
Also, remove the duplicated 'edi_document_ids' field inside the view.
'edi_document_ids' is now in debug mode for payments.
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#75529Description 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 Forward-Port-Of: odoo/odoo#76221
Original PR description
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 Forward-Port-Of: odoo/odoo#76221
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 Forward-Port-Of: odoo/odoo#76035
Original PR description
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 Forward-Port-Of: odoo/odoo#76035
- Go to any graph view (i.e. in CRM) - Change "Group By" 2 times very very quickly (In Chrome, you can set Throttling to "Slow 3G" in Network tab of devtools) Data from first groupby will be mixed with data from the second one. A graph reload is performing the following steps: * clean previous data * fetch data * set data The issue happens when a second reload is performed while the previous one has not set its data yet and the cleaning step of the second one is performed befor
Original PR description
- Go to any graph view (i.e. in CRM) - Change "Group By" 2 times very very quickly (In Chrome, you can set Throttling to "Slow 3G" in Network tab of devtools) Data from first groupby will be mixed with data from the second one. A graph reload is performing the following steps: * clean previous data * fetch data * set data The issue happens when a second reload is performed while the previous one has not set its data yet and the cleaning step of the second one is performed before the setting step of the first one. The solution will be to ignore the setting step of all previous reloads if there is a more recent one. opw-2460145 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 Forward-Port-Of: odoo/odoo#76279 Forward-Port-Of: odoo/odoo#75307
Actually we can't gie more one barcode for a product In inventory we can make "package" with various quantity So with this commit we add the possibility to add a package of product (1-n) with a specific barcode Task: 2610279 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 Forward-Port-Of: odoo/odoo#76212
Original PR description
Actually we can't gie more one barcode for a product In inventory we can make "package" with various quantity So with this commit we add the possibility to add a package of product (1-n) with a specific barcode Task: 2610279 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 Forward-Port-Of: odoo/odoo#76212
`fields.Date.today` doesn't give date based on TZ which might be wrong in some cases as it doesn't respect TZ. With this commit, we are using `fields.Date.context_today` as default date. 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 Forward-Port-Of: odoo/odoo#75600
Original PR description
`fields.Date.today` doesn't give date based on TZ which might be wrong in some cases as it doesn't respect TZ. With this commit, we are using `fields.Date.context_today` as default date. 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 Forward-Port-Of: odoo/odoo#75600
Before this commit, safari mobile would immediately launch new videos as fullScreen, while safari would prevent the autoplay of videos, as the play request didn't originate from a user input. Forward-Port-Of: odoo/odoo#76069
Original PR description
Before this commit, safari mobile would immediately launch new videos as fullScreen, while safari would prevent the autoplay of videos, as the play request didn't originate from a user input. Forward-Port-Of: odoo/odoo#76069
Before this commit, ending the call on mobile when on fullScreen would lead to a traceback as the callViewer was updated asynchronously because it relies on the browser fullScreen promises. This commit fixes this issue by ensuring that the callViewer still exists when the fullScreen promise is resolved. Forward-Port-Of: odoo/odoo#76073
Original PR description
Before this commit, ending the call on mobile when on fullScreen would lead to a traceback as the callViewer was updated asynchronously because it relies on the browser fullScreen promises. This commit fixes this issue by ensuring that the callViewer still exists when the fullScreen promise is resolved. Forward-Port-Of: odoo/odoo#76073
Before this commit, leaving the call before the request for the audio stream was complete would lead to a traceback as the following operations were no longer relevant when a call is ended. Forward-Port-Of: odoo/odoo#76153
Original PR description
Before this commit, leaving the call before the request for the audio stream was complete would lead to a traceback as the following operations were no longer relevant when a call is ended. Forward-Port-Of: odoo/odoo#76153
Commit cd122933867c096f61fae945f11e842ea84d06b8 introduced an optimization in the way that models and their inheritances are loaded, with this commit we defer the setting of each model class' bases from the _build_model method to the _prepare_setup method. This has the advantage of setting any given model class' `__bases__` attribute only once, but it also means that when _add_manual_models is called, the __bases__ for ir.model are not yet set (only the default implementation exists), t
Original PR description
Commit cd122933867c096f61fae945f11e842ea84d06b8 introduced an optimization in the way that models and their inheritances are loaded, with this commit we defer the setting of each model class' bases…
Commit cd122933867c096f61fae945f11e842ea84d06b8 introduced an optimization in the way that models and their inheritances are loaded, with this commit we defer the setting of each model class' bases from the _build_model method to the _prepare_setup method. This has the advantage of setting any given model class' `__bases__` attribute only once, but it also means that when _add_manual_models is called, the __bases__ for ir.model are not yet set (only the default implementation exists), therefore any module overrides to ir.model do not take effect when creating the custom models. This meant that if one creates a custom model with chatter support (i.e. custom ir.model behaviour implemented in mail) and one restarted the server, the registry would not properly setup ir.model before creating the custom model (yielding warnings about tracking and such not being valid fields) and when creating a record of the custom model, the registry would crash. With this commit, ir.model's _prepare_setup is explicitly called before _add_manual_models to ensure that all overrides to ir.model are taken into account. Forward-Port-Of: odoo/odoo#76272
This commits adds a proper event listener removal for `onbeforeunload` to facilitate testing and cleans up the join/leave rpc button locking. Forward-Port-Of: odoo/odoo#75993
Original PR description
This commits adds a proper event listener removal for `onbeforeunload` to facilitate testing and cleans up the join/leave rpc button locking. Forward-Port-Of: odoo/odoo#75993
Before this commit, the callViewer model was re instantiated in cases when the amount of RTC session would change, which was not necessary if the call viewer was already present. Forward-Port-Of: odoo/odoo#76205
Original PR description
Before this commit, the callViewer model was re instantiated in cases when the amount of RTC session would change, which was not necessary if the call viewer was already present. Forward-Port-Of: odoo/odoo#76205
Since the addition of guests, it isn't enough to rely on the `partner_id` of the record to get the name. This commit adds an override of `name_get` so that the `display_name` of the record remains consistent for both partners and guests. Forward-Port-Of: odoo/odoo#76249
Original PR description
Since the addition of guests, it isn't enough to rely on the `partner_id` of the record to get the name. This commit adds an override of `name_get` so that the `display_name` of the record remains consistent for both partners and guests. Forward-Port-Of: odoo/odoo#76249
task-2638359 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#76167
Original PR description
task-2638359 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#76167
Before this commit, the context given to the client action report was incorrect and produced a crash server-side. After this commit the context is correctly given to the ReportAction and to the print 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 Forward-Port-Of: odoo/odoo#76254
Original PR description
Before this commit, the context given to the client action report was incorrect and produced a crash server-side. After this commit the context is correctly given to the ReportAction and to the print 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 Forward-Port-Of: odoo/odoo#76254
Since commit bbb1a8f151b, module's upgrade script can also be added into special 'upgrades' folder as an alternative to the old 'migrations' folder. As those upgrade scripts are not maintained from version to version, we should not count them as maintenance. OPW-2536046 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#76184
Original PR description
Since commit bbb1a8f151b, module's upgrade script can also be added into special 'upgrades' folder as an alternative to the old 'migrations' folder. As those upgrade scripts are not maintained from version to version, we should not count them as maintenance. OPW-2536046 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#76184
The search param "domains" of type Array was not satisfactory for several reasons: - useless for non reporting views - too close from the search param "domain" - a key "fieldName" was put on the value (resulting in a loss of information in case of stringification) We change it for a search param "comparison" of type null or Object. Forward-Port-Of: odoo/odoo#76163
Original PR description
The search param "domains" of type Array was not satisfactory for several reasons: - useless for non reporting views - too close from the search param "domain" - a key "fieldName" was put on the value (resulting in a loss of information in case of stringification) We change it for a search param "comparison" of type null or Object. Forward-Port-Of: odoo/odoo#76163
Before this commit if the text selection was lost while the color palette was used, the color selection was not applied on anything. After this commit if the text selection was lost, it is restored to the last selection known in history before applying (or previewing) the color selection. task-2599771 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 g
Original PR description
Before this commit if the text selection was lost while the color palette was used, the color selection was not applied on anything. After this commit if the text selection was lost, it is restored to the last selection known in history before applying (or previewing) the color selection. task-2599771 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 Forward-Port-Of: odoo/odoo#76207
Modify search filters on the invoice views: Open -> Unpaid (not_paid & partial) Closed -> Paid (in_payment & paid) Overdue -> Overdue [FIX] journal kanban view "late invoices/bills" should not include due date = today Task 2635664 Forward-Port-Of: odoo/odoo#76283
Original PR description
Modify search filters on the invoice views: Open -> Unpaid (not_paid & partial) Closed -> Paid (in_payment & paid) Overdue -> Overdue [FIX] journal kanban view "late invoices/bills" should not include due date = today Task 2635664 Forward-Port-Of: odoo/odoo#76283
Since the recent time off B2B, time off validity has been moved from the time off type to the time off allocation. Meaning that a company may use the same time off type every year for their yearly time off. This means that the dashboard must display currently valid data. Remaining leaves and taken leaves will now be computed in function of that data aswell in the dashboard. This commit also fixes being able to take a leave if the current allocation does not permit it if an expired one w
Original PR description
Since the recent time off B2B, time off validity has been moved from the time off type to the time off allocation. Meaning that a company may use the same time off type every year for their yearly time off. This means that the dashboard must display currently valid data. Remaining leaves and taken leaves will now be computed in function of that data aswell in the dashboard. This commit also fixes being able to take a leave if the current allocation does not permit it if an expired one would have made it possible. TaskId-2636405 Forward-Port-Of: odoo/odoo#75981
It was previously decided that double clicking on a link shouldn't do anything other than opening the popover (which happen on single click). It was recently decided that we should actually open the right panel link tool on double click. Adding double click behavior, it was needed to refactor the way the popover is opening/closing -> We now use `focus` as trigger instead of `click`. Side effect, it will also fix 2641448 (part about double click on word) task-2618494 Forward-Port-Of
Original PR description
It was previously decided that double clicking on a link shouldn't do anything other than opening the popover (which happen on single click). It was recently decided that we should actually open the right panel link tool on double click. Adding double click behavior, it was needed to refactor the way the popover is opening/closing -> We now use `focus` as trigger instead of `click`. Side effect, it will also fix 2641448 (part about double click on word) task-2618494 Forward-Port-Of: odoo/odoo#76154
This fixes a small bug that caused a wrong redirection. It used the company id instead of the agent's. At the same time, this fix also disables the possibility to create a new partner from the redirect warning. Forward-Port-Of: odoo/enterprise#20752
Original PR description
This fixes a small bug that caused a wrong redirection. It used the company id instead of the agent's. At the same time, this fix also disables the possibility to create a new partner from the redirect warning. Forward-Port-Of: odoo/enterprise#20752
The search param "domains" of type Array was not satisfactory for several reasons: - useless for non reporting views - too close from the search param "domain" - a key "fieldName" was put on the value (resulting in a loss of information in case of stringification) In odoo/odoo@27daa0c, it has been changed for a search param "comparison" of type null or Object. Here we adapt the code of enterprise to that change. Forward-Port-Of: odoo/enterprise#20702
Original PR description
The search param "domains" of type Array was not satisfactory for several reasons: - useless for non reporting views - too close from the search param "domain" - a key "fieldName" was put on the value (resulting in a loss of information in case of stringification) In odoo/odoo@27daa0c, it has been changed for a search param "comparison" of type null or Object. Here we adapt the code of enterprise to that change. Forward-Port-Of: odoo/enterprise#20702
project_timesheet_forecast , planning_sale Currently, SO and Hours Recorded stat buttons arrive in different lines in the planning form view. It has been done in a single line. Task-ID : 2638500 Forward-Port-Of: odoo/enterprise#20759
Original PR description
project_timesheet_forecast , planning_sale Currently, SO and Hours Recorded stat buttons arrive in different lines in the planning form view. It has been done in a single line. Task-ID : 2638500 Forward-Port-Of: odoo/enterprise#20759
Before this commit, the total time displayed in the 'Forecast' stat button take in account the shifts are not planned yet. This commit adds a condition in the compute of total time to take into account only the planned shifts. task-2633229 Community PR: odoo/odoo#76167 closes #20701 Forward-Port-Of: odoo/enterprise#20701
Original PR description
Before this commit, the total time displayed in the 'Forecast' stat button take in account the shifts are not planned yet. This commit adds a condition in the compute of total time to take into account only the planned shifts. task-2633229 Community PR: odoo/odoo#76167 closes #20701 Forward-Port-Of: odoo/enterprise#20701
Change needed in order to take advantage of https://github.com/odoo/odoo/commit/e13f048a78b41d81602e868a3b0c7ded24ce992b opw-2628309 Forward-Port-Of: odoo/enterprise#20593
Original PR description
Change needed in order to take advantage of https://github.com/odoo/odoo/commit/e13f048a78b41d81602e868a3b0c7ded24ce992b opw-2628309 Forward-Port-Of: odoo/enterprise#20593
Steps to reproduce the bug: - Install helpdesk, timesheet, project, sales and helpdesk_timesheet - Create a new user and give him only "user" right for the Helpdesk and project app - Go to Helpdesk > configuration > Helpdesk teams - Choose the “Customer Care” helpdesk team and enable the “timesheet on ticket” option - select project “AGR - S00023” - Enable the “Timesheet Timer” and “Time Reinvoicing” option - Create a new ticket > Assign the newly created user and choose the “Cust
Original PR description
Steps to reproduce the bug:
- Install helpdesk, timesheet, project, sales and helpdesk_timesheet
- Create a new user and give him only "user" right for the Helpdesk and project app
- Go to Helpdesk > configuration > Helpdesk teams
- Choose the “Customer Care” helpdesk team and enable the “timesheet on ticket” option
- select project “AGR - S00023”
- Enable the “Timesheet Timer” and “Time Reinvoicing” option
- Create a new ticket > Assign the newly created user and choose the “Customer Care” helpdesk team
- log in with the new user and try to access the ticket
Problem:
An access error occurred, because the "sale_line_id" field must be computed in the _compute_sale_line_id,
but the user does not have access to "sale.order.line"
opw-2631064
Forward-Port-Of: odoo/enterprise#20705Forward-Port-Of: odoo/enterprise#20743
Original PR description
Forward-Port-Of: odoo/enterprise#20743