Daily updates from Odoo
Navigate
Branch
Friday, June 3, 2022
20 changes
Enhancements to existing features
Projects can now manage their own document workspace, tags, sharing, and portal access, making it easier for document-heavy teams to organize versions and collaborate with customers. Companies can define parent workspaces and templates so new project folders are created consistently with the right workflows and actions.
Original PR description
Purpose ======= The goal of this task is to address the use-case of law firms, architect's offices, design offices, insurance brokers, etc. that deal with a lot of documents for their projects.…
Purpose ======= The goal of this task is to address the use-case of law firms, architect's offices, design offices, insurance brokers, etc. that deal with a lot of documents for their projects. Typically, they handle multiple documents and work on different versions of them. Once those are validated, they are sent to the customer, who can then download, review, and sign the documents, as well as upload new ones. Previous behavior ================= Before this PR, when the feature was enabled, a workspace and default tags could be defined in the settings. Then, when an attachment was added to a task/project, or contained in a message in the chatter, it would be automatically added to the workspace as a document with the given default tags and linked to the respective project/task. Changes introduced ================== - Added a "Use Documents" setting on projects to enable the feature per project. - When enabling the feature globally, it will be enabled automatically on new and existing non-fsm projects. - Moved the "Documents Workspace" and "Default Tags" settings to the projects. - Only a workspace with the same company of no company can be selected. - Attachments are added as documents in the specified folder with the default tags set on the project and linked to their respective project/task. - If no workspace is selected when creating a project, a new one will be created automatically with the same name as the project. - When the feature is enabled globally, workspaces are also automatically created for all the projects without one. - Only tags from the project workspace or its parents can be selected. - Introduced a new company setting: "Parent Workspace". - If it is set, automatically created document workspaces for projects in this company will be children of this workspace. - All existing and new companies will have a default "Projects" parent workspace, which contains some tags, workflow rules and actions. - Introduced a new company setting: "Workspace Template". - If it is set, automatically created document workspaces for projects in this company will be a copy of this workspace. - Copies of the workspace include copies of its facets, tags, rules, actions, and child workspaces (recursively). - The copy will still have the same name as the project. - The workspace template cannot be a parent of the workspace set as parent workspace in the settings - Added a new link in the portal on tasks: "Documents". - This link is ony available if there are documents linked to the task that are also shared through a share link, whether by ids or by domain. - This page is pretty much the same as the one you get when opening a share link with multiple documents. - You can also upload documents if the folder of the project of the task is shared through a share link by domain (meaning it's either shared directly or by one of its ancestors with the "Include sub-folders" option enabled) - When viewing the documents linked to a project/task, only the relevant workspaces will be available in the search panel. - This includes the workspace of the project, and other workspaces containing documents linked to the task/project - Added a "Documents" button in the project kanban view, between the "Timesheets" and "Sales Order" ones. Technical details ================= documents --------- Most of the changes here are on `documents.folder`: - Added a `parent_path`, to make computations involving ancestors/descendants more efficient. - Added field `is_shared`, which computes if a folder is shared. - A folder is shared if there exists a `documents.share` link sharing the folder by domain, or sharing one its ancestor by domain with the `include_sub_folders` set to True. - Added a test to check that this field works as intended. - Added an override to the `copy` method, to allow duplicating folders for the "Workspace Template" setting. - The facets and tags are copied automatically - This method manually copies the workflow rules/actions linked to a folder to correctly set the tags/facets ids on the copies. - It also manually copies the workpace children recursively, because by default, only `copy_data` would be called on the children. - Added a test to check that this method works as intended. documents_project ----------------- - Added a new "Documents" link on tasks with shared documents in the portal - The shared documents page is an override of the page used for `documents.share` links, with most routes changed and share link/tokens dependencies removed - Added controllers for the new portal routes. - Access to most of those routes depends on having access to the corresponding task. - Added a `is_shared` field on `documents.document`, to compute if a document is shared. - A document is shared if its folder is shared (see above) or if there exists a `documents.share` link sharing the document by id. - This field is computationally expensive, which is why we decided to put it in `documents_project` and not `documents`. - However, it is not stored, as keeping it up to date would be expensive too, and it's only used in two places. - Added a test to check that this field works as intended - Added an override to `search_panel_select_range`in `documents.document` to only include folders relevant to a task/project. - Changed the search domain for the `_compute_attachment_ids` method in `project.task` to exclude attachments linked to a document. - Added the One2many `document_ids` in ` ir.attachments` to make this easier. - The field `attachment_ids` is only used in the portal to show attachments, the idea here is to reduce redundancy with the new shared documents page. - Added a method on `res.company` to automatically create default data. - It creates a default "Projects" workspace for the "Parent Workspace" setting, as well as defaults facets, tags, workflow rules and actions for that workspace. - Added constraints to ensure that the workspace of the "Parent Workspace" setting cannot be a child of the workspace of the "Workspace Template" setting. - Added constraints to ensure that a workspace is not linked to a project in a different company. - Added constraints to ensure that the default tags on a project cannot be linked to a folder different than that of the project. - Added tests to check that the "Parent Workspace" and "Workspace Template" settings work as intended documents_fsm ------------- New module, its sole purpose is to not automatically enable the documents feature on fsm project, and automatically enable/disable it when toggling the fsm status of a project. documents_project_sign ---------------------- New module, its sole purpose is to add a "Sign" workflow action on the parent workspace of all new and existing companies. ----- Related: https://github.com/odoo/odoo/pull/92044 Related: https://github.com/odoo/upgrade/pull/3557 Task-2802803
The Belgian payroll departure notice wizard now decides when to show the notice respect field based on the calculated notice period instead of fixed departure reason codes. This makes the process more accurate and easier to maintain for HR payroll users.
Original PR description
In belgian l10n payroll the departure notice wizard currently hides the notice_respect field using the hard-coded departure_reason_codes. This commit uses the computed value of weeks/months of notice to hide/show the field. task-2837430
This update adapts payroll and Studio-related tests to recent changes in Odoo's report and page rendering engine. It helps keep reports, payroll documents, and Studio editing reliable while supporting improved rendering performance through newer caching behavior.
Original PR description
related with: * https://github.com/odoo/odoo/pull/85110 * https://github.com/odoo/odoo/pull/88276
Point of Sale shop configuration is now managed from Odoo's General Settings, making administration more consistent and limiting changes to users with settings access. Several common options are enabled by default or always active, reducing setup complexity for daily store operations.
Original PR description
1. Each point of sale should now be configured in the general settings, meaning, only users with settings access can configure the shops. But some fields were still exposed to normal users like the authorized employees but the number of these fields is very limited. 2. `Settings` buttons from the dashboard (kanban) view of the shops is renamed to `Edit`. 3. `Invalidate Cache` button is moved to the dashboard (kanban) view of the shops, accessible besides the `Edit` button. 4. Limited products and partners loading are now active by default. Still configurable in the Technical Section which is only visible in debug mode. 5. Customer notes, product configurator, category pictures and open product info are removed and they are now always active. TASK-ID: 2753430
Manufacturing teams can now plan work orders in parallel or with custom dependencies instead of only one after another. The update also improves Gantt visibility with progress and timing details, and supports work center capacity that varies by product for more accurate production planning.
The journal audit report is easier to read and navigate, with clearer tax sections and narrower tables. Users can now click taxes or use audit buttons to quickly review related journal entries grouped by the relevant tax information.
Original PR description
Improve the tax report section of the journal audit by adding a
background color to it, as well as reducing the width of the tables.
Ease the navigation from the journal audit report by adding three
new actions:
- Taxes in the tax applied section can be clicked to audit them
- The tax applied and the impacted tax grid sections now have an
audit button to open a group-by view of journal items grouped
appropriately according to the information we need.The appraisal form now keeps both feedback fields visible throughout the process, reducing confusion for employees and managers. When a manager or appraisal manager force-publishes employee feedback, the system records a note in the chatter for better transparency.
Original PR description
Users were getting confused with the disappearing feedback fields depending on the stage of the appraisal. Now the 2 feedback fields are always displayed and a message is logged in the chatter when the manager / appraisal manager force-publish the employee's feedback. TaskID: 2844135
The Documents spreadsheet component was updated to include recent fixes from the spreadsheet engine. This improves chart refresh behavior after data changes and adjusts an icon used in conditional formatting, helping spreadsheet reports stay accurate and clearer for users.
Original PR description
### Contains the following commits: https://github.com/odoo/o-spreadsheet/commit/088698e0 [FIX] conditional format: change third icon https://github.com/odoo/o-spreadsheet/commit/30be60be [FIX] evaluation_chart: mark charts as outdated for all commands which invalidate evaluation
The Sign app now starts users in automatic signing mode by default. This makes the signing process faster and reduces extra steps for people completing documents.
Original PR description
In order to make the process of signing faster, automatic mode should be the default one. task-2862209
Resolved issues and error corrections
Pivot side panels in Documents Spreadsheet now display readable dimension names instead of internal technical labels. This makes spreadsheet pivot information easier for users to understand and reduces confusion when reviewing reports.
Original PR description
Since 65d772de9af2a92967b26946706cf26503d445af, it's the technical name of the dimensions that were displayed in the side panel of the pivots instead of a friendly name. Task-id 2842860
Code cleanup and technical improvements
The Amazon sales integration has been reorganized by merging the newer SP-API module into the main Amazon sales module. This simplifies maintenance and keeps Amazon marketplace functionality in one place without introducing a separate business workflow.
Original PR description
Following commit https://github.com/odoo/enterprise/commit/aa00c474a5ee237d6486251c6a7def5ac1092605, the module `sale_amazon_spapi` was added alongside the module `sale_amazon`. In master, we can now merge the two modules together with this commit. task-2694222 task-2823194 See also: - https://github.com/odoo/upgrade/pull/3559 - https://github.com/odoo/documentation/pull/2156
Miscellaneous changes
This domain wasn't matching anything due to a missing '|'. Forward-Port-Of: odoo/enterprise#28018 Forward-Port-Of: odoo/enterprise#27156
Original PR description
This domain wasn't matching anything due to a missing '|'. Forward-Port-Of: odoo/enterprise#28018 Forward-Port-Of: odoo/enterprise#27156
Steps to reproduce: (on a new database without demp) - create an invoice of 1000$ for every month from November 2021 to April 2022 - In reporting > Balance Sheet - Select "End Of Last Month" Issue: The "Previous Year Unallocated Earnings" will be incorrect != 2000 (1000 December + 1000 November) Cause: The issue is not from "Previous Year Unallocated Earnings" per se but from from one of its subcomponent: the "Current Year Earnings" ``` PREV_YEAR_EARNINGS = -sum
Original PR description
Steps to reproduce: (on a new database without demp) - create an invoice of 1000$ for every month from November 2021 to April 2022 - In reporting > Balance Sheet - Select "End Of Last Month" Issue:…
Steps to reproduce:
(on a new database without demp)
- create an invoice of 1000$ for every month from November 2021 to April 2022
- In reporting > Balance Sheet
- Select "End Of Last Month"
Issue:
The "Previous Year Unallocated Earnings" will be incorrect != 2000 (1000 December + 1000 November)
Cause:
The issue is not from "Previous Year Unallocated Earnings" per se but from from one of its subcomponent: the "Current Year Earnings"
```
PREV_YEAR_EARNINGS =
-sum : from_beginning
+ ALLOCATED_EARNINGS : from_beginning
- CURR_YEAR_EARNINGS_ALLOC : from_fiscalyear
- CURR_YEAR_EARNINGS_PNL : normal -> Problematic one
[OPINC + OIN - COS - EXP - DEP]
```
The CURR_YEAR_EARNINGS_PNL or NEP (Net Profit) is computed for the month of April 2022 (04/01/22 - 04/30/222) instead of from the beginning of the fiscal year (01/01/22-30/04/22).
This happens only when you select a "Last of [month quarter]" option (quarter if in the third or fourth one). If you select "Today" or a "Custom End Date", it won't cause the issue.
Solution:
Force a "custom" option value to compute it correctly
opw-2821529
Forward-Port-Of: odoo/enterprise#28022
Forward-Port-Of: odoo/enterprise#27910…81.10 Purpose ======= The company car exemption is declared in the 281.10 sheet. No need to bring mystic hidden computation on the monthly payslips, as the difference will be paid to the employee at the end of the 'exercice'. This was bringing confusion to employees trying to understand their payslips, and this was complex for HR people too when they had to validate the whole batch. This commit will slightly increase the withholding taxes on the monthly payslip, but as this is
Original PR description
…81.10 Purpose ======= The company car exemption is declared in the 281.10 sheet. No need to bring mystic hidden computation on the monthly payslips, as the difference will be paid to the employee at the end of the 'exercice'. This was bringing confusion to employees trying to understand their payslips, and this was complex for HR people too when they had to validate the whole batch. This commit will slightly increase the withholding taxes on the monthly payslip, but as this is a tax advance, the employees will recover this money at the end of the year. TaskID: 2869755 Forward-Port-Of: odoo/enterprise#27984
Forward-Port-Of: odoo/enterprise#27880
Original PR description
Forward-Port-Of: odoo/enterprise#27880
…ilters - Insert a pivot in a spreadsheet - Create a relational filter - Try to change the value in the filter => changes are not reflected Since 4ccd405 Forward-Port-Of: odoo/enterprise#27990
Original PR description
…ilters - Insert a pivot in a spreadsheet - Create a relational filter - Try to change the value in the filter => changes are not reflected Since 4ccd405 Forward-Port-Of: odoo/enterprise#27990
Line account_financial_report_line_it_sp_PASS_A_IX's domain wasn't matching anything, due to a missing or operator. Forward-Port-Of: odoo/enterprise#27198 Forward-Port-Of: odoo/enterprise#27132
Original PR description
Line account_financial_report_line_it_sp_PASS_A_IX's domain wasn't matching anything, due to a missing or operator. Forward-Port-Of: odoo/enterprise#27198 Forward-Port-Of: odoo/enterprise#27132
Before this commit, template `dsfinvk_cash_point_closing_template` used `full_product_name` for the `text` field for order lines. When a sale order is imported in the POS session, this field includes the product description as the full product name by default. This description might include line breaks (i.e. `\n`) which causes an error in `ast.literal_eval` when processing the POS session. It might also be too long which doesn't comply with Fiskaly API (which specifies it to be 255 charac
Original PR description
Before this commit, template `dsfinvk_cash_point_closing_template` used `full_product_name` for the `text` field for order lines. When a sale order is imported in the POS session, this field includes the product description as the full product name by default. This description might include line breaks (i.e. `\n`) which causes an error in `ast.literal_eval` when processing the POS session. It might also be too long which doesn't comply with Fiskaly API (which specifies it to be 255 characters or less) To fix these problems, we can use product name as the text field for order lines in this report (the same way it was done in v13) opw-2817707 Forward-Port-Of: odoo/enterprise#27938
**Steps to follow** - Go to Social Marketing > Post > Calendar view - Add a new post by clicking on a day block - Set a message and change the scheduled date - Save the record - Go back to the calendar view by using the breadcrumbs -> The displayed date is not the expected one **Cause of the issue** `default_calendar_date` is set by the calendar view when clicking on a day block. The orm sees that the `calendar_date` has a default value and thus the `_compute
Original PR description
**Steps to follow** - Go to Social Marketing > Post > Calendar view - Add a new post by clicking on a day block - Set a message and change the scheduled date - Save the record - Go back to the calendar view by using the breadcrumbs -> The displayed date is not the expected one **Cause of the issue** `default_calendar_date` is set by the calendar view when clicking on a day block. The orm sees that the `calendar_date` has a default value and thus the `_compute_calendar_date` method is not called. **Solution** Set the `calendar_date` manually in the create method, before `default_get` is called opw-2857947 Forward-Port-Of: odoo/enterprise#27986 Forward-Port-Of: odoo/enterprise#27885
Prior to this commit: - When they were more than one leave in the following week, only the last leave was removed from the availabilities which lead to strange behaviors. After this commit: - The balanced assignation will correctly take into account the employees' leaves. task-2870985 Forward-Port-Of: odoo/enterprise#28000
Original PR description
Prior to this commit: - When they were more than one leave in the following week, only the last leave was removed from the availabilities which lead to strange behaviors. After this commit: - The balanced assignation will correctly take into account the employees' leaves. task-2870985 Forward-Port-Of: odoo/enterprise#28000