Daily updates from Odoo
Tuesday, March 3, 2026
11 changes · master
Resolved issues and error corrections
This update resolves an issue where the Colombian electronic invoicing system (l10n_co_dian) didn't properly handle mismatched DIAN operation modes. When the selected mode doesn't align with the system's expectations, a warning is now triggered to prevent incorrect invoice generation. This ensures compliance and accurate electronic invoicing.
Original PR description
Steps to reproduce: - Install `l10n_co_dian` module(demo data) > Switch to `CO Company` - Settings > Colombian Electronic Invoicing > Change the Operation Mode: `DIAN 2.1: Support Documents`(eg:…
Steps to reproduce:
- Install `l10n_co_dian` module(demo data) > Switch to `CO Company`
- Settings > Colombian Electronic Invoicing > Change the Operation Mode: `DIAN 2.1: Support Documents`(eg: [Image](https://www.awesomescreenshot.com/image/58874464?key=0cb74e446dcdb0f087df6ed619f785c2))
- Vendors > Create a Bill > Confirm > `Acknowledge Reception`
Traceback:
```py
File "/home/odoo/src/enterprise/saas-19.1/l10n_co_dian/models/account_move.py", line 293, in l10n_co_dian_send_event_update_status_received
self._l10n_co_dian_send_event_update_status('received')
File "/home/odoo/src/enterprise/saas-19.1/l10n_co_dian/models/account_move.py", line 313, in _l10n_co_dian_send_event_update_status
document = self.env['l10n_co_dian.document']._send_commercial_event(self, commercial_state_next)
File "/home/odoo/src/enterprise/saas-19.1/l10n_co_dian/models/l10n_co_dian_document.py", line 593, in _send_commercial_event
xml, errors = self.env['account.edi.xml.ubl_dian']._export_co_send_event_update_status_invoice(locked_move, commercial_state_next)
File "/home/odoo/src/enterprise/saas-19.1/l10n_co_dian/models/account_edi_xml_ubl_dian.py", line 1208, in _export_co_send_event_update_status_invoice
return self.with_context(l10n_co_next_commercial_state=next_commercial_state)._dian_sign_xml(xml, invoice)
File "/home/odoo/src/enterprise/saas-19.1/l10n_co_dian/models/account_edi_xml_ubl_dian.py", line 1524, in _dian_sign_xml
'software_security_code': self._dian_get_security_code(operation_mode, document_number),
File "/home/odoo/src/enterprise/saas-19.1/l10n_co_dian/models/account_edi_xml_ubl_dian.py", line 1443, in _dian_get_security_code
operation_mode.dian_software_id
TypeError: unsupported operand type(s) for +: 'int' and 'str'
```
We are getting this error because `_dian_get_operation_mode` [returns] an empty `l10n_co_dian.operation_mode()` record. This happens when the `Operation modes` do not match. As a result, [operation_mode] also contains an empty record.
[operation_mode]: https://github.com/odoo/enterprise/blob/84022deef3414096fcaf61f8d45c08393431e0ab/l10n_co_dian/models/account_edi_xml_ubl_dian.py#L1432
[returns]: https://github.com/odoo/enterprise/blob/84022deef3414096fcaf61f8d45c08393431e0ab/l10n_co_dian/models/account_edi_xml_ubl_dian.py#L1394-L1400
sentry-7273771732
Forward-Port-Of: odoo/enterprise#107885This update fixes a mobile map issue where the pin list was too small, making it unusable. The team replaced the permanent list with a toggle button for on-demand access, and added styling improvements for a better mobile experience. This ensures maps are easily viewable and functional on mobile devices.
Original PR description
**Problem:** Recent changes (https://github.com/odoo/enterprise/pull/104618) broke the mobile map layout, causing the pin list to shrink to an unusable 46px height on top of the map. **Solution:** Replaced the permanent list section with a toggle button to access the pin list on demand. Added polishing CSS to improve the general mobile aesthetic and usability of the map view. task-5126312 Forward-Port-Of: odoo/enterprise#108345
This update resolves an issue where users were encountering errors when processing after-departure payments. Now, a clear and informative message is displayed if a previous payslip isn't linked, guiding the user to correctly set up the payment. This improves the user experience and prevents data inconsistencies.
Original PR description
For after departure payment to work, a previous payslip is required in the system. So, instead of having a traceback, display an informative message to the user. task-5933607 Forward-Port-Of: odoo/enterprise#108980 Forward-Port-Of: odoo/enterprise#107386
This update resolves an issue where the scheduling dialog was incorrectly filtering out unscheduled shifts for resources. The fix removes a default filter, ensuring planners can now see and assign all available shifts, improving scheduling efficiency. This change corrects a previous bug that prevented accurate shift assignment.
Original PR description
Steps to Reproduce ------------------ 1. Open the Planning Gantt view. 2. Click a cell that belongs to a resource with **no** scheduled shifts. 3. The Plan dialog opens with an empty list. Issue…
Steps to Reproduce ------------------ 1. Open the Planning Gantt view. 2. Click a cell that belongs to a resource with **no** scheduled shifts. 3. The Plan dialog opens with an empty list. Issue ----- A previous change keeps the clicked resource in the dialog context; the Gantt model turns it into a default search filter, so only shifts already linked to that resource are shown. Unassigned shifts are therefore hidden, preventing planners from assigning them by role or availability. Current Behaviour ----------------- The Plan dialog is always filtered by `resource_id`, which returns no results for unscheduled resources, even when they have the right roles. Expected Behaviour ------------------ The dialog should list all unscheduled shifts that match the resource’s roles, or every unscheduled shift if the resource has no roles, while still preserving full context for scheduling once a shift is selected. Fix --- Remove the automatic resource filter from the dialog context in `getSelectCreateDialogProps()`. This prevents the unwanted search restriction; role defaults remain, so the dialog now displays the correct shifts. Task-4922525 Issue – https://github.com/odoo/enterprise/pull/87424/commits/a218a7cedce61f992fbe76284c273be8f937d28d Forward-Port-Of: odoo/enterprise#92100
This update fixes an error in how holiday pay recovery is calculated for employees in Belgium with non-standard working schedules. Previously, the system used a default 38-hour week, leading to inaccurate deductions. Now, the system correctly uses the employee's actual weekly hours (40) to ensure accurate holiday pay recovery amounts.
Original PR description
**Steps to Reproduce:** 1 - create an employee in Belgium company with hourly rate 20.62 and 40h/week working schedule 2 - Set 10 paid time off to this employee 3 - Set 2000 euros in recovery amount…
**Steps to Reproduce:** 1 - create an employee in Belgium company with hourly rate 20.62 and 40h/week working schedule 2 - Set 10 paid time off to this employee 3 - Set 2000 euros in recovery amount holiday n-1 4 - Set 10 days in recovery day holiday n-1 5 - Employee takes 5 paid time off in February and 5 in December 6 - Do one payslip for this employee for February and validate it 7 - Do one payslip for this employee for December Current behaviour : - the holiday n-1 amount for February = 824.80 - the holiday n-1 amount for December = 742.32 Expected behaviour : - the holiday n-1 amount for December should be 20.62 (hourly_rate) * 5 (days) * 8 (hours) = 824.80 **Reason** - The daily recovery amount was calculated using hardcoded standard working hours (38h/week) instead of the employee's actual schedule (40h/week), causing an incorrect deduction rate for non-standard schedules. **Solution** - Replace the hardcoded reference with the actual hours per week from the employee's resource calendar to ensure the correct hourly rate is applied. Forward-Port-Of: odoo/enterprise#109069 Forward-Port-Of: odoo/enterprise#106205
This update fixes an issue where salary rules were incorrectly reducing both employee and employer costs. A new ‘Net Cost’ salary rule has been added to accurately reflect employer contributions, ensuring correct cost calculations for payroll reporting.
Original PR description
## Before: - Setting appears_on_employee_cost_dashboard to True on a salary rule uses the rule’s sign to compute employee cost. - For rules like Social Insurance Employee Contribution and DEWS Employee Contribution, the sign must be negative to deduct the amount from the employee, which incorrectly reduces the employer cost as well. ## After: - Introduced a new salary rule “Net Cost” to correctly reflect employer cost. - This allows employee contribution rules to keep a negative sign for deductions while still increasing the employer contribution amount. Task-5912761 Forward-Port-Of: odoo/enterprise#107090
This update corrects a bug that prevented payslip PDFs from being created correctly during pay run validation. The change ensures PDFs are generated for pay runs with 5 or fewer payslips, addressing a previous limitation that only triggered PDF creation for single payslips. This improves the reliability of payslip document generation.
Original PR description
Due to a missplaced argument in the js definition of the Validate button of the Pay Run view, context indicating the need for the creation of the pdfs of the payslips was not passed correctly, resulting in their missed creation, both immediately and later by the cron. Also, previously the pdfs were only computed right away if the pay run included only 1 payslip, which almost never happens. Here we change that condition to computing the pdfs if there are <= 5 payslips. Task: 5498819
This update corrects a technical issue where the new booking view for POS appointments was inadvertently replacing standard calendar event views, causing compatibility problems with other modules. By restricting the new view to use 'primary' mode within the POS, this fix ensures proper functionality and avoids disruption to other parts of the system.
Original PR description
The list view in pos appointment would replace the original list view on calendar event and break other modules. This PR will add the `primary` mode for the new view so it is only used inside the POS Runbot Error: [234914](https://runbot.odoo.com/odoo/runbot.build.error/234914) Forward-Port-Of: odoo/enterprise#107132
This update prevents users from canceling subscriptions if they don't have access to the associated invoices. Previously, a sales representative could cancel a subscription even without seeing the invoices. Now, the system ensures cancellation is only possible when the representative has full visibility of the invoices, improving subscription management reliability.
Original PR description
Before this commit, when a user had access to an invoiced subscription but not to the invoiced, he could cancel the subscription. Step to reproduce: - create a subscription in company A, with a pricelist available in company B. Sales person A belong to company A. - invoice the subscription and confirm the invoice - update the company (company B) and sales person of the subscription (B). The new salesperon don't see the invoice in the stat button. After this commit salesperson B can't cancel the subscription. task-5907345 Forward-Port-Of: odoo/enterprise#108550 Forward-Port-Of: odoo/enterprise#106441
This update resolves an issue where payslips wouldn't generate correctly when an employee changed contracts within a pay period. The fix ensures the system uses the employee's initial contract start date for accurate calculations, preventing errors related to holiday entitlements and year-of-service calculations. This improves payroll accuracy for employees with multiple contracts.
Original PR description
An error is thrown when we try to generate a payslip for an employee that changed contract on a period before the contract change Steps to reproduce: 1. Install l10n_mx and l10n_mx_hr_payroll modules…
An error is thrown when we try to generate a payslip for an employee that changed contract on a period before the contract change
Steps to reproduce:
1. Install l10n_mx and l10n_mx_hr_payroll modules
2. Switch to INNOVACION VALOR... company
3. Go to Employees and open Cecilia Miranda Sanchez
4. Go to Payroll tab, set the end of the contract to Jan 31 and save
5. Create a new contract from Feb 1
6. Go to Payroll > Payslips > Payslips and create a new pay run
7. Select Salary Structure 'Mexico: Regular Pay', Pay Schedule 'Bi-weekly' and Period 'Jan 1 -> Jan 15'
8. Click on Continue, select Cecilia and click on Select
9. An error is thrown
Problem:
In `_compute_integration_factor` we try to compute the number of years the employee has worked by accessing the start date on the employee but this date might be earlier than the start date of the employee's current contract if the employee has changed contract. This will throw an error when we try to access the holidays count for 0 year because `payslip._rule_parameter('l10n_mx_holiday_tables')` doesn't have an entry for 0
Solution:
Use the start date of the first contract of the employee, take gaps in between the employee's contracts into consideration to correctly compute the number of years worked
opw-5931355
Forward-Port-Of: odoo/enterprise#108495This update simplifies the process of adding employees to work orders. Previously, the automatic creation of employee profiles was removed, causing issues. Now, a popup allows quick creation of employee profiles with the current user's ID pre-filled, and automatically creates employees with HR access for shopfloor operators.
Original PR description
In 19.1, the automatic creation of an employee profile for the admin user has been removed. This causes issues when the admin wants to start a workorder or mark it as done, so we added a popup to create a new employee profile with the user_id already filled with the id of the current user. Also, if no employee exist when editing operators in the shopfloor, the popup proposes to directly create a new employee linked to the current user if they have HR access. This new employee will be directly logged in the shopfloor operators. see https://github.com/odoo/odoo/pull/250607 to make `action_create_employee` return an employee record. task 5932500 Forward-Port-Of: odoo/enterprise#107439