Daily updates from Odoo
Navigate
Branch
Friday, December 2, 2022
16 changes
New functionality added to Odoo
This update adds and extends worksheet/reporting capabilities across quality checks and field service workflows. Business teams can capture, share, and print more structured operational information, improving consistency for on-site service and quality processes.
Enhancements to existing features
Odoo’s settings screens have been reorganized using a common structure for applications, groups, and individual settings. This makes settings more consistent, easier to browse, and easier to maintain across many business apps.
Original PR description
The aim of this commit is to simplify and standardize the settings archs. To do this, a small DSL exclusively for the settings was created. This new DSL introduces 3 tags: `app`, `block` and…
The aim of this commit is to simplify and standardize the settings archs.
To do this, a small DSL exclusively for the settings was created. This new DSL introduces 3 tags: `app`, `block` and `setting`.
## `app`
The `app` tag is used to declare the application on the settings view. It creates an entry with its logo on the sidebar of the view. It also acts as delimiter when searching.
### Syntax
```xml
<app string="CRM" name="crm">
...
</app>
```
### Parameters
- `string` : The "display" name of the application.
- `name` : The technical name of the application (the name of the module).
- `logo` *optional* : The relative path to the logo. If not set, the logo is created using the `name` parameter : `/{name}/static/description/icon.png`.
## `block`
The `block` tag is used to declare a group of settings. This group can have a title and a description/help.
### Syntax
```xml
<block title="Title of group Bar">
...
</block>
```
### Parameters
- `title` *optional* : The title of the block of settings (the old h2), you can perform research on its text.
- `help` *optional* : The description/help of the block of settings (the old h3), you can perform research on its text.
## `setting`
The `setting` tag is used to declare the setting itself. The first field in the setting is used as the main field (optional). This field is placed on the left panel (if it's a boolean field) or on the top of the right panel (otherwise). The field is also used to create the setting label if a `string` is not defined. The `setting` tag can also contain more elements (e.g. html), all of these elements are rendered in the right panel.
### Syntax
```xml
<setting string="this is bar">
<field name="bar"/>
...More elements
</setting>
```
### Parameters
- `type` *optional* : By default, a setting is visually separated on two panels (left and right), and is used to edit a given field. By defining `type='header'`, a special kind of setting is rendered instead. This setting is used to modify the scope of the other settings. For example, on the website application, this setting is used to indicate to which website the other settings apply. The header setting is visually represented as a yellow banner on the top of the screen.
- `string` *optional* : The text used as label of the setting. If it's not defined, the first field is used as label.
- `title` *optional* : The text used as tooltip.
- `help` *optional* : The help/description of the setting. This text is displayed just below the setting label (with classname `text-muted`).
- `company_specific` *optional* : If this attribute is set to "1" an icon is displayed next to the setting label to explicit that this setting is company-specific.
- `documentation` *optional* : If this attribute is set, an icon is added next to the setting label, this icon is a link to the documentation. Note that you can use relative or absolute path. The relative path is relative to `https://www.odoo.com/documentation/server_version`, so it's not necessary to hard-code the server version on the arch anymore.
## Example
```xml
<app string="CRM" name="crm">
<setting type="header" string="Foo">
<field name="foo" title="Foo?."/>
<button name="nameAction" type="object" string="Button"/>
</setting>
<block title="Title of group Bar">
<setting help="this is bar" documentation="/applications/technical/web/settings/this_is_a_test.html">
<field name="bar"/>
</setting>
<setting string="This is Big BAR" company_specific="1">
<field name="bar"/>
</setting>
</block>
<block title="Title of group Foo">
<setting string="Personalize setting" help="this is full personalize setting">
<div>This is a different setting</div>
</setting>
</block>
</app>
```
More examples can be found in the code base.
## Example of the simplification of the code
```diff
- <div class="app_settings_block" data-string="CRM" string="CRM" data-key="crm">
+ <app string="CRM" name="crm">
- <div class="row app_settings_header my-0 ms-0 mw-100 bg-warning bg-opacity-25">
- <div class="col-xs-12 col-md-6 ms-0 o_setting_box">
- <div class="o_setting_right_pane border-start-0 ms-0 ps-0">
- <div class="content-group">
- <div class="row flex-row flex-nowrap mt8 align-items-center">
- <label class="col ps-0 text-nowrap" string="Foo" for="foo"/>
- <field name="foo" title="Foo?."/>
- <button name="nameAction" type="object" string="Button" class="col-auto btn-link ms-2 text-nowrap" style="line-height: 0.5;"/>
- </div>
- </div>
- </div>
- </div>
- </div>
+ <setting type="header" string="Foo">
+ <field name="foo" title="Foo?."/>
+ <button name="nameAction" type="object" string="Button"/>
+ </setting>
- <h2>Title of group Bar</h2>
- <div class="col-xs-12 row o_settings_container">
+ <block title="Title of group Bar">
- <div class="col-xs-12 col-lg-6 o_setting_box">
- <div class="o_setting_left_pane">
- <field name="bar"/>
- </div>
- <div class="o_setting_right_pane">
- <a href="https://www.odoo.com/documentation/master/applications/technical/web/settings/this_is_a_test.html" title="Documentation" class="o_doc_link" target="_blank"/>
- <div class="text-muted">
- this is bar
- </div>
- </div>
- </div>
+ <setting help="this is bar" documentation="/applications/technical/web/settings/this_is_a_test.html">
+ <field name="bar"/>
+ </setting>
- <div class="col-xs-12 col-lg-6 o_setting_box">
- <div class="o_setting_left_pane">
- <field name="bar"/>
- </div>
- <div class="o_setting_right_pane">
- <label for="bar" string="This is Big BAR" />
- <span class="fa fa-lg fa-building-o" title="Values set here are company-specific." aria-label="Values set here are company-specific." groups="base.group_multi_company" role="img"/>
- </div>
- </div>
+ <setting string="This is Big BAR" company_specific="1">
+ <field name="bar"/>
+ </setting>
- </div>
+ </block>
- <h2>Title of group Foo</h2>
- <div class="col-xs-12 row o_settings_container">
- <div class="col-xs-12 col-lg-6 o_setting_box">
- <div class="o_setting_left_pane">
- </div>
- <div class="o_setting_right_pane">
- <span class="o_form_label">Personalize setting</span>
- <div class="text-muted">
- this is full personalize setting
- </div>
- <div>This is a different setting</div>
- </div>
- </div>
- </div>
+ <block title="Title of group Foo">
+ <setting string="Personalize setting" help="this is full personalize setting">
+ <div>This is a different setting</div>
+ </setting>
+ </block>
- </div>
+ </app>
```
This commit also promotes the use of the well-known tag `group` in settings archs. For instance:
```xml
<div class="content-group">
<div class="row mt16">
<label for="bar" class="col-lg-4 o_light_label"/>
<field name="bar" required="True"/>
</div>
<div class="row">
<label for="foo" class="col-lg-4 o_light_label"/>
<field name="foo"/>
</div>
</div>
```
becomes
```xml
<group>
<field name="bar" required="True"/>
<field name="foo"/>
</group>
```
task-id: 3081367
Co-authored-by: "Michael Mattiello (mcm)" <mcm@odoo.com>
Community : https://github.com/odoo/odoo/pull/106425This update simplifies the internal structure behind the PLM bill of materials overview by making each process request the information it needs directly. It reduces reliance on hidden workarounds, making future maintenance safer and easier without changing the user-facing experience.
Original PR description
Since fixes done on the bom overview in odoo/enterprise#33613 had to be done in a released version, no method signature changes could be donce, hence the use of excessive context keys to bypass it. Changes the signatures so that future work is done on better grounds, and so that each method explicitely asks for what parameters it needs to do its work. Related to odoo/odoo#107006
This update tightens how form and kanban screens prepare the information they use when displaying records. It helps keep several business apps consistent and reduces the risk of display issues after related platform changes.
Cancelled manufacturing orders can now be returned to draft, giving teams a way to correct or reuse orders instead of recreating them. This also supports changing the product on a confirmed manufacturing order by moving it back to draft, updating it, and confirming it again.
Original PR description
After this commit, we can now reset a cancelled MO to draft. We can also change the product_id of a confirmed MO. The way we do it is first reset it to draft, then we make the change, then confirm it again. Task 2278147 COM PR odoo/odoo#55837
Resolved issues and error corrections
This update fixes two localization issues found during nightly checks. It restores installation reliability for the Peru invoicing module and corrects the Romania reporting setup to avoid future access-rights warnings.
Original PR description
Fixes two recent issues in l10n that appeared on the nightly
This update restores a broken Peruvian invoice report customization after a related platform change. It helps ensure Peruvian electronic invoice documents continue to render the expected information correctly.
Original PR description
Following changes in odoo/odoo@3f38d903e9f4b39c6d4638cc4e745a9bb35ac390, a Peruvian xpath does not work anymore. This commit fixes this by updating the Peruvian xpath to follow the new changes.
This fix prepares VAT and VIES validation to work with tax units, ensuring group tax reporting can use the same checks as individual companies. It matters because businesses using tax units should get more reliable compliance validation in accounting reports.
Original PR description
Since the VIES check is in base_vat, account.tax.unit is moved to account
A broken accounting walkthrough was corrected after invoice status labels changed for draft bills. This keeps internal validation aligned with the current invoice view and helps prevent false failures during quality checks.
Original PR description
Following the community PR that has removed the tag payment state when the move is not posted, the tour was broken. It checked if a payment state was present in the view for a draft bill. This PR correct that by checking the state instead of the payment state Task-id: 3085423
Code cleanup and technical improvements
This update modernizes internal code formatting across appointment scheduling, calendar, helpdesk, and social media features. It improves maintainability and may slightly improve performance without changing user-facing behavior.
Original PR description
* = appointment, calendar, social, social_facebook, social_twitter To increase readability and performance, use f-strings where appropriate (multiple concatenation +- formatting). Task-2977548 See odoo/odoo#99811
The Master Production Schedule interface has been rebuilt using Odoo's newer web technology. This should make the planning screen easier to maintain and better aligned with the rest of Odoo, while preserving its business purpose for production planning.
Original PR description
Owlify mrp_mps
Miscellaneous changes
In the following situation: - Create a bank statement, reconcile using manual operations (e.g. Skonto-vk-19%) - Two amls are created: the base and the tax - The base does not have the full amount as it's not an invoice line - Only the aml with base amount is exported in DATEV csv export. The tax amount is missing. The only way to get the full amount is to use `compute_all` on every aml. Forward-Port-Of: odoo/enterprise#34541 Forward-Port-Of: odoo/enterprise#33611
Original PR description
In the following situation: - Create a bank statement, reconcile using manual operations (e.g. Skonto-vk-19%) - Two amls are created: the base and the tax - The base does not have the full amount as it's not an invoice line - Only the aml with base amount is exported in DATEV csv export. The tax amount is missing. The only way to get the full amount is to use `compute_all` on every aml. Forward-Port-Of: odoo/enterprise#34541 Forward-Port-Of: odoo/enterprise#33611
Before this commit, the recurring_monthly value changed over time. MRR was null when start_date <= today <= end_date and if the order was in progress. Unfortunately, the compute dependencies were not correct and a renewal order confirmed and invoice before the start_date would never have a non null MRR. This commits change the logic to make sure the MRR is only computed based on stored fields: 'stage_category', 'state', 'is_subscription', 'amount_untaxed'. recurring_live was not updat
Original PR description
Before this commit, the recurring_monthly value changed over time. MRR was null when start_date <= today <= end_date and if the order was in progress. Unfortunately, the compute dependencies were not correct and a renewal order confirmed and invoice before the start_date would never have a non null MRR. This commits change the logic to make sure the MRR is only computed based on stored fields: 'stage_category', 'state', 'is_subscription', 'amount_untaxed'. recurring_live was not updated when a renewal was started. We update the code to make sure a renewal become alive when the parent is closed. The _mail_track method is modified to take into account this change and make sure that the behavior of the logs is not modified. Forward-Port-Of: odoo/enterprise#34405 Forward-Port-Of: odoo/enterprise#33716
Before, we only displayed the assets that have a posted move in the period. That filter on moves should only be in the depreciations applied, not on the assets themselves. [opw-3039478](https://www.odoo.com/web#id=3039478&model=project.task) Forward-Port-Of: odoo/enterprise#33583
Original PR description
Before, we only displayed the assets that have a posted move in the period. That filter on moves should only be in the depreciations applied, not on the assets themselves. [opw-3039478](https://www.odoo.com/web#id=3039478&model=project.task) Forward-Port-Of: odoo/enterprise#33583
Before this commit, studio hooks (which are dropzones for new structures) in notebooks and in outergroups where not correctly added. Some were misplaced, others had wrong data on them. After this commit, they are correctly added with the right information Forward-Port-Of: odoo/enterprise#34393
Original PR description
Before this commit, studio hooks (which are dropzones for new structures) in notebooks and in outergroups where not correctly added. Some were misplaced, others had wrong data on them. After this commit, they are correctly added with the right information Forward-Port-Of: odoo/enterprise#34393
[IMP] sale_subscription: change upsell button position Forward-Port-Of: odoo/enterprise#34459
Original PR description
[IMP] sale_subscription: change upsell button position Forward-Port-Of: odoo/enterprise#34459