Daily updates from Odoo
Thursday, March 21, 2024
7 changes · saas-17.1
Resolved issues and error corrections
This update fixes a bug that prevented invoices with specific UBL-CII tax formats (ubl_bis3 and nlcius_1) from confirming correctly. The fix ensures the system correctly processes these invoices, allowing users to complete the confirmation process without errors. This improves the reliability of electronic invoicing.
Original PR description
**Current behavior:** Creating a fixed tax with the edi formats ubl_bis3 and nlcius_1 then creating an invoice with this tax tied to a product will cause a traceback when a user tries to confirm the…
**Current behavior:**
Creating a fixed tax with the edi formats ubl_bis3 and nlcius_1
then creating an invoice with this tax tied to a product will
cause a traceback when a user tries to confirm the invoice.
**Expected behavior:**
The invoice will post as any other might.
**Steps to reproduce:**
1. Create a NL company with l10n_nl_edi accounting
2. Create a tax with the following field values:
*tax computation: fixed*
*affect base of subsequent taxes: True*
*base affected by previous taxes: True*
3. In the customer invoices journal for the created company,
go to the 'Advanced Settings' notebook tab and enable the
NLCIUS and Peppol options under 'Electronic Invoicing'
4. Create a new invoice with some product and attach the newly
created tax to it, then try to confirm the invoice to see
the traceback
**Cause of the issue:**
The edi format tags invoke different instances of the
get_invoice_line_allowance_vals_list() method. This method
returns a dict list where the dicts only sometimes contain the
key 'allowance_charge_reason_code'. A subsequent expression
expects this key in the dict which can cause a KeyError.
**Fix:**
Check instead for a 'charge_indicator' key, which is present in
both the ubl_bis3 and nlcius_1 val dicts, allowing the correct
total to be summed and reflected in the EDI document output.
opw-3680527
Forward-Port-Of: odoo/odoo#157221
Forward-Port-Of: odoo/odoo#152229This fix ensures that new projects correctly utilize the selected analytic plan. Previously, the system defaulted to a 'Projects' plan regardless of user settings. This update resolves a discrepancy in how the analytic plan is applied, improving the accuracy of timesheet and project accounting.
Original PR description
Currently, the `plan_id` used to create analytic accounts is not the one set in the settings. Steps to reproduce: ------------------- * Go to the **Settings** * Enable developper mode * Select **User…
Currently, the `plan_id` used to create analytic accounts is not the one set in the settings. Steps to reproduce: ------------------- * Go to the **Settings** * Enable developper mode * Select **User & Companies** > **Groups** * Select `Technical/Analytic Accounting` * Add user * Go to the **Project** app * Select **Configuration** > **Settings** * Under **Time Management**, enable Timesheets * Under **Analytics** > **Analytic Plan**, select Projects * Create a new project * Go into the settings of the project * Under the **Settings** tab, select the internal link for the **Analytic Account** > **Observation**: The Plan is set to Projects * Go to **Conffiguration** > **Settings** * Under **Analytics** > **Analytic Plan**, change Projects to Departments * Create a new project * Go into the settings of the project * Under the **Settings** tab, select the internal link for the **Analytic Account** > **Observation**: The Plan is still set to Projects Why the fix: ------------ When creating, an analytic account, the plan is computed with `_get_all_plans()`. https://github.com/odoo/odoo/blob/e365e22485dc45f1cbe87ae93395b022a4724a3c/addons/project/models/project_project.py#L894-L903 Inside `__get_all_plans()` the plan is computed as follows: https://github.com/odoo/odoo/blob/e365e22485dc45f1cbe87ae93395b022a4724a3c/addons/analytic/models/analytic_plan.py#L106-L107 However, the setting that the user changes in the frontend corresponds to `analytic.analytic_plan_projects`. https://github.com/odoo/odoo/blob/e365e22485dc45f1cbe87ae93395b022a4724a3c/addons/project/models/res_config_settings.py#L18-L22 This seeting is not company-related. It can be used on projects even if they have a `company_id` set to false. We fallback on `_get_all_plans()` if the user did not specifically choose a plan in the settings. opw-3751661 Forward-Port-Of: odoo/odoo#157247
This update removes an automatically installed module, `partner_autocomplete`, from the project module. This fix addresses a previous issue where shared projects with portal users would encounter internal server errors due to missing module files. The change ensures smoother operation for shared projects.
Original PR description
Issue: ------ The `partner_autocomplete` module is an automatically installed module. This module is not included in the dependencies and can therefore be uninstalled. If `partner_autocomplete` is uninstalled and we go to a shared project with a portal user for example, we get an internal server error, as we don't have access to the `partner_autocomplete` files. Solution: --------- Remove the `partner_autocomplete` files from the manifest file of the `project` module. Note: If the widget is not found (in the very rare case of uninstalling the `partner_autocomplete` module), we will use the default widget (and create a log). opw-3774575 Forward-Port-Of: odoo/odoo#157865 Forward-Port-Of: odoo/odoo#157411
Documentation and clarification updates
This pull request formally records the signing of a legal agreement (CLA) by Hari1119. This ensures compliance with Odoo's open-source licensing and strengthens our commitment to the Odoo community. The change involves adding a documentation file detailing this agreement.
Original PR description
Signed a individual CLA Forward-Port-Of: odoo/odoo#156234
This pull request updates the documentation to include a legal agreement (CLA) signature for a contribution by ZhongduoduoQAQ. This ensures the code adheres to Odoo's licensing terms and allows for proper attribution. It’s a standard process for accepting contributions into the Odoo project.
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#157957
This pull request formally signs Odoo's Contributor License Agreement (CLA), ensuring compliance with our open-source licensing. This update is a standard legal step for contributors and doesn't impact Odoo's functionality. It strengthens our commitment to the Odoo community.
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#157960
This pull request formally records that santiagopim has signed the Odoo Contributor License Agreement (CLA). This is a necessary step for santiagopim to contribute code to the Odoo project, ensuring compliance with our licensing terms. With the CLA now signed, santiagopim can begin contributing to Odoo.
Original PR description
Description of the issue/feature this PR addresses: Sign CLA agreement for santiagopim Current behavior before PR: No CLA signed Desired behavior after PR is merged: CLA signed --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#157955