Daily updates from Odoo
Navigate
Branch
Friday, December 5, 2025
237 changes
8 changes
Resolved issues and error corrections
This update ensures Odoo automatically updates remaining modules in the database, regardless of how Odoo is started. Previously, this only worked when Odoo was launched with specific command-line arguments. This change adds a configuration setting to trigger the automatic update process, improving database consistency and stability.
Original PR description
In https://github.com/odoo/odoo/pull/216025, we force auto upgrade of modules remaining in the database when `preload_registries` is called. However, this strategy doesn't work if Odoo is not started with the `-d` argument, because `preload_registries` is only called for databases specified in the `-d` argument. This commit fixes the issue by adding a special record in `ir_config_parameter` with key `base.partially_updated_database` to indicate that the next time `Registry.new` is called, it should force auto upgrade of modules remaining in the database. 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#238748 Forward-Port-Of: odoo/odoo#238320
This update fixes an issue where the 'Journal Items' link in the General Ledger Report was incorrectly displaying items not associated with the selected account group. The fix ensures that users see the correct journal items linked to their account groups, improving report accuracy and data reliability.
Original PR description
Repro steps: 1. Create account groups 2. Go to general ledger report 3. Click on 'Journal Items' of one of the account groups lines Problem: The journal items shown don't belong to the account group that it should belong to. Fix: This commit fixes this issue by adding the correct action_domain of account_id.group_id. opw-5180867 Forward-Port-Of: odoo/enterprise#100191
This update resolves a bug where the aged receivable report was not displaying correct data for invoices without a due date. The fix ensures the report accurately reflects outstanding balances by aligning the data source used in the report with the invoice's maturity date. This improves report accuracy and data visibility.
Original PR description
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this…
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this entry <img width="1599" height="238" alt="image" src="https://github.com/user-attachments/assets/010f97f4-0d50-4e5a-9366-ae67d17e2bb7" /> Observation: - on clicking the entry, when redirected to list view, there are `0` records. Issue: - The query which is used to display data on report uses `COALESCE(account_move_line.date_maturity, account_move_line.date)` https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L222-L226 - while the method `_build_domain_from_period` uses only `date_maturity` in domain redirecting to list view - This creates inconsistencies between two. https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L383-L394 opw-5237298 Forward-Port-Of: odoo/enterprise#99883
This update resolves an error that occurred when creating time off requests, specifically when a start date was removed and the employee was changed. The fix ensures the system only checks for past dates when a start date is provided, preventing the 'bool' object has no attribute 'date' error.
Original PR description
Currently, an error occurs when creating a time off request for an employee. Steps to Reproduce: - Install the `hr_holiday` module. - Go to `Management > Time Off`. - Create a `new time off` and…
Currently, an error occurs when creating a time off request for an employee. Steps to Reproduce: - Install the `hr_holiday` module. - Go to `Management > Time Off`. - Create a `new time off` and `remove the start date`. - Now `change the employee`. `AttributeError: 'bool' object has no attribute 'date'` This error occurs when creating a time off request for an employee. If the start date is removed and then the employee is changed, the compute method [1] runs to determine whether the time off can be approved and to update the states [2]. During this process, the system checks whether the time off date is in the past, and since the start date is missing, it results in the error [3]. This commit ensures that the system only checks whether the time off is in the past when a start date is provided. [1]- https://github.com/odoo/odoo/blob/aa53689d3c593a8a41479c51edc2b01e3c284f96/addons/hr_holidays/models/hr_leave.py#L594-L597 [2]- https://github.com/odoo/odoo/blob/aa53689d3c593a8a41479c51edc2b01e3c284f96/addons/hr_holidays/models/hr_leave.py#L1279 [3]- https://github.com/odoo/odoo/blob/aa53689d3c593a8a41479c51edc2b01e3c284f96/addons/hr_holidays/models/hr_leave.py#L1237 No Task ID --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#238281
This update fixes an issue where application refusal emails weren't sent promptly, relying solely on a delayed queue. Now, emails are sent immediately upon refusal and a log entry is created in the applicant's chat, improving communication and transparency in the recruitment process. This ensures candidates receive timely updates.
Original PR description
**Steps to reproduce:** 1. Install `hr_recruitment` 2. Create a job position and then an application with an email address for it 3. Refuse the application with "Send Email" enabled **Issue:** 1. Refusal emails are not sent right away; they are only queued and delivered later by the scheduled action. 2. No log entry is created in the chatter. **Cause:** - During the recruitment refusal flow refactoring, mail handling was not properly adapted. The code prepared the refusal mail but never explicitly sent it, resulting in it being added to the queue only. **Solution:** - Ensure refusal mails are sent immediately instead of waiting for the queue. Log the refusal mail in the applicant’s chatter at the time of refusal. opw-5058709
This update ensures that bills automatically received through the PEPPOL network are immediately posted to the system, rather than remaining in a draft state. This streamlines the billing process and improves efficiency for partners using the PEPPOL network for invoice receipt.
Original PR description
Currently, even if a partner has auto-post bills enabled, the incoming bills stay in the draft state. This change addresses that issue. Task-5373302 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#238473
This update fixes an issue where tax calculations weren't automatically applied during Express Checkout using Stripe. Now, the correct tax position (based on the user's address) is applied immediately, eliminating the need for a page reload. This ensures accurate pricing and tax calculations for eCommerce users.
Original PR description
## Issue: When a fiscal position should apply based on the address provided during Express Checkout, it was not applied automatically The correct fiscal position only appeared after reloading the…
## Issue: When a fiscal position should apply based on the address provided during Express Checkout, it was not applied automatically The correct fiscal position only appeared after reloading the checkout page This issue affects public users using the eCommerce with Stripe Express Checkout ## Cause: The fiscal position was correctly determined during the `availableCarriers` computation, but it was not propagated to the payment request itself As a result, prices and taxes were only updated after a full page reload ## Steps to reproduce: - Configure Stripe with Express Checkout (e.g., Google Pay) - Create a fiscal position with automatic detection (Country = US, Tax mapping: 15% → 0%) - Create a product using the 15% tax - Go to the website shop and add the product to the cart - Use Express Checkout with a US address - Observe that the fiscal position is not applied unless the page is reloaded opw-5018238 Forward-Port-Of: odoo/odoo#238690 Forward-Port-Of: odoo/odoo#236832
This update corrects a technical issue in the Danish Nemhandel integration by ensuring that Denmark-specific document type checks are applied only to Danish partners. This prevents conflicts with standard Peppol processes and ensures consistent data flow, improving the reliability of the system.
Original PR description
Before: - The l10n_dk_nemhandel override of _check_document_type_support replaced the generic Peppol logic and did not accept process_type, causing errors when other localizations relied on the base method. After: - Aligned the method and applied the DK-specific logic only for Danish partners, falling back to the generic Peppol behavior otherwise. Impact: - Prevents unintended overrides towards standard Peppol flow. Forward-Port-Of: odoo/odoo#238543
17 changes
Enhancements to existing features
This update clarifies the labeling of a field used when making salary adjustments within the HR payroll module. The change ensures users understand exactly where this input is accessible, improving the overall user experience. This is a minor improvement focused on usability.
Original PR description
This change ensures the label accurately reflects where the field is accessible and providing better clarity for users when working with salary adjustments. Task: 5375187 Forward-Port-Of: odoo/enterprise#101065
Resolved issues and error corrections
This update resolves an issue where journal item links within the general ledger report were incorrectly associating items with the wrong account groups. The fix ensures that journal items are accurately linked to their respective account groups, improving the accuracy of financial reporting.
Original PR description
Repro steps: 1. Create account groups 2. Go to general ledger report 3. Click on 'Journal Items' of one of the account groups lines Problem: The journal items shown don't belong to the account group that it should belong to. Fix: This commit fixes this issue by adding the correct action_domain of account_id.group_id. opw-5180867 Forward-Port-Of: odoo/enterprise#100191
This update fixes an issue where debit notes created in the Uruguay localization were incorrectly assigned as e-invoices (type 111). The fix ensures debit notes automatically use the correct document type (113), streamlining invoice processing for Uruguayan customers. This improves data accuracy and compliance.
Original PR description
**Steps to reproduce:** * Install and activate the **Uruguayan Localization** for the company. * Create a contact located in Uruguay. * Create an invoice for this customer and set **Document Type =…
**Steps to reproduce:** * Install and activate the **Uruguayan Localization** for the company. * Create a contact located in Uruguay. * Create an invoice for this customer and set **Document Type = 111 (e-Invoice)**. * From the invoice's gear icon, create a **Debit Note**. **Observed behavior:** * The debit note is automatically assigned **Document Type 111 (e-Invoice)**, even though it should use **113 (e-Invoice Debit Note)**. * Attempting to change the document type manually only shows 113 as an option, confirming the debit note should not have been set to 111. **Cause:** * `_compute_l10n_latam_document_type()` applies a rule that assigns Document Type **111** to all Uruguay electronic invoices with RUT identification. * This logic does **not** check whether the move is a **debit note** (`m.debit_origin_id`), and therefore incorrectly overrides the expected debit note document type. * The override prevents the correct selection (internal_type == *debit_note*) from being applied. **Fix:** * Add a condition in the automatic e-Invoice assignment logic. * Debit notes now bypass the e-Invoice assignment and fall through to the parent method, which correctly assigns **Document Type 113**. opw-5154599 Forward-Port-Of: odoo/enterprise#100938
This update enhances the Point of Sale experience by adding a 'Reload Data' button to error dialogs. Previously, users were left without clear guidance on how to resolve data-related issues, often requiring support assistance. Now, users can easily retry data loading directly from the error dialog, streamlining the process.
Original PR description
Before this commit: --------- - Users could only click "Ok" or close error dialogs. - No clear guidance to resolve blocking issues. After this commit: ----------------- - ErrorDialog shows a "Reload Data" button alongside "Ok". Task-5353590 Related PR-https://github.com/odoo/odoo/pull/238112
This update resolves a previous error that prevented users from creating consolidated invoices for multiple POS orders linked to the same customer. The fix ensures accurate invoice generation when multiple orders are combined, improving the POS invoicing process. This change ensures consistent and reliable invoice creation for SA company users.
Original PR description
Currently, an error occurs when trying to create a consolidated invoice for multiple POS orders associated with the same customer. **Steps to reproduce:** - Install the `l10n_sa_pos` module and…
Currently, an error occurs when trying to create a consolidated invoice for multiple POS orders associated with the same customer. **Steps to reproduce:** - Install the `l10n_sa_pos` module and switch to the `SA company`. - Create two POS orders for the `same customer` without invoicing at checkout. - Close the POS session and go to `Point of Sale` > `Orders`. - Select both orders > click `Create Invoice` > `confirm` the action. (Make sure `Consolidated Billing` is enabled) **Error:** `ValueError: Expected singleton: pos.order(8, 7)` **Root cause:** At [1], the code accesses `self.date_order`, but when `consolidated billing` is enabled, self contains multiple POS orders, causing an `error`. **Fix:** This commit prevents the error by ensuring that the `current datetime` is assigned when creating a `consolidated invoice`, same as [2]. [1]: https://github.com/odoo/odoo/blob/583bacdc8ad2b87b99b11d1e12dacf6e42edf22b/addons/l10n_sa_pos/models/pos_order.py#L13 [2]: https://github.com/odoo/odoo/blob/583bacdc8ad2b87b99b11d1e12dacf6e42edf22b/addons/point_of_sale/models/pos_order.py#L828-L832 opw-5266908 Forward-Port-Of: odoo/odoo#237677
This update corrects a bug in the aged receivable report that prevented it from displaying accurate data when invoices lacked a due date. The fix ensures the report correctly filters and displays outstanding invoices, resolving a discrepancy between the report's data source and its display.
Original PR description
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this…
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this entry <img width="1599" height="238" alt="image" src="https://github.com/user-attachments/assets/010f97f4-0d50-4e5a-9366-ae67d17e2bb7" /> Observation: - on clicking the entry, when redirected to list view, there are `0` records. Issue: - The query which is used to display data on report uses `COALESCE(account_move_line.date_maturity, account_move_line.date)` https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L222-L226 - while the method `_build_domain_from_period` uses only `date_maturity` in domain redirecting to list view - This creates inconsistencies between two. https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L383-L394 opw-5237298 Forward-Port-Of: odoo/enterprise#99883
This fix resolves an issue where stock valuations were incorrectly calculated after splitting a purchase order into a batch and validating the batch. The problem stemmed from how the system handled quantity updates during batch validation, leading to inaccurate valuation amounts. This update ensures correct stock valuations are generated when using batch billing.
Original PR description
…n batch billed on ordered qty **Problem:** When the picking of a purchase order (of a product billed on ordered quantity) is split into different moves and put in a batch, at batch validation, svls…
…n batch billed on ordered qty
**Problem:**
When the picking of a purchase order (of a product billed on ordered quantity) is split into different
moves and put in a batch, at batch validation, svls are created with the wrong values.
**Steps to reproduce:**
- enable "Batch, Wave & Cluster Transfers" settings
- create a storable product with a standard price of 1
- set the category as avco
- in the Purchase tab select the control policy as
"on ordered quantities"
- create and confirm a purchase order for 50 of this product
- on the Receipt, change the quantity to 20 and split the
picking
- go back the the PO and create and confirm a bill for
the full amount
- click on the receipt smart button
- select the two pickings and then the 'Action' button
- select add to batch
- check 'new batch transfer' and confirm
- open the batch and validate it
- open stock valuation
**Current behavior:**
the newly created svls have total values of
50 and 50.10
**Expected behavior:**
it should be 20 and 30
**Cause of the issue:**
When the batch is validated, _action_done is called
on the two stock moves.
https://github.com/odoo/odoo/blob/dc57ea4d306f8745d37f2c5d2c3d3fa4bcaf7253/addons/stock/models/stock_picking.py#L1258
In the stock_account override:
- first the super method is called
As a consequence the state of the two moves becomes 'done'
and the qty_received of the linked purchase order line becomes 50.
- then product_price_update_before_done is called before creating
the svls.
Inside product_price_update_before_done we call _get_price_unit.
In the purchase_stock override of _get_price_unit :
- because the super method of action_done was already called,
qty_received of the purchase order line is 50, so _get_qty_received_without_self
will return 30.
https://github.com/odoo/odoo/blob/dc57ea4d306f8745d37f2c5d2c3d3fa4bcaf7253/addons/purchase_stock/models/stock_move.py#L50
So received_qty is 30 and later remaining_qty will be 20
https://github.com/odoo/odoo/blob/dc57ea4d306f8745d37f2c5d2c3d3fa4bcaf7253/addons/purchase_stock/models/stock_move.py#L86
- but because no svl was created yet receipt_value will stay 0 and later
remaining_value will be 50
https://github.com/odoo/odoo/blob/dc57ea4d306f8745d37f2c5d2c3d3fa4bcaf7253/addons/purchase_stock/models/stock_move.py#L55-L63
Therefore price_unit will be 2.5 (50/20) instead of 1
**fix**
We do not take into account the move(s) of the
same batch in the remaining value (because svls are not created yet)
so we should not take them into account in the remaining quantity.
opw-5179581
Forward-Port-Of: odoo/odoo#238222
Forward-Port-Of: odoo/odoo#235601This update ensures that bills automatically received through the PEPPOL network are immediately posted to the system, rather than remaining in a draft state. This streamlines the accounting process for partners using the PEPPOL network, improving efficiency and reducing manual intervention. This change was made to address a previous issue.
Original PR description
Currently, even if a partner has auto-post bills enabled, the incoming bills stay in the draft state. This change addresses that issue. Task-5373302 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#238473
This update fixes a potential issue where IoT reports could be printed multiple times. The change ensures that websocket actions are not duplicated by also checking for longpolling calls, streamlining report generation and improving efficiency. This prevents wasted resources and ensures accurate reporting.
Original PR description
In order to prevent duplicate IoT actions, we now ensure that websocket actions have not already been called through longpolling. odoo/odoo#236917 Forward-Port-Of: odoo/enterprise#101257 Forward-Port-Of: odoo/enterprise#100161
This update fixes a potential issue where reports could be printed multiple times, leading to unnecessary actions. The change ensures that websocket actions are not duplicated by checking if they've already been processed via longpolling. This improves efficiency and reduces potential errors.
Original PR description
In order to prevent duplicate IoT actions, we now ensure that websocket actions have not already been called through longpolling. odoo/enterprise#100161 Forward-Port-Of: odoo/odoo#238575 Forward-Port-Of: odoo/odoo#236917
This update fixes an issue where Express Checkout wasn't automatically applying the correct tax based on the customer's address. Now, the system correctly identifies and uses the appropriate fiscal position, eliminating the need for a page reload to see accurate pricing and taxes for users utilizing Stripe Express Checkout.
Original PR description
## Issue: When a fiscal position should apply based on the address provided during Express Checkout, it was not applied automatically The correct fiscal position only appeared after reloading the…
## Issue: When a fiscal position should apply based on the address provided during Express Checkout, it was not applied automatically The correct fiscal position only appeared after reloading the checkout page This issue affects public users using the eCommerce with Stripe Express Checkout ## Cause: The fiscal position was correctly determined during the `availableCarriers` computation, but it was not propagated to the payment request itself As a result, prices and taxes were only updated after a full page reload ## Steps to reproduce: - Configure Stripe with Express Checkout (e.g., Google Pay) - Create a fiscal position with automatic detection (Country = US, Tax mapping: 15% → 0%) - Create a product using the 15% tax - Go to the website shop and add the product to the cart - Use Express Checkout with a US address - Observe that the fiscal position is not applied unless the page is reloaded opw-5018238 Forward-Port-Of: odoo/odoo#238690 Forward-Port-Of: odoo/odoo#236832
This update resolves an issue where document previews were not updating after renaming documents, displaying outdated attachment names. The fix ensures that preview names consistently reflect the current document name, regardless of how the document was renamed (via the Rename action or chatter).
Original PR description
BUG 1: --------- **steps to reproduce**: 1. Install documents 2. Open any document 3. Go to Action > Rename 4. Rename the document 5. Preview it and read the name showed there **issue**: When…
BUG 1:
---------
**steps to reproduce**:
1. Install documents
2. Open any document
3. Go to Action > Rename
4. Rename the document
5. Preview it and read the name showed there
**issue**:
When previewing the document, it still shows the old attachment name.
**observation**:
When renaming a document, only the document name was updated. The attachment name remained unchanged, which caused inconsistencies:
1. In the All Records section, the document name is displayed correctly. https://github.com/odoo/enterprise/blob/459e8ddaf6f67a556d35bf00e0fbb68eb1500a94/documents/views/documents_document_views.xml#L130
2. But in the Preview, the old attachment name was still shown, as it is taken from the attachment:
https://github.com/odoo/enterprise/blob/459e8ddaf6f67a556d35bf00e0fbb68eb1500a94/documents/static/src/views/hooks.js#L373-L383
**solution**:
Use the document name when previewing it
BUG 2:
---------
**steps to reproduce**:
1. Install Documents.
2. Open any document.
3. Rename it via the chatter.
4. Try renaming it again via the details panel.
**issue**:
After renaming a document twice through the details panel, the preview still displayed the old document name.
**cause**:
On the first rename, the [insert](https://github.com/odoo/enterprise/blob/691115d8a0b31322f64d35d82dc8c9ddbfcd39b0/documents/static/src/core/document_service.js#L96-L129)) method creates a new [store.Document](https://github.com/odoo/enterprise/blob/691115d8a0b31322f64d35d82dc8c9ddbfcd39b0/documents/static/src/views/hooks.js#L367-L393) record with the updated attachment name. However, The write method (used by chatter) skips reloading the record and linked attachment data on the second rename.
Unlike the Rename button, which uses web_save (and triggers a record reload via web_read), the chatter directly calls write without refreshing the attachment.
**Solution**:
Ensure the preview uses the document name from the document record, keeping it consistent after multiple renames via the details panel.
**Example:** Try to rename a "Invoice.pdf" document to "Invoice_rename.pdf"
<details>
<summary>Click here to see the results:</summary>
Before:
<img src="https://github.com/user-attachments/assets/563b7fb9-709c-4651-8492-032a7f353730"/>
After:
<img src="https://github.com/user-attachments/assets/6fc6bdfe-dd1e-4f3c-aaf7-821c44fd135d"/>
</details>
opw-5065433
Forward-Port-Of: odoo/enterprise#100539
Forward-Port-Of: odoo/enterprise#95111This update corrects a technical issue in the Danish Nemhandel integration by ensuring that specific document type checks are only applied to Danish partners. This prevents conflicts with standard Peppol processes and ensures consistent data flow, improving the reliability of the Danish integration.
Original PR description
Before: - The l10n_dk_nemhandel override of _check_document_type_support replaced the generic Peppol logic and did not accept process_type, causing errors when other localizations relied on the base method. After: - Aligned the method and applied the DK-specific logic only for Danish partners, falling back to the generic Peppol behavior otherwise. Impact: - Prevents unintended overrides towards standard Peppol flow. Forward-Port-Of: odoo/odoo#238543
This update prevents the creation of duplicate reversal and deferral entries when generating deferred entries from invoices. The change corrects a calculation issue introduced with a new method for handling monthly accounting dates, ensuring journal entries are cleaner and more accurate. This improves the overall stability and clarity of financial reporting.
Original PR description
When generating deferred entries from invoice lines, certain scenarios led to the creation of both a reversal and a deferral for the same amounts. These entries would effectively cancel each other out, creating unnecessary noise in the journal entries. This issue primarily occurred when the start date, end date, and accounting date all fell within the same calendar month. The problem was exacerbated by the introduction of the `full_months` computation method in https://github.com/odoo/enterprise/commit/5dca9c0c2691cba2335e110ad63a2dcc8bbf6d57. To correctly handle this method and prevent the erroneous paired entries, the end date must now be adjusted by subtracting one month when calculating the deferral period. opw-5000337 Forward-Port-Of: odoo/enterprise#101258 Forward-Port-Of: odoo/enterprise#100507
This update resolves an error that occurred when creating time off allocations using hours, particularly when each attendance had a defined start and end date. The fix prevents a division-by-zero error, ensuring time off allocations are created correctly. This addresses a symptom of a deeper issue with how attendance dates are handled, but doesn't fully resolve the underlying problem.
Original PR description
_ ## Short functional explanation of the error When creating a time off allocation with a time off type expressed in hours, and having start/end dates for every attendance in the corresponding…
_ ## Short functional explanation of the error When creating a time off allocation with a time off type expressed in hours, and having start/end dates for every attendance in the corresponding calendar, an error is raised. ## Reproduction Steps 1. Go to Employees and click on the Configuration tab > Working Schedules. 2. Click on a schedule and click on the button next to Work Entry Type to show the Starting date. 3. Set a starting date for each entry. 4. Go to Time Off. Click on the Configuration tab > Time Off Types. 5. Click on a time off and next to the Take Time Off in, select Hours. 6. Click on the Management tab > Allocations. Click on New. 7. Select an employee that has the schedule you updated earlier. ## Expected behavior The allocation is created. ## Unexpected Behavior A traceback occurs: ``` ZeroDivisionError: float division by zero ``` ## Origin of the issue When setting a start or/and an end date to an attendance, this attendance won't be taken into account for global attendances anymore. This leads to an erroneous computation of hours_per_day, leading to a few issues; one of them is related to time off allocation: When setting a time off with a time off type expressed in hours, if every single attendance in the calendar has a start/end date, there will be no global attendance hours left, leading to a division by 0: https://github.com/odoo/odoo/blob/8097b674a23858ed7692a0b30ca74419b8f890f7/addons/hr_holidays/models/hr_leave_allocation.py#L262 After discussion, we decided that this fix would only fix a symptom, and not the problem itself. _ opw-5340056 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#237782
This update resolves an issue where the timesheet grid incorrectly displayed unavailable days when flexible hours were enabled for a company. The fix ensures that all days are treated as working days when flexible hours are in use, providing accurate timesheet availability. This improves the usability of the timesheet feature for companies utilizing flexible work schedules.
Original PR description
**Description** When a company's working schedule has flexible hours enabled, the timesheet grid was incorrectly displaying random weekdays as non-working days (greyed out cells). The affected days…
**Description** When a company's working schedule has flexible hours enabled, the timesheet grid was incorrectly displaying random weekdays as non-working days (greyed out cells). The affected days varied by month because the unavailability calculation was time-dependent. **Steps to reproduce** 1. Enable flexible hours on company's working schedule 2. Go to Timesheets > All timesheets 3. Switch to Grid view and filter by month 4. Observe that random weekdays (e.g., Wed/Thu or Mon/Tue) are greyed out **Fix** The grid_unavailability method now checks if the company calendar has flexible_hours enabled. When true, it returns an empty list of unavailable days, treating all days as potential working days. This fix adds the flexible_hours check in two locations within the grid_unavailability method to cover all code paths: 1. get_company_unavailable_dates() helper function - prevents unnecessary calculation when called as fallback 2. company_unavailable_days assignment from calendar_work_intervals - handles the direct path when company calendar is found This follows the same pattern as the gantt view fix #100385 opw-5215646 Forward-Port-Of: odoo/enterprise#100881
This update resolves an error that occurred when configuring the Tax Returns journal in Odoo. The fix ensures a default progress record is created, preventing a singleton error that arose from changes in how onboarding data is initialized. This ensures the Tax Returns journal functionality works correctly for all Odoo instances.
Original PR description
Currently, an error is produced when configuring the **Accounting Period** on the "**Tax Returns**" journal. Steps to Reproduce: 1. Install `accountant` module without demo data using `-i` command.…
Currently, an error is produced when configuring the **Accounting Period** on the "**Tax Returns**" journal. Steps to Reproduce: 1. Install `accountant` module without demo data using `-i` command. 2. Accounting > Dashboard > "**Tax Returns**" Journal, click on “Tax Returns” button. 3. Set an _Opening Date_ in the wizard and try to apply the **Accounting Periods**. **Error:** `ValueError - Expected singleton: onboarding.progress()` **Cause:** **Until saas-18.2,** The onboarding record’s `current_progress_id` was created by method `_search_or_create_progress()` - ([1]) during module initialization. This method was triggered through `_initiate_account_onboardings()`, which was called in the `_accounting_post_init()` hook for all companies - ([2]). **From saas-18.3,** `_accounting_post_init()` was modified to call `_initiate_account_onboardings()` only for companies having a `chart_template` - ([3]). As a result, companies without a chart template never receive a default progress record, leaving `current_progress_id` unset. When rendering onboarding values, this leads to a singleton error. **Fix:** This commit ensures that a progress record exists by creating it when missing before rendering onboarding values. [1]: https://github.com/odoo/odoo/blob/b2558e92e627a0efd975a402b77a6b53810c4c41/addons/onboarding/models/onboarding_onboarding.py#L107-L111 [2]: https://github.com/odoo/enterprise/blob/2f2b53f1c6f31ae22351d22cf4bf59ef01a63691/accountant/__init__.py#L22-L25 [3]: https://github.com/odoo/enterprise/blob/37dd63580967c1186618d7340a21539a6c98dbba/accountant/__init__.py#L22-L24 sentry-7064593163
9 changes
Enhancements to existing features
This update clarifies the labeling of a field used when making salary adjustments within the Odoo Enterprise system. The change ensures users understand exactly where this setting is accessible, improving the overall user experience and reducing potential confusion. This is a minor improvement focused on usability.
Original PR description
This change ensures the label accurately reflects where the field is accessible and providing better clarity for users when working with salary adjustments. Task: 5375187 Forward-Port-Of: odoo/enterprise#101065
Resolved issues and error corrections
This update fixes an issue where journal items displayed in financial reports were incorrectly linked to the wrong account groups. The fix ensures that journal items are accurately associated with the corresponding account group, improving the accuracy of financial reporting.
Original PR description
Repro steps: 1. Create account groups 2. Go to general ledger report 3. Click on 'Journal Items' of one of the account groups lines Problem: The journal items shown don't belong to the account group that it should belong to. Fix: This commit fixes this issue by adding the correct action_domain of account_id.group_id. opw-5180867 Forward-Port-Of: odoo/enterprise#100191
This update fixes an issue where debit notes created in the Uruguay localization were incorrectly assigned as e-invoices. The fix ensures debit notes automatically use the correct document type (113) instead of the default e-invoice type (111), improving invoice processing accuracy.
Original PR description
**Steps to reproduce:** * Install and activate the **Uruguayan Localization** for the company. * Create a contact located in Uruguay. * Create an invoice for this customer and set **Document Type =…
**Steps to reproduce:** * Install and activate the **Uruguayan Localization** for the company. * Create a contact located in Uruguay. * Create an invoice for this customer and set **Document Type = 111 (e-Invoice)**. * From the invoice's gear icon, create a **Debit Note**. **Observed behavior:** * The debit note is automatically assigned **Document Type 111 (e-Invoice)**, even though it should use **113 (e-Invoice Debit Note)**. * Attempting to change the document type manually only shows 113 as an option, confirming the debit note should not have been set to 111. **Cause:** * `_compute_l10n_latam_document_type()` applies a rule that assigns Document Type **111** to all Uruguay electronic invoices with RUT identification. * This logic does **not** check whether the move is a **debit note** (`m.debit_origin_id`), and therefore incorrectly overrides the expected debit note document type. * The override prevents the correct selection (internal_type == *debit_note*) from being applied. **Fix:** * Add a condition in the automatic e-Invoice assignment logic. * Debit notes now bypass the e-Invoice assignment and fall through to the parent method, which correctly assigns **Document Type 113**. opw-5154599 Forward-Port-Of: odoo/enterprise#100938
This update corrects a bug in the aged receivable report that prevented it from correctly displaying invoices without a due date. The issue stemmed from an inconsistency in how the report's query and the filtering logic handled invoice dates, leading to empty results when viewing individual invoice entries. This ensures accurate reporting for all invoices.
Original PR description
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this…
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this entry <img width="1599" height="238" alt="image" src="https://github.com/user-attachments/assets/010f97f4-0d50-4e5a-9366-ae67d17e2bb7" /> Observation: - on clicking the entry, when redirected to list view, there are `0` records. Issue: - The query which is used to display data on report uses `COALESCE(account_move_line.date_maturity, account_move_line.date)` https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L222-L226 - while the method `_build_domain_from_period` uses only `date_maturity` in domain redirecting to list view - This creates inconsistencies between two. https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L383-L394 opw-5237298 Forward-Port-Of: odoo/enterprise#99883
This update eliminates a technical issue that caused duplicate reversal and deferral entries in the accounting system, particularly when invoice dates fell within the same month. By adjusting the deferral period calculation, this fix reduces accounting noise and improves the accuracy of financial reports.
Original PR description
When generating deferred entries from invoice lines, certain scenarios led to the creation of both a reversal and a deferral for the same amounts. These entries would effectively cancel each other out, creating unnecessary noise in the journal entries. This issue primarily occurred when the start date, end date, and accounting date all fell within the same calendar month. The problem was exacerbated by the introduction of the `full_months` computation method in https://github.com/odoo/enterprise/commit/5dca9c0c2691cba2335e110ad63a2dcc8bbf6d57. To correctly handle this method and prevent the erroneous paired entries, the end date must now be adjusted by subtracting one month when calculating the deferral period. opw-5000337 Forward-Port-Of: odoo/enterprise#101258 Forward-Port-Of: odoo/enterprise#100507
This update resolves an issue where the timesheet grid incorrectly displayed unavailable days when flexible hours were enabled for a company. The fix ensures that all days are treated as working days when flexible hours are in use, providing accurate timesheet availability. This improves the usability of the timesheet feature for companies utilizing flexible work schedules.
Original PR description
**Description** When a company's working schedule has flexible hours enabled, the timesheet grid was incorrectly displaying random weekdays as non-working days (greyed out cells). The affected days…
**Description** When a company's working schedule has flexible hours enabled, the timesheet grid was incorrectly displaying random weekdays as non-working days (greyed out cells). The affected days varied by month because the unavailability calculation was time-dependent. **Steps to reproduce** 1. Enable flexible hours on company's working schedule 2. Go to Timesheets > All timesheets 3. Switch to Grid view and filter by month 4. Observe that random weekdays (e.g., Wed/Thu or Mon/Tue) are greyed out **Fix** The grid_unavailability method now checks if the company calendar has flexible_hours enabled. When true, it returns an empty list of unavailable days, treating all days as potential working days. This fix adds the flexible_hours check in two locations within the grid_unavailability method to cover all code paths: 1. get_company_unavailable_dates() helper function - prevents unnecessary calculation when called as fallback 2. company_unavailable_days assignment from calendar_work_intervals - handles the direct path when company calendar is found This follows the same pattern as the gantt view fix #100385 opw-5215646 Forward-Port-Of: odoo/enterprise#100881
This update resolves a test failure related to user switching in the MRP work order module. The fix ensures the test waits for shop floor records to fully load before checking their presence, preventing intermittent failures. This improves the reliability of the test suite.
Original PR description
The test `test_shop_floor_my_wo_filter_with_pin_user` sometimes fails on these steps:…
The test `test_shop_floor_my_wo_filter_with_pin_user` sometimes fails on these steps: https://github.com/odoo/enterprise/blob/422ac3d5b10c44233321010b9ecb8e37735b3ea3/mrp_workorder/static/tests/tours/tour_shopfloor.js#L177-L190 https://github.com/odoo/enterprise/blob/422ac3d5b10c44233321010b9ecb8e37735b3ea3/mrp_workorder/static/tests/tours/tour_shopfloor.js#L196-L206 https://github.com/odoo/enterprise/blob/422ac3d5b10c44233321010b9ecb8e37735b3ea3/mrp_workorder/static/tests/tours/tour_shopfloor.js#L212-L221 This happends since changing the user requires some time to display the related shopfloor records, but the steps check the number of visible records as soon as it has switched rather than when it is sure that the records are displayed. #### Fix: Since switching employees will first empty the recordset and later display the related records, we can split the steps in two. We first check that we switched users, then we check the existence of a record that is not present for the previous user, and only then perform the related checks. #### runbot-226734 Forward-Port-Of: odoo/enterprise#100908 Forward-Port-Of: odoo/enterprise#100746
This update fixes an issue where IoT reports were sometimes printed multiple times. The change ensures that report actions are only executed once, whether through a standard websocket or a previous longpolling method. This improves report reliability and avoids unnecessary printing.
Original PR description
In order to prevent duplicate IoT actions, we now ensure that websocket actions have not already been called through longpolling. odoo/odoo#236917 Forward-Port-Of: odoo/enterprise#101257 Forward-Port-Of: odoo/enterprise#100161
This update corrects a previous error in the EPF (Employee Provident Fund) calculation for Malaysian employees. The changes ensure accurate rounding of tax amounts to the next ringgit, aligning with current legislation. This update improves the accuracy of payroll processing for our Malaysian clients.
Original PR description
Previous behavior did not account for the rounding of the amount of tax to the next ringgit. Also the employee's rate has been updated in accordance to the legislation. task-5286179 Forward-Port-Of: odoo/enterprise#100736
18 changes
Enhancements to existing features
This update clarifies the labeling of a field used when making salary adjustments within the HR payroll system. The change ensures users understand exactly where this setting is accessible, improving the overall user experience. This is a minor improvement focused on usability.
Original PR description
This change ensures the label accurately reflects where the field is accessible and providing better clarity for users when working with salary adjustments. Task: 5375187 Forward-Port-Of: odoo/enterprise#101065
Resolved issues and error corrections
This update fixes an issue where the payroll system was incorrectly referencing employee version records instead of the main employee records. This change ensures accurate calculations and reporting related to employee compensation, particularly in Switzerland. The fix was triggered by a recent update to the Odoo Enterprise system.
Original PR description
Commit [46052c4](https://github.com/odoo/enterprise/commit/46052c4bc5ad1bd2549a6125202e0671b56beac8) introduced the `hr.version` model, which contains historical information about an employee record. Some of the updated lines use the hr.version ID when they should use `hr.employee`. Ticket [5218215](https://www.odoo.com/odoo/project.task/5218215) Forward-Port-Of: odoo/enterprise#100079
This update resolves an issue where duplicating multiple repair orders would cause errors. The fix ensures the system correctly handles multiple records during duplication, allowing users to efficiently copy repair orders without encountering technical problems. This improves the reliability of a key business process.
Original PR description
## Current behaviour: Duplicating multiple repair orders raises an error due to direct access to record fields without iterating on each record. ## Expected behaviour: Duplicating multiple repair orders should work without errors. ## Steps to reproduce: 1. Open runbot. 2. Select multiple repair orders. 3. Click "Duplicate". 4. System raises an error. ## Cause of the issue: The create/write methods assume a single record and fail when multiple records are processed at once. ## Caused by: https://github.com/odoo/enterprise/commit/16e1a97d85fc8227c73ce4a1507ab92ab7ed8486 The commit introduced logic that accesses values directly without looping over each record. ## Fix: Loop over records in create and write to handle multi-record operations. opw-5382657 Forward-Port-Of: odoo/enterprise#101184
This update fixes an issue where the 'Journal Items' link in the General Ledger report incorrectly displayed items not associated with the selected account group. The fix ensures that users see the correct journal items linked to their account groups, improving report accuracy and data reliability.
Original PR description
Repro steps: 1. Create account groups 2. Go to general ledger report 3. Click on 'Journal Items' of one of the account groups lines Problem: The journal items shown don't belong to the account group that it should belong to. Fix: This commit fixes this issue by adding the correct action_domain of account_id.group_id. opw-5180867 Forward-Port-Of: odoo/enterprise#100191
This update fixes an issue where debit notes created in Uruguay were incorrectly assigned as e-invoices (type 111). The fix ensures debit notes automatically use the correct document type (113), streamlining invoice processing for Uruguayan customers. This improves data accuracy and compliance.
Original PR description
**Steps to reproduce:** * Install and activate the **Uruguayan Localization** for the company. * Create a contact located in Uruguay. * Create an invoice for this customer and set **Document Type =…
**Steps to reproduce:** * Install and activate the **Uruguayan Localization** for the company. * Create a contact located in Uruguay. * Create an invoice for this customer and set **Document Type = 111 (e-Invoice)**. * From the invoice's gear icon, create a **Debit Note**. **Observed behavior:** * The debit note is automatically assigned **Document Type 111 (e-Invoice)**, even though it should use **113 (e-Invoice Debit Note)**. * Attempting to change the document type manually only shows 113 as an option, confirming the debit note should not have been set to 111. **Cause:** * `_compute_l10n_latam_document_type()` applies a rule that assigns Document Type **111** to all Uruguay electronic invoices with RUT identification. * This logic does **not** check whether the move is a **debit note** (`m.debit_origin_id`), and therefore incorrectly overrides the expected debit note document type. * The override prevents the correct selection (internal_type == *debit_note*) from being applied. **Fix:** * Add a condition in the automatic e-Invoice assignment logic. * Debit notes now bypass the e-Invoice assignment and fall through to the parent method, which correctly assigns **Document Type 113**. opw-5154599 Forward-Port-Of: odoo/enterprise#100938
This update fixes a problem where annotations in PDF exports of Balance Sheet reports were not displayed in chronological order. Now, the oldest annotations will appear first, ensuring a more accurate and understandable report. This improves the clarity and reliability of financial reporting.
Original PR description
We expect the oldest annotations to appear first when exporting to a PDF.
To reproduce:
- Go to any report such as the Balance Sheet
- Open the chatter for an account
- Post 2 messages ("first" and "second" for exemple)
- Export the report to PDF
This was introduced in https://github.com/odoo/enterprise/pull/95307
Forward-Port-Of: odoo/enterprise#100475This update resolves a test failure that occurred when the demo data was used. The fix ensures the test no longer interferes with the demo environment, preventing disruptions and maintaining the accuracy of the demo setup. This improves the reliability of the demo for testing and demonstration purposes.
Original PR description
Some tests were failing when the demo data were installed. This commit fixes the test so that it doesn't interfere with demo data. Related build error: https://runbot.odoo.com/odoo/runbot.build.error/234529 task-5386529 Forward-Port-Of: odoo/enterprise#101301
This update resolves an issue where the automatic transfer account rule was creating duplicate and incorrect rules, leading to inaccurate account assignments. The fix simplifies the rule creation process by removing redundant mechanisms, ensuring data integrity and a more reliable transfer process.
Original PR description
## Steps to reproduce: 1. Create a new transfer record 2. Add more than one account to the Accounts field or add a rule with condition on Account or remove account from an Account condition with multiple accounts set ... (various other actions when adding/removing accounts) ## Before: Redundant and incorrect rules are created and an incorrect value is assigned for account_ids due to the faulty sync between the two. ## After: Removing the onchange mechanism that creates the rule with condition on Account whenever an account is added to the Accounts field, this information is redundant for the user. Also removing the onchange mechanism of the reverse (adding accounts to the Accounts field when a rule with condition on Account is added) as it cannot account for nested rules and any/all conditions. opw - 5160635 Forward-Port-Of: odoo/enterprise#100054
This update resolves an issue where bank statement creation would fail when the Chart of Accounts wasn't properly configured. The fix ensures the system only attempts to match accounts when valid accounts are present, preventing a syntax error and improving the reliability of bank statement processing.
Original PR description
**Steps to Reproduce:** 1. Install the **Accounting** module without demo data. 2. In "**Chart of Accounts**", change the type of all accounts (e.g.; Expenses). 3. In "**Bank**" Journal, create a new bank statement line and try to save it. **Error:** ``` SyntaxError - syntax error at or near ")" LINE 19: AND aml.account_id IN () ``` **Cause:** A **IN** condition is evaluated with an empty tuple `AND aml.account_id IN ()`. This is due to that there are no `account_ids`. **Fix:** This commit only executes the SQL query when there are valid accounts to consider. sentry-7059353053 Forward-Port-Of: odoo/enterprise#100931 Forward-Port-Of: odoo/enterprise#100459
This update corrects a visual issue where the activity badge within the bank reconciliation widget was misaligned. The fix removes a styling class that was causing the misalignment, ensuring the badge now appears correctly positioned on the icon. This improves the user experience and visual consistency of the bank reconciliation feature.
Original PR description
Current behavior before PR: The activity badge inside the bank reconciliation widget was misaligned, <img width="55" height="60" alt="image" src="https://github.com/user-attachments/assets/0f99ea55-fedd-401a-a65e-226296070e32" /> Desired behavior after PR is merged: The activity badge now sits in the correct position on the icon. <img width="62" height="55" alt="image" src="https://github.com/user-attachments/assets/abf96aed-73d4-4153-8e0a-56937d4ff08a" /> Changes implemented: - Removed `fa-fw` class. - Removed the unnecessary 'fa-fw' class from comment and paperclip icon. task-5354994 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/enterprise#100573
This update fixes an issue where the Christmas Bonus payslip incorrectly used a standard periodicity. The change ensures the payslip's periodicity is set to '99' (other periodicity) when the bonus is classified as extraordinary, accurately reflecting Mexican payroll regulations. This ensures correct reporting and payment processing for this specific bonus type.
Original PR description
For the Christmas Bonus, the 'periodicidad_pago', the periodicity of the payslip, should be 99, i.e. other periodicity. Right now, it takes the periodicity from the version which is not correct. Fix: when the structure is of payroll type extraordinary, put 99 in the 'periodicidad_pago'. Task: 5344050 Forward-Port-Of: odoo/enterprise#100271
This update resolves a critical error that prevented the generation of payroll export files. The fix corrects a naming mismatch in the code, ensuring accurate retrieval of employee data. A new test suite has been added to guarantee the reliability of the export process and validate data integrity.
Original PR description
The export generation crashed due to a mismatch between field names — the code was referencing employee_ids, while the model actually defines employee_id. Since the Prisma code is now stored on the employee model, the logic was updated to correctly access the employee_id field and retrieve the related Prisma code. Additionally, a comprehensive test suite was added to validate Prisma code behavior, including: - validation of code length for employees, companies, and work entry types, - handling of codes across different companies, - and the complete Prisma export flow (from work entry creation and validation to export file generation). task-5153727 Forward-Port-Of: odoo/enterprise#101137 Forward-Port-Of: odoo/enterprise#96743
This update resolves an issue where the timesheet grid incorrectly displayed unavailable days when flexible hours were enabled for a company. The fix ensures that all days are treated as working days when flexible hours are in use, providing accurate timesheet availability. This improves the usability of the timesheet feature for companies utilizing flexible work schedules.
Original PR description
**Description** When a company's working schedule has flexible hours enabled, the timesheet grid was incorrectly displaying random weekdays as non-working days (greyed out cells). The affected days…
**Description** When a company's working schedule has flexible hours enabled, the timesheet grid was incorrectly displaying random weekdays as non-working days (greyed out cells). The affected days varied by month because the unavailability calculation was time-dependent. **Steps to reproduce** 1. Enable flexible hours on company's working schedule 2. Go to Timesheets > All timesheets 3. Switch to Grid view and filter by month 4. Observe that random weekdays (e.g., Wed/Thu or Mon/Tue) are greyed out **Fix** The grid_unavailability method now checks if the company calendar has flexible_hours enabled. When true, it returns an empty list of unavailable days, treating all days as potential working days. This fix adds the flexible_hours check in two locations within the grid_unavailability method to cover all code paths: 1. get_company_unavailable_dates() helper function - prevents unnecessary calculation when called as fallback 2. company_unavailable_days assignment from calendar_work_intervals - handles the direct path when company calendar is found This follows the same pattern as the gantt view fix #100385 opw-5215646 Forward-Port-Of: odoo/enterprise#100881
This update resolves an issue where the ChatGPT plugin button was disabled when no text selection was made in the HTML editor. Now, the button consistently enables the ChatGPT window, regardless of whether a selection is present, ensuring users can always access the AI features.
Original PR description
This PR fixes an issue with the toolbar button. Before when no selection were applied in the HTML Editor, the button would be disabled. This PR introduce a fix that makes the button enabled in two scenarios: - Either the user has no selection, clicking the button will then open the chat window without any AI button, as it does with the powerbox buttons, - Or the user has a selection, then clicking the button will result in opening the chat window with the AI buttons as it was already the case. If the user has a selection that is empty, then the button remains visible but is disabled. Forward-Port-Of: odoo/enterprise#101332
This update corrects a technical error in how Odoo processes webhook events related to virtual expense cards. Specifically, it addresses a situation where 'None' shipping values were incorrectly treated as dictionaries, preventing proper expense tracking. This fix ensures accurate expense reporting data.
Original PR description
Add a fix to a pattern of error found in webhook events where virtual cards whose shipping value is "None" would be accessed as dict Forward-Port-Of: odoo/enterprise#100703
This update fixes a technical issue that caused duplicate journal entries (reversals and deferrals) to be created, leading to confusing accounting reports. The change ensures that deferred entries are calculated correctly, particularly when invoice dates fall within the same month, resulting in cleaner and more reliable financial records.
Original PR description
When generating deferred entries from invoice lines, certain scenarios led to the creation of both a reversal and a deferral for the same amounts. These entries would effectively cancel each other out, creating unnecessary noise in the journal entries. This issue primarily occurred when the start date, end date, and accounting date all fell within the same calendar month. The problem was exacerbated by the introduction of the `full_months` computation method in https://github.com/odoo/enterprise/commit/5dca9c0c2691cba2335e110ad63a2dcc8bbf6d57. To correctly handle this method and prevent the erroneous paired entries, the end date must now be adjusted by subtracting one month when calculating the deferral period. opw-5000337 Forward-Port-Of: odoo/enterprise#101258 Forward-Port-Of: odoo/enterprise#100507
Features or functions removed from Odoo
This update simplifies the AI modules by replacing outdated PyTZ dependencies with the more current ZoneInfo. This change was driven by a previous update to standardize timezone handling within Odoo, ensuring greater consistency and accuracy.
Original PR description
Small commit that replaces pytz dependencies with ZoneInfo since the following PR made that be the standard choice: https://github.com/odoo/odoo/pull/236660
Code cleanup and technical improvements
This update simplifies the way ringtones are handled within the Odoo Enterprise system. Previously, a separate service was required to initialize ringtones; now, ringtones are directly initialized and exported as objects. This change improves efficiency and reduces complexity in the system.
Original PR description
There is no need to have a service to initialize a ringtone object. Instead, we just initialize an object and export it.
39 changes
Enhancements to existing features
This update enhances the ability to retrieve information from related records (o2m relationships) when sending sign requests. Previously, limitations prevented accessing additional data, but this change enables greater flexibility and data access for sign workflows. This improves the functionality of the sign process.
Original PR description
The class `SignerX2Many` is inheritable, but if we need another value from the o2m, we can't use it because the `signerX2Many` is not exportable. Enable `signerX2Many` customization, allowing more fields to be read from the `sign.send.request.signer` model. Forward-Port-Of: odoo/enterprise#99977
This update clarifies the labeling of a field used when making salary adjustments within Odoo. The change ensures users understand exactly where this input type is accessible, preventing confusion and streamlining the adjustment process. This improves the overall user experience for HR professionals.
Original PR description
This change ensures the label accurately reflects where the field is accessible and providing better clarity for users when working with salary adjustments. Task: 5375187 Forward-Port-Of: odoo/enterprise#101065
Resolved issues and error corrections
This update resolves a problem where images set to a percentage width in the document footer were not being displayed correctly when using wkhtmltopdf. The fix reverts a previous change that caused this issue, ensuring images resize properly and appear as intended. This improves the visual quality of documents generated from the HTML editor.
Original PR description
Problem: wkhtmltopdf doesn't render images with both width and height set in percentage. Solution: When resizing in percentage, set only the width. This effectively reverts a change introduced in 920cea5ff567c9113370174570d0ead0bbfa767a. Steps to reproduce: - Add an image to the document footer. - Set the image size to 50%. - Print the document. - The image does not appear. opw-5168087 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes an issue where stock deliveries weren't accurately reflecting the FIFO (First-In, First-Out) valuation method. The change ensures that the quantity already delivered is properly accounted for, leading to more precise cost of goods calculations. This improves the accuracy of financial reporting related to stock movements.
Original PR description
Steps to reproduce: - Have a product valued in fifo - Create 3 PO for it, each for 1 qty of price 10, 20 and 30. - Confirm these PO & validate their receipts - Create 2 SO for this product, each for 1 qty - Confirm these SO & validate their deliveries together Issue: The value associated to the delivery moves (and so the cogs generated from them) is 10 for both. When calling `_action_done()` on the moves, we'll set the value of each move before moving them. To get the correct value from the fifo stack, we rely on the `qty_available` at the time. However, since we're going to set the value of multiple moves before validating them, the `qty_available` won't be updated between each call. opw-5359484 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves an issue where promotion rewards automatically added to cart lines couldn't be removed. The fix ensures that the necessary context is passed during the removal process, allowing users to correctly remove promotion rewards from their shopping carts. This improves the user experience and prevents unwanted promotion applications.
Original PR description
Steps: - Add a loyalty program of type promotion - Program trigger should be Automatic - Go to Shop > Add a product that triggers the reward of promotion - Try to remove the promotion added from the cart lines Issue: - Remove does not work for the automatically applied promotion reward Cause: - Context is not properly passed to the unlink method that removes the cart line of the promotion reward. - Since the unlink method is not receiving context properly, removal is bypassed Fix: - Instead of adding context in `self`, adding it directly in the `order_line` context fixes the issue. task-5076061 Forward-Port-Of: odoo/odoo#226789
This update fixes an issue where changing a manufacturing order (MO) in the Gantt view would incorrectly update product information, leading to inconsistencies in reporting and data. Specifically, it prevents the `product_id` from changing after confirmation, ensuring accurate component tracking and preventing misleading by-product displays on shop floor reports.
Original PR description
Steps to reproduce: 1- Create MO and confirm 2- In gantt view move it to another product's line Issue: Product is changed, after being confirmed and it causes a lot of inconsistencies, as it changes into the new product with the main product's component and in the shop floor the main product is shown as a by-product even if the by-products are disabled. Task: 5362247 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update clarifies the ESIC contribution rules within the payroll system. The tooltip now specifies that employee and employer contributions are calculated when gross wages are below ₹21,000. This ensures accurate reporting and compliance with ESIC regulations.
Original PR description
We are updating the field tooltip. Before: - l10n_in_esic_employee_amount: Employee contributions towards ESIC(Employees’ State Insurance Corporation) are calculated based on their gross wages. - l10n_in_esic_employer_amount: Employer contributions towards ESIC (Employees’ State Insurance Corporation) are calculated based on the employee’s gross wages. After: - l10n_in_esic_employee_amount: Employee contributions apply when the gross wage is below ₹21,000 - l10n_in_esic_employer_amount: Employer contributions apply when the gross wage is below ₹21,000 Task: 5383839
This update resolves an issue where invalid PDF tests would fail due to compatibility problems with different versions of the PyPDF library. The fix standardizes error handling, ensuring the test consistently passes regardless of the PyPDF version used, improving the reliability of the sign document process.
Original PR description
## Case 1: When `pypdf2_2` is not installed, it falls back to using the pypdf package. (Ref1) This triggers a warning during the test case when it tries to parse an invalid PDF. This commit…
## Case 1: When `pypdf2_2` is not installed, it falls back to using the pypdf package. (Ref1) This triggers a warning during the test case when it tries to parse an invalid PDF. This commit suppresses the warning to ensure the test runs without warnings. Ref1: https://github.com/odoo/odoo/blob/26a5384af0af8fc6e6b5a10bea277f937e2b3481/odoo/tools/pdf/__init__.py#L42-L46 ## Case 2: With **PyPDF2===1.26.0**, the line at [1] raises a `PyPDF2.utils.PdfReadError: EOF marker not found`. This exception is not handled by the same except block but is instead handled later in the flow at [2]. As a result, the test raises a **UserError**, causing the assertion to fail. On the other hand, when `pypdf2_2` or `pypdf` is installed, the _PdfFileReader_ raises a **UnicodeDecodeError**, which is then handled as a **ValidationError**, allowing the test to pass as expected. This commit adds handling for **PdfReadError** in method `get_valid_pdf_data()` to unify the behavior across all supported PyPDF versions. 1: https://github.com/odoo/enterprise/blob/f79601c62ca629dc01a5c1ad5520b0bb44a169d0/sign/utils/pdf_handling.py#L27 2: https://github.com/odoo/enterprise/blob/f79601c62ca629dc01a5c1ad5520b0bb44a169d0/sign/models/sign_document.py#L433-L437 Runbot-234021, 234022
This update fixes an issue where Point of Sale orders with variant kits didn't correctly generate picking lists. Previously, only one variant's specific components were included. Now, the system accurately creates picking lists for all variants within a kit, ensuring complete fulfillment of orders.
Original PR description
When selling a bom kit that have some components that applies on specific variants only, the picking was not correctly created. It would only take one kit variant into account, even if you sold 2…
When selling a bom kit that have some components that applies on specific variants only, the picking was not correctly created. It would only take one kit variant into account, even if you sold 2 kits with different variants. Steps to reproduce: ------------------- * Create a product P * For product P, create an attribute with type "No variant" and values V1 and V2 * Create a BoM Kit for product P, with 3 components C1 C2 and C3 - C2 applies only for variant V1 - C3 applies only for variant V2 * Create a POS order with 2 lines of product P: - 1 with variant V1 - 1 with variant V2 * Validate the order and check the created picking > Observation: Only C1 and C2 are in the picking, C3 is missing Why the fix: ------------ When creating the picking, the code was grouping the order lines by product only, and not by product variant. Therefore, the 2 lines would be grouped together, and only one of the variant-specific components would be taken into account. opw-5051289 Forward-Port-Of: odoo/odoo#237844 Forward-Port-Of: odoo/odoo#235528
This update resolves a crash issue that occurred within the website builder when a form contained a Many2One field with no associated records. The fix mirrors the approach used for many2many and one2many fields, displaying a disabled input when a field has no data. This ensures a stable and reliable user experience for website form creation.
Original PR description
With the [website builder refactor], the code was not robust in case there were no records for a many2one field in a form.
Steps to reproduce:
- Open website builder on a form in a new database
- Set action "Send an email"
- Add a field with type "Alias Domain" ("Option List" must be empty)
- Change "Selection type" to "Radio"
- Bug: crash
[website builder refactor]: 9fe45e2b7ddbbfd0445ffe25a859e67a316d02b2
task-5238496
Forward-Port-Of: odoo/odoo#234586This update corrects an error in the Belgian VAT return XML generation, preventing rejections by the government. The issue stemmed from an outdated filter within the accounting module, leading to incorrect grid numbers being included. This fix ensures accurate VAT return submissions for Belgian companies.
Original PR description
**Steps to reproduce:** - Install accountant and l10n_be_reports - Switch to a Belgian company (e.g. BE Company CoA) - Create an Intra-Community invoice: * Customer: [EU customer] * Invoice Date:…
**Steps to reproduce:** - Install accountant and l10n_be_reports - Switch to a Belgian company (e.g. BE Company CoA) - Create an Intra-Community invoice: * Customer: [EU customer] * Invoice Date: [last month] * Fiscal Position: [Intra-Community] * Invoice Lines: [a product with "0% EU M" tax] - Confirm the invoice - Go to "Accounting / Accounting / Closing / Tax Returns" - Open the period containing the created invoice - Mark all lines as "Reviewed" - Validate the VAT Return **Issue:** In the generated XML, there is a line for grid number "46L", which should not appear. Therefore, the XML is rejected by the government. Same issue with grid number "46T". These 2 grids are sub-section of grid number "46" and should not appear in the XML. Cause: Previously, they were filtered out, but since this commit https://github.com/odoo/odoo/commit/17a6117ed88c29b5bc4db0c872bcdbc109a7d98b, the formula has changed from "46L" to "-46L" but the excluding filter has not been updated. opw-5344566
This update fixes an issue where annotations in PDF exports of Balance Sheet reports were not displayed in chronological order. The changes ensure that the oldest annotations appear first, providing a more accurate and user-friendly report. This improves the clarity and reliability of financial reporting.
Original PR description
We expect the oldest annotations to appear first when exporting to a PDF.
To reproduce:
- Go to any report such as the Balance Sheet
- Open the chatter for an account
- Post 2 messages ("first" and "second" for exemple)
- Export the report to PDF
This was introduced in https://github.com/odoo/enterprise/pull/95307This update prevents the website's product shop from showing an empty "alternative products" section. Previously, even when no alternatives were listed, the section would still appear. This change ensures a cleaner user experience by only displaying relevant product options.
Original PR description
### Issue: In this issue, alternative products section will continue to be shown in website_sale, even if the product has no alternative products, due to editing alternative products using Editor. #### To reproduce: 1- Create a product with an at least one alternative product. 2- On product shop page, using Editor, edit the description of alternative products section. 3- Remove alternative products of the product. 4- As seen, the alternative products section is still shown, even though it is empty. #### Cause: This is caused due to 9fe45e2b7ddbbfd0445ffe25a859e67a316d02b2 which commented out `display: none` for empty snippets. https://github.com/odoo/odoo/blob/d985ec2e9b61b5e6c36a278654d526aaa5b512e2/addons/website/static/src/snippets/s_dynamic_snippet/000.scss#L2-L5 opw-5253884 Forward-Port-Of: odoo/odoo#237117
This update resolves a technical error that prevented the generation of payroll export files. The fix corrects a field name mismatch, ensuring accurate retrieval of employee data. A new test suite has been implemented to guarantee the reliability of the export process and data integrity.
Original PR description
The export generation crashed due to a mismatch between field names — the code was referencing employee_ids, while the model actually defines employee_id. Since the Prisma code is now stored on the employee model, the logic was updated to correctly access the employee_id field and retrieve the related Prisma code. Additionally, a comprehensive test suite was added to validate Prisma code behavior, including: - validation of code length for employees, companies, and work entry types, - handling of codes across different companies, - and the complete Prisma export flow (from work entry creation and validation to export file generation). task-5153727 Forward-Port-Of: odoo/enterprise#101039 Forward-Port-Of: odoo/enterprise#96743
This update resolves a bug where the 'lock' action in the document previewer's action menu wasn't updating correctly. The fix ensures that the action menu reflects the current document status, providing consistent functionality for users. This improves the overall document management experience.
Original PR description
Steps to reproduce =================== - Preview any documents. - Click on the actions menu and lock the document. - Now go to the actions menu again. => The set of options is not updated. Technical =========== - The action menu, which we are using inside the file previewer, is passed explicitly inside the FileViewer component of the document. We were using the `record.load()`, which will not have any effect on the FileViewer component and that's why the action menu was not updating. After this commit ================== - Used the `this._notifyChange()` method, which closes the preview and loads the model to align with the same behaviour as other actions. Task-4988116 Forward-Port-Of: odoo/enterprise#100255 Forward-Port-Of: odoo/enterprise#91760
This update corrects an issue where fiscal year start dates were inconsistent, leading to incorrect return generation based on the current date. The fix ensures that returns are always generated with the correct fiscal year start date, regardless of the current date. This improves the accuracy of financial reporting across Belgium, New Zealand, and the UK.
Original PR description
compute_fiscalyear_dates using date.today() is wrong and can lead to different start_dates depending the current date. For instance if we create a custom fiscal_year from sept 2025 to Dec 2025 and we are currently the 10th Sept 2025. Then, we try to generate a return for January. The start date would be set to the 1st Sept. Then later, when trying to generate the same return for January 2025 but being after that custom fiscal year (for instance 20th January 2026), We get a completely different start date. The fix is to avoid using the custom fiscal years in get_start_date_elements. An improvement will be done in master to add that feature. We can also safely remove the custom start_date from the belgian localization as now it is not used anymore. See: https://github.com/odoo/enterprise/pull/100034 Forward-Port-Of: odoo/enterprise#100022
This update fixes an issue where PDF payslips generated from payruns were named 'new payslip' instead of including the employee's name and pay period. Now, payslips will correctly display 'Salary Slip - <employee name> - <time period>', ensuring accurate and professional payroll documentation. This improves the user experience and clarity of payroll reports.
Original PR description
[FIX] hr_payroll: write full name on payslip generated from payrun _ ## Short functional explanation of the error When generating a payslip from a payrun for an employee, the name of the PDF payslip…
[FIX] hr_payroll: write full name on payslip generated from payrun _ ## Short functional explanation of the error When generating a payslip from a payrun for an employee, the name of the PDF payslip is simply "new payslip" instead of "Salary Slip - <name of employee> - <time period of the slip>" ## Reproduction Steps 1. Go to Payroll and click on the Payslips tab > payslips. 2. Click on Pay Run. Select Regular Pay and click Continue. 3. Select an employee for which you'd like to generate the payslip. 4. Click on the employee row in the list view. 5. Click Compute sheet > Print. ## Expected behavior A PDF with name "Salary Slip - <employee name> - <time period>" is generated. ## Unexpected Behavior A PDF with name "new Payslip" is generated. ## Origin of the issue When printing the slip with this flow, we don't call the method ```_compute_name()``` used to compute the name of the current slip. Therefore, it stays at 'New Slip', which is the default name. Henceforth, we have to call this method manually when printing the slip. _ opw-5216796 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/enterprise#101056
This update ensures the NIF (tax identification number) is now included in the BOE export file for model 347, as required by Spanish tax regulations. Previously, the system only included VAT, but this change corrects a data omission, aligning with specific reporting requirements outlined in official documentation. Users are responsible for accurately entering the NIF in the company's VAT field.
Original PR description
[FIX] l10n_es_reports: include NIF in boe export for model 347 The NIF must be included in the BOE export for modelo 347 https://sede.agenciatributaria.gob.es/static_files/Sede/Disenyo_registro/DR_300_399/archivos/347.pdf pages 3 & 12. Before this commit, we read the vat but if it doesn't start with 'ES' we return an empty string because we based on TIN. Now we'll read the vat (without 'ES' if it starts with it). The user is responsible to fill a correct number in the vat field of the company. opw-5207241 Forward-Port-Of: odoo/enterprise#100489
This update prevents a critical error that occurred when users created or modified fields with incorrect domain settings. The fix wraps domain evaluations in a try-except block, gracefully handling invalid domains and providing a clear error message to the user. This ensures a smoother user experience and prevents data loss.
Original PR description
Currently an error is generated when the user tries to create or write fields with wrong domain. Steps to produce an error - Install sale_management and create a new field with the below detail -…
Currently an error is generated when the user tries to create or write fields
with wrong domain.
Steps to produce an error
- Install sale_management and create a new field with the below detail
- Model: `Sales order`
- Field Type: `one2many`
- Related Model: `sale.order`
- Relation Field `partner_id`
- Domain: `[('sale_order_id', 'in', sale_order_ids)]`
- Click on save
This error occurs because we have a constraint in the domain, and it is triggered
when the user modifies the domain at code line [1]. Inside this constraint, we use
`safe_eval` to evaluate the domain. During this evaluation, an error is raised because
the user entered an incorrect domain.
This commit fixes the above issue by wrapping `safe_eval` inside a `try–except`
block and raising a `ValidationError` with an appropriate message when an error occurs during domain evaluation.
[1]- https://github.com/odoo/odoo/blob/e4e2dca73213c33c487033dd404a7ca335960a66/odoo/addons/base/models/ir_model.py#L651-L654
sentry-6964956583
Forward-Port-Of: odoo/odoo#237937
Forward-Port-Of: odoo/odoo#236891This update fixes a payroll issue in Belgium where public holidays were incorrectly paid during long-term sick leaves. The fix ensures that public holidays are no longer included in pay calculations after 30 calendar days of sick leave, aligning with Belgian labor laws. This ensures accurate payroll processing for employees on long-term sick leave.
Original PR description
Bug: In Belgium, after 30 calendar days of sick leave, all public holidays during the sick leaves are no longer paid. But here they were still being paid. Cause: The method that was checking what to do about public holidays was never seeing public holidays since they were already changed to their corresponding work entries at the work entry generation. Fix: Add the public holidays in the context and change the condition for checking if the current leave is actually from a public holiday or not. Task: 3864585 Forward-Port-Of: odoo/enterprise#98661 Forward-Port-Of: odoo/enterprise#95178
This fix resolves an issue where the website page URL input field would become unstable with slow connections, causing data loss. It also corrects a related problem where the 'Redirect Old Url' element wasn't hidden when reverting to the original URL. The update ensures a smoother and more reliable user experience when editing website pages.
Original PR description
Scenario: - edit a website page (eg: /test that you create) - go to Site > Properties - have a slow connection and write in field "Page URL" for some seconds Result: the input jitter, if going too…
Scenario: - edit a website page (eg: /test that you create) - go to Site > Properties - have a slow connection and write in field "Page URL" for some seconds Result: the input jitter, if going too fast the text can be removed to get previous version. Secondary issue: if we cancel our change and set back the original URL, the "Redirect Old Url" part is not hidden. Reason: we trigger onchange at each input event, so if we write 20 letters we will possibly still have 20 onchange that are ongoing and will set back older version of the field value. The secondary issue is because we are using a field using useInputField and FieldUrl but we are hacking it to remove the "/" prefix inside the input. So when the invisible modifier is checked, we check eg. "old_url=/test" against "url=test" that are always different. With this fix: Since the triggered onchange were only to update quicker the condition `invisible="old_url == url"`, we trigger them only if that condition will change, and debounce it to prevent the now single onchange of happening in the middle of text input. And for the secondary issue, we add and remove the / when triggering the onchange. opw-4517181 Forward-Port-Of: odoo/odoo#238544 Forward-Port-Of: odoo/odoo#200016
This update resolves an issue where animation options would unexpectedly reset when re-selecting text within the website builder. The fix normalizes text formatting to ensure consistent comparisons, preventing incorrect mismatches and maintaining the intended animation state. This improves the user experience and stability of the website builder.
Original PR description
Steps to reproduce: case 1: 1. Select all text in the footer. 2. Apply an animation (e.g. slide). 3. Re-select the same text (e.g. by triple-clicking or drag-selecting). 4. Observe that the animation…
Steps to reproduce: case 1: 1. Select all text in the footer. 2. Apply an animation (e.g. slide). 3. Re-select the same text (e.g. by triple-clicking or drag-selecting). 4. Observe that the animation option resets unexpectedly. Case 2: 1. Select all text in a paragraph. 2. Apply a text highlight. 3. Re-select the same text (e.g. by triple-clicking or drag-selecting). 4. Apply an animation (e.g. on scroll). 5. Re-select the same text again. 6. Observe that the animation option resets unexpectedly. Cause: The previous comparison between `selection.textContent()` and `ancestor.innerText` did not account for differences in whitespace and formatting, leading to false mismatches even when the selected and ancestor text appeared identical. Fix: Normalized both the selection and ancestor text by collapsing multiple whitespace characters and trimming leading/trailing spaces before comparison. This ensures that visually identical text is treated as equal, maintaining the animation option state when re-selecting the same text. Forward-Port-Of: odoo/odoo#227780
This update corrects a bug in the vehicle availability calculations for the l10n_be_hr_payroll_fleet module. It now accurately excludes vehicles flagged for change (plan_to_change_car or plan_to_change_bike) with a 'False' status, ensuring they are correctly marked as unavailable. This prevents incorrect vehicle availability reporting.
Original PR description
Refine _get_available_vehicles_domain to consider only vehicles with plan_to_change_car or plan_to_change_bike set to True as available. This ensures vehicles planned for change but marked False are treated as unavailable. Related task: 4963484. Forward-Port-Of: odoo/enterprise#101266 Forward-Port-Of: odoo/enterprise#90812
This update resolves an issue preventing bank statement creation when the chart of accounts isn't properly configured. The fix ensures the system correctly identifies and associates accounts with bank statements, preventing a syntax error and improving the reliability of bank statement processing.
Original PR description
**Steps to Reproduce:** 1. Install the **Accounting** module without demo data. 2. In "**Chart of Accounts**", change the type of all accounts (e.g.; Expenses). 3. In "**Bank**" Journal, create a new bank statement line and try to save it. **Error:** ``` SyntaxError - syntax error at or near ")" LINE 19: AND aml.account_id IN () ``` **Cause:** A **IN** condition is evaluated with an empty tuple `AND aml.account_id IN ()`. This is due to that there are no `account_ids`. **Fix:** This commit ensures that the SQL query is executed only when there are remaining statement lines and valid account IDs to process. If either is missing, the method now returns early and updates `cron_last_check`. sentry-7059353053 Forward-Port-Of: odoo/enterprise#100459
This update fixes an error in the payroll calculations for Switzerland (l10n_ch_hr_payroll) where the wrong employee ID was being used. The fix ensures accurate record linking by consistently referencing the primary employee record instead of a historical version, improving payroll accuracy.
Original PR description
Commit [46052c4](https://github.com/odoo/enterprise/commit/46052c4bc5ad1bd2549a6125202e0671b56beac8) introduced the `hr.version` model, which contains historical information about an employee record. Some of the updated lines use the hr.version ID when they should use `hr.employee`. Ticket [5218215](https://www.odoo.com/odoo/project.task/5218215) Forward-Port-Of: odoo/enterprise#100079
This update fixes a reporting issue where journal items weren't correctly linked to the associated account groups. The fix ensures that reports accurately display the correct financial items for each group, improving the accuracy of financial reporting. This resolves a data discrepancy impacting financial analysis.
Original PR description
Repro steps: 1. Create account groups 2. Go to general ledger report 3. Click on 'Journal Items' of one of the account groups lines Problem: The journal items shown don't belong to the account group that it should belong to. Fix: This commit fixes this issue by adding the correct action_domain of account_id.group_id. opw-5180867 Forward-Port-Of: odoo/enterprise#100191
This update resolves an error that occurred when creating time off allocations using hours, particularly when each attendance had a defined start and end date. The fix prevents a division-by-zero error, ensuring time off allocations are created correctly. While this addresses the immediate issue, the underlying problem isn't fully resolved.
Original PR description
_ ## Short functional explanation of the error When creating a time off allocation with a time off type expressed in hours, and having start/end dates for every attendance in the corresponding…
_ ## Short functional explanation of the error When creating a time off allocation with a time off type expressed in hours, and having start/end dates for every attendance in the corresponding calendar, an error is raised. ## Reproduction Steps 1. Go to Employees and click on the Configuration tab > Working Schedules. 2. Click on a schedule and click on the button next to Work Entry Type to show the Starting date. 3. Set a starting date for each entry. 4. Go to Time Off. Click on the Configuration tab > Time Off Types. 5. Click on a time off and next to the Take Time Off in, select Hours. 6. Click on the Management tab > Allocations. Click on New. 7. Select an employee that has the schedule you updated earlier. ## Expected behavior The allocation is created. ## Unexpected Behavior A traceback occurs: ``` ZeroDivisionError: float division by zero ``` ## Origin of the issue When setting a start or/and an end date to an attendance, this attendance won't be taken into account for global attendances anymore. This leads to an erroneous computation of hours_per_day, leading to a few issues; one of them is related to time off allocation: When setting a time off with a time off type expressed in hours, if every single attendance in the calendar has a start/end date, there will be no global attendance hours left, leading to a division by 0: https://github.com/odoo/odoo/blob/8097b674a23858ed7692a0b30ca74419b8f890f7/addons/hr_holidays/models/hr_leave_allocation.py#L262 After discussion, we decided that this fix would only fix a symptom, and not the problem itself. _ opw-5340056 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#237782
This update fixes an issue where debit notes created in the Uruguayan localization were incorrectly assigned as e-invoices (type 111). The fix ensures debit notes automatically use the correct document type (113), streamlining invoice processing for Uruguayan businesses. This improves data accuracy and compliance.
Original PR description
**Steps to reproduce:** * Install and activate the **Uruguayan Localization** for the company. * Create a contact located in Uruguay. * Create an invoice for this customer and set **Document Type =…
**Steps to reproduce:** * Install and activate the **Uruguayan Localization** for the company. * Create a contact located in Uruguay. * Create an invoice for this customer and set **Document Type = 111 (e-Invoice)**. * From the invoice's gear icon, create a **Debit Note**. **Observed behavior:** * The debit note is automatically assigned **Document Type 111 (e-Invoice)**, even though it should use **113 (e-Invoice Debit Note)**. * Attempting to change the document type manually only shows 113 as an option, confirming the debit note should not have been set to 111. **Cause:** * `_compute_l10n_latam_document_type()` applies a rule that assigns Document Type **111** to all Uruguay electronic invoices with RUT identification. * This logic does **not** check whether the move is a **debit note** (`m.debit_origin_id`), and therefore incorrectly overrides the expected debit note document type. * The override prevents the correct selection (internal_type == *debit_note*) from being applied. **Fix:** * Add a condition in the automatic e-Invoice assignment logic. * Debit notes now bypass the e-Invoice assignment and fall through to the parent method, which correctly assigns **Document Type 113**. opw-5154599 Forward-Port-Of: odoo/enterprise#100938
This update resolves an error that occurred when creating time off requests. Specifically, the system would fail if a start date was removed and then the employee was changed. The fix ensures the system only checks for past dates when a start date is provided, preventing the error.
Original PR description
Currently, an error occurs when creating a time off request for an employee. Steps to Reproduce: - Install the `hr_holiday` module. - Go to `Management > Time Off`. - Create a `new time off` and…
Currently, an error occurs when creating a time off request for an employee. Steps to Reproduce: - Install the `hr_holiday` module. - Go to `Management > Time Off`. - Create a `new time off` and `remove the start date`. - Now `change the employee`. `AttributeError: 'bool' object has no attribute 'date'` This error occurs when creating a time off request for an employee. If the start date is removed and then the employee is changed, the compute method [1] runs to determine whether the time off can be approved and to update the states [2]. During this process, the system checks whether the time off date is in the past, and since the start date is missing, it results in the error [3]. This commit ensures that the system only checks whether the time off is in the past when a start date is provided. [1]- https://github.com/odoo/odoo/blob/aa53689d3c593a8a41479c51edc2b01e3c284f96/addons/hr_holidays/models/hr_leave.py#L594-L597 [2]- https://github.com/odoo/odoo/blob/aa53689d3c593a8a41479c51edc2b01e3c284f96/addons/hr_holidays/models/hr_leave.py#L1279 [3]- https://github.com/odoo/odoo/blob/aa53689d3c593a8a41479c51edc2b01e3c284f96/addons/hr_holidays/models/hr_leave.py#L1237 No Task ID --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#238281
This update corrects a bug in the aged receivable report that prevented accurate data display when invoices lacked a due date. The fix ensures the report correctly identifies outstanding invoices by aligning the date comparison logic, resolving a discrepancy between the report query and the filtering method.
Original PR description
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this…
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this entry <img width="1599" height="238" alt="image" src="https://github.com/user-attachments/assets/010f97f4-0d50-4e5a-9366-ae67d17e2bb7" /> Observation: - on clicking the entry, when redirected to list view, there are `0` records. Issue: - The query which is used to display data on report uses `COALESCE(account_move_line.date_maturity, account_move_line.date)` https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L222-L226 - while the method `_build_domain_from_period` uses only `date_maturity` in domain redirecting to list view - This creates inconsistencies between two. https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L383-L394 opw-5237298 Forward-Port-Of: odoo/enterprise#99883
This update ensures that bills received through the PEPPOL network are automatically posted to the accounting system, even when auto-post functionality is enabled for the partner. Previously, these bills remained in a draft state, requiring manual processing. This change streamlines the billing process and improves efficiency.
Original PR description
Currently, even if a partner has auto-post bills enabled, the incoming bills stay in the draft state. This change addresses that issue. Task-5373302 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#238473
This update ensures that a checkered background is consistently displayed in the color preset preview area, regardless of whether a gradient or custom color is selected. Previously, custom colors lacked this visual indicator of transparency. This improves the user experience when customizing website themes.
Original PR description
[*]=html_builder Steps to reproduce: 1. Go to website and click edit. 2. Switch to the _Theme_ tab and click on _Color Presets_. 3. Click on first color preset, then open the background color picker.…
[*]=html_builder Steps to reproduce: 1. Go to website and click edit. 2. Switch to the _Theme_ tab and click on _Color Presets_. 3. Click on first color preset, then open the background color picker. 4. Switch to gradient tab, select any gradient, and adjust the opacity. 5. Now, click on second color preset, open the background color picker. 6. Switch to the custom tab, select any color, and adjust its opacity. Issue: When a gradient is selected (first color preset), the color preset preview area correctly displays a checkered background to indicate transparency. However, when a plain custom color is selected (second color preset), the checkered transparency background is missing from the color preset preview area. Fix: Set the value of `--PreviewAlphaBg-background-size` variable as `32px`. Moreover, extended the `%o-preview-alpha-background` placeholder in the `color_picker_theme_tab.scss` file to ensure the checkered background is consistently applied for both gradient and custom color selections. | Before | After | |-----------------------------|---------------------------------| | <img width="363" height="308" alt="image" src="https://github.com/user-attachments/assets/dbb64116-70d6-4475-9d41-90c0b591efcd" /> | <img width="363" height="308" alt="image" src="https://github.com/user-attachments/assets/ea8caa90-3518-4219-a980-a2a22f2f427d" /> | task-5226064 Forward-Port-Of: odoo/odoo#234083
This update fixes a potential issue where users could inadvertently modify approval requests, leading to unpredictable system behavior. The change prevents any edits to approval requests, ensuring data integrity and stability within the approval workflow. This resolves a technical concern that could have impacted the reliability of the system.
Original PR description
There is no legitimate use case that should modify the approval request. This would result in unexpected behaviour. task-5269982 Forward-Port-Of: odoo/enterprise#101132 Forward-Port-Of: odoo/enterprise#100273
This update corrects a technical issue in the l10n_dk_nemhandel module by ensuring that Denmark-specific document type checks are applied only to Danish partners. This prevents conflicts with standard Peppol processes and ensures consistent data flow, improving the stability of the system.
Original PR description
Before: - The l10n_dk_nemhandel override of _check_document_type_support replaced the generic Peppol logic and did not accept process_type, causing errors when other localizations relied on the base method. After: - Aligned the method and applied the DK-specific logic only for Danish partners, falling back to the generic Peppol behavior otherwise. Impact: - Prevents unintended overrides towards standard Peppol flow. Forward-Port-Of: odoo/odoo#238543
This update corrects a technical issue that caused duplicate reversal and deferral entries to be created when generating deferred entries from invoices. The fix ensures that deferral periods are calculated correctly, reducing unnecessary noise in financial reports and improving data accuracy. This change primarily impacts the account accounting module.
Original PR description
When generating deferred entries from invoice lines, certain scenarios led to the creation of both a reversal and a deferral for the same amounts. These entries would effectively cancel each other out, creating unnecessary noise in the journal entries. This issue primarily occurred when the start date, end date, and accounting date all fell within the same calendar month. The problem was exacerbated by the introduction of the `full_months` computation method in https://github.com/odoo/enterprise/commit/5dca9c0c2691cba2335e110ad63a2dcc8bbf6d57. To correctly handle this method and prevent the erroneous paired entries, the end date must now be adjusted by subtracting one month when calculating the deferral period. opw-5000337 Forward-Port-Of: odoo/enterprise#101258 Forward-Port-Of: odoo/enterprise#100507
This update corrects a visual issue where the activity badge within the bank reconciliation widget was misaligned. The fix removes unnecessary styling code, ensuring the badge now correctly aligns with the icon. This improves the user experience and visual consistency of the bank reconciliation feature.
Original PR description
Current behavior before PR: The activity badge inside the bank reconciliation widget was misaligned, <img width="55" height="60" alt="image" src="https://github.com/user-attachments/assets/0f99ea55-fedd-401a-a65e-226296070e32" /> Desired behavior after PR is merged: The activity badge now sits in the correct position on the icon. <img width="62" height="55" alt="image" src="https://github.com/user-attachments/assets/abf96aed-73d4-4153-8e0a-56937d4ff08a" /> Changes implemented: - Removed `fa-fw` class. - Removed the unnecessary 'fa-fw' class from comment and paperclip icon. task-5354994 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/enterprise#100573
This update resolves an issue where the 'Import Records' function within the Master Production Schedule (MPS) module wasn't working correctly. The fix ensures that initialization for client actions, triggered by the MPS feature, is properly executed, allowing users to import records as intended. This improves the usability of the MPS workflow.
Original PR description
Steps to reproduce: ------------------- 1. Install mrp_mps 2. Go to Inventory > Operations > Procurement > MPS 3. Click "Toggle search panel"(▼) 4. Click “Import Records” Issue: ------ Nothing…
Steps to reproduce: ------------------- 1. Install mrp_mps 2. Go to Inventory > Operations > Procurement > MPS 3. Click "Toggle search panel"(▼) 4. Click “Import Records” Issue: ------ Nothing happens when clicking “Import Records”. Cause: ------ After this 646bee6, initialization moved to `onWillStart()`, but it only runs when the current action type is `ir.actions.act_window`. MPS triggers the import from a [client action](https://github.com/odoo/enterprise/blob/142d86ad89435cd0751e9865ff62e8263a67e060/mrp_mps/views/mrp_mps_menu_views.xml#L4-L9), so the condition returns early and [get_import_templates](https://github.com/odoo/odoo/blob/f272eb19813be4254fd461ec21f1cc47e8834559/addons/base_import/static/src/import_model.js#L238) never loads. Solution: --------- Allow initialization for client actions as well, same as window actions. Reference: MPS(Master Production Schedule) opw-5248073 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update corrects a bug preventing ECPay invoice generation in version 19.0. The previous system attempted to access a removed field, causing an error. The fix removes the outdated field reference and now utilizes the standard 'phone' field for contact information, ensuring reliable ECPay integration.
Original PR description
**Steps to reproduce:** 1. Install l10n_tw_edi_ecpay. 2. Switch to the TW company. 3. Go to Configuration → search for "ECPay". 4. Enable staging mode. 5. Enter all credentials. 6. Create a new…
**Steps to reproduce:**
1. Install l10n_tw_edi_ecpay.
2. Switch to the TW company.
3. Go to Configuration → search for "ECPay".
4. Enable staging mode.
5. Enter all credentials.
6. Create a new invoice → select “Taiwan Semiconductor” as customer → set an email and leave the phone field empty.
7. Add a product → confirm → click “Send” → select only “Send to ECPay” → send.
> You can find ECPay testing credentials here : https://developers.ecpay.com.tw/?p=24174
**Issue:**
A traceback occurs while sending the e-invoice:
`AttributeError: 'res.partner' object has no attribute 'mobile'`
**Cause:**
In commit https://github.com/odoo/odoo/commit/6b820eb6fc6f782ba6a83d605d87b4a1dd2a87be the `mobile` field was removed from `res.partner`. The ECPay integration still attempted to read `partner.mobile`, which causes the traceback on versions where the field no longer exists.
Additionally, the code was still using the deprecated `self._cr` cursor reference, which was replaced by `self.env.cr` as part of the cleanup in: https://github.com/odoo/odoo/pull/193636/commits/ad7606195a4ba44bf9854506bf2e305d3dd13dbb
**Fix:**
Remove the reference to the obsolete `mobile` field and rely solely on the `phone` field, which is the only supported contact number field in 19.0.
Also replace deprecated `self._cr` with `self.env.cr`
**opw-5357429**The timesheet grid now accurately reflects company working schedules with flexible hours enabled. Previously, it incorrectly displayed unavailable days, but this update ensures all days are considered working, resolving a confusing and inconsistent user experience. This improvement provides accurate timesheet availability for teams using flexible work arrangements.
Original PR description
**Description** When a company's working schedule has flexible hours enabled, the timesheet grid was incorrectly displaying random weekdays as non-working days (greyed out cells). The affected days…
**Description** When a company's working schedule has flexible hours enabled, the timesheet grid was incorrectly displaying random weekdays as non-working days (greyed out cells). The affected days varied by month because the unavailability calculation was time-dependent. **Steps to reproduce** 1. Enable flexible hours on company's working schedule 2. Go to Timesheets > All timesheets 3. Switch to Grid view and filter by month 4. Observe that random weekdays (e.g., Wed/Thu or Mon/Tue) are greyed out **Fix** The grid_unavailability method now checks if the company calendar has flexible_hours enabled. When true, it returns an empty list of unavailable days, treating all days as potential working days. This fix adds the flexible_hours check in two locations within the grid_unavailability method to cover all code paths: 1. get_company_unavailable_dates() helper function - prevents unnecessary calculation when called as fallback 2. company_unavailable_days assignment from calendar_work_intervals - handles the direct path when company calendar is found This follows the same pattern as the gantt view fix #100385 opw-5215646 Forward-Port-Of: odoo/enterprise#100881
7 changes
New functionality added to Odoo
This update enhances the Point of Sale (POS) experience by allowing offline ticket number generation, utilizing local storage for backup. Additionally, the update hides specific buttons (Orders and Cash In/Out) for cashier roles in the navigation bar, streamlining the user interface for common tasks.
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
This pull request enhances the mobile ordering experience and introduces new functionality within the custom module. Specifically, it streamlines the mobile ordering process and expands the capabilities of the custom module, allowing for more flexible configuration and management. These changes aim to improve user convenience and expand the versatility of the Odoo platform.
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
Resolved issues and error corrections
This update fixes an issue where the 'Journal Items' link in the general ledger report incorrectly displayed items not associated with the selected account group. The fix ensures that the report accurately shows journal items belonging to the correct account group, improving report accuracy and data reliability.
Original PR description
Repro steps: 1. Create account groups 2. Go to general ledger report 3. Click on 'Journal Items' of one of the account groups lines Problem: The journal items shown don't belong to the account group that it should belong to. Fix: This commit fixes this issue by adding the correct action_domain of account_id.group_id. opw-5180867 Forward-Port-Of: odoo/enterprise#100191
This update resolves a bug where the aged receivable report was not displaying correct data for invoices without a due date. The fix ensures the report accurately reflects outstanding balances by aligning the data source used in the report with the invoice's date. This improves report accuracy and data reliability.
Original PR description
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this…
step to reproduce: - create a invoice and confirm it - remove due date from it and save it - ensure the confirmed invoice do not payment term or due date - open aged receivable report - open this entry <img width="1599" height="238" alt="image" src="https://github.com/user-attachments/assets/010f97f4-0d50-4e5a-9366-ae67d17e2bb7" /> Observation: - on clicking the entry, when redirected to list view, there are `0` records. Issue: - The query which is used to display data on report uses `COALESCE(account_move_line.date_maturity, account_move_line.date)` https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L222-L226 - while the method `_build_domain_from_period` uses only `date_maturity` in domain redirecting to list view - This creates inconsistencies between two. https://github.com/odoo/enterprise/blob/ffc329e4ff2bd6512164ecd4206210fd5c9264b9/account_reports/models/account_aged_partner_balance.py#L383-L394 opw-5237298 Forward-Port-Of: odoo/enterprise#99883
This update prevents users from accidentally triggering email sends when using the 'Send' button in the Email Marketing app. Previously, clicking 'Cancel' while the email was in the 'In Queue' state didn't stop the immediate sending process. The fix hides the 'Cancel' button during immediate scheduling to avoid this unintended behavior.
Original PR description
**Steps to reproduce:** - Go to `Email Marketing` app - Create a new marketing campaign - Click on `Send` button - `Cancel` button appears during `In Queue` state - Clicking `Cancel` set the state back to draft - Mails are sent out anyway **Issue:** As the mails are added directly when clicking the `Send` button, they are sent out immediately (added to the queue and cron job is triggered). While `Cancel` button is still clickable (unless the page is refreshed), it has no effect on the mailing itself (it just changes the state to `Draft`). **Fix:** Hide `Cancel` button when sending directly. We could also consider adding a short delay to allow users to cancel their campaign. opw-4937725 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fix resolves an issue where reordering rules would incorrectly attempt to update locked manufacturing orders (MOs) after a quality check was completed. The update was prevented in newer versions by a change in how the system handles state transitions. This ensures the system correctly handles MOs that are blocked due to quality checks, preventing errors and maintaining data integrity.
Original PR description
### Issue: In 18.0-18.2, for product with a Manufacturing BoM containing a Component, a WO and a Quality Point If a Reordering Rule is triggered, odoo try to add the newly ordered quantity to an…
### Issue: In 18.0-18.2, for product with a Manufacturing BoM containing a Component, a WO and a Quality Point If a Reordering Rule is triggered, odoo try to add the newly ordered quantity to an existing MO But if the MO is "locked" because a quality check has been performed, a Error is raised: ``` Odoo Warning You cannot update the quantity to do of an ongoing manufacturing order for which quality checks have been performed. ``` ### Steps to reproduce: - Create a product tracked by quantity - Add a BoM (1 component tracked by Quantity, 1 Operation with 1 Quality Point) - Create a Reordering Rule (Route: Manufacture, Trigger: Manual, Min/Max: 1) - Click on Order - Open the created MO and the Shop Floor (Remove the filters to see the WO) - Complete the Quality Point - Modify the Reordering Rule (Min/Max: 2) - Click on Order - the error should be raised ### Cause: The MO to update is retrieved here: https://github.com/odoo/odoo/blob/45184da06cf7b92a48e3e4e90bf8b285bdd9ad6a/addons/mrp/models/stock_rule.py#L53-L57 Using a domain defined in this function: https://github.com/odoo/odoo/blob/45184da06cf7b92a48e3e4e90bf8b285bdd9ad6a/addons/mrp/models/stock_rule.py#L130-L153 In 18.0-18.2, when validating a `quality check` from the Shop Floor while the WO is in `waiting` state, the MO remains in `confirmed` state This makes the domain match the current WO and MO, triggering `change_prod_qty` even though the MO is locked In 18.3–18.4, a similar issue can occur with multiple WOs when the first blocks the second and a `quality check` is performed on the latter The `blocked` state behaves like `waiting`, but the issue is avoided when using the Shop Floor because this commit ensures that clicking a card starts the timer and changes the state to `progress`: 67c2127 However, it could still theoretically be triggered under specific conditions In 19.0, the new stock.reference system (odoo/odoo#212679) ensures the MO is detected as different, so a new one is always created opw-5012588 enterprise: https://github.com/odoo/enterprise/pull/101313
This update resolves an issue where by-products weren't correctly registered during multi-step manufacturing processes. The fix ensures that by-product lines are created with the correct pre-production and production locations, streamlining the manufacturing workflow. This issue is now resolved in version 18.0.
Original PR description
### Steps to reproduce: - In the settings enable By-Products an Multi-step routes - Put your warehouse in manufacturing in 3 steps - Create two storable products: - Final Product (FP) with an empty…
### Steps to reproduce:
- In the settings enable By-Products an Multi-step routes
- Put your warehouse in manufacturing in 3 steps
- Create two storable products:
- Final Product (FP) with an empty bom
- By Product (BP)
- Go to the barcode app > Operations > Manufacturing > New
- Scan FP > Register By-Products
- Scan BP
#### > The line is created with pre-prod as location and prod as destination
### Cause of the issue:
Since no existing line refers to the by product, a new line is created and its `location_id` and `location_dest_id` are provided by the `_getNewLineDefaultValues`:
https://github.com/odoo/enterprise/blob/17fd46b04d87585b7ed46c00d9559414daa17384/stock_barcode/static/src/models/barcode_model.js#L562-L566 However, at this point nothing had set the `params.newByProduct` in the `processBarcode`:
https://github.com/odoo/enterprise/blob/17fd46b04d87585b7ed46c00d9559414daa17384/stock_barcode_mrp/static/src/models/barcode_mrp_model.js#L375-L383 In fact, the only thing indicating that we are creating a by prodcut line at this point is the `displayByProduct`.
### Note:
The issue is no longer reproducible in 18.0+ as this change has already been applied in 2d5dbb93e6b33c2be786f9b2361c993f715d1a7f
opw-5350222
Forward-Port-Of: odoo/enterprise#1010872 changes
Enhancements to existing features
This update ensures that newly imported partner records are automatically identified as 'companies' within Odoo. This is crucial for accurate accounting and reporting related to electronic invoices (UBL-CII) and simplifies the process of matching imported transactions with company data. It addresses a previous issue where imported partners weren't correctly categorized.
Original PR description
Ensure imported partner records are marked as companies when creating new partners. Task-5353923 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Resolved issues and error corrections
This update fixes an accounting error related to invoice processing for 'Unearned Revenue' (account 3387). Previously, the system incorrectly created both receivable and payable entries. By changing the account type, the system now accurately reflects 'Unearned Revenue' as a current liability, ensuring correct balance sheet reporting.
Original PR description
When posting an invoice, the system creates: - Journal Entry: Dr 131 (Receivable) / Cr 511 Then the system creates a deferral entry: - Deferral entry: Dr 511 / Cr 3387 (Payable) Falsifying the…
When posting an invoice, the system creates: - Journal Entry: Dr 131 (Receivable) / Cr 511 Then the system creates a deferral entry: - Deferral entry: Dr 511 / Cr 3387 (Payable) Falsifying the Balance sheet report, in the accounts receivable and accounts payable indicators The issue was that account 3387 was configured as `Payable`, which caused the system to generate both Receivable (131) and Payable (3387) for the same partner. This is incorrect because account 3387 represents "Unearned Revenue", which is a current liability, not a payable account. By changing the account type from `Payable` to `Current Liabilities`, the deferral entry now correctly reflects that 3387 is a current liability account, preventing the incorrect reconciliation behavior where both receivable and payable entries were created for the same partner. After this fix: - Entry: Dr 131 (Receivable) / Cr 511 - Deferral: Dr 511 / Cr 3387 (Current Liabilities) 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