Daily updates from Odoo
Wednesday, September 17, 2025
5 changes · 17.0
Enhancements to existing features
Accounting KPI summaries now count posted bank journal entries linked to unreconciled bank statements. This gives businesses a more complete view of outstanding bank activity and improves the reliability of financial indicators.
Original PR description
### [REF] account: reorganize kpi.provider tests The account test_kpi_provider was already getting complicated, and this commit aims to simplify it by breaking it into smaller tests that show more clearly what is expected. Task-id: 5062431 ### [IMP] account: make kpi.provider report unreconciled bank statements The `kpi.provider:get_account_kpi_summary` method should include posted moves of a bank journal that are related to an unreconciled bank statement. Task-id: 5062431 Forward-Port-Of: odoo/odoo#227605
Resolved issues and error corrections
Users can no longer accidentally upload documents while viewing the trash folder, even if a slow connection briefly shows the upload option. This prevents upload errors and keeps the document uploader usable after failed upload attempts.
Original PR description
Currently, an error occurs when a user uploads a file in `TRASH`.
Stack Trace:
```
ValueError: invalid literal for int() with base 10: 'TRASH'
File "home/odoo/src/enterprise/saas-17.2/documents/controllers/documents.py", line 132, in upload_document
'folder_id': int(folder_id),
```
The user was not allowed to upload the file to the trash (the upload button was disabled when the user was in the trash folder), but due to the low speed of the internet, the button was visible a few times during this time, and users were able to upload the file after switching the normal folder to trash.
This commit will fix the above issue by not allowing uploads of files when users are in the `TRASH` folder. Also updated is the code to ensure that always reset file input value to ensure the file uploader works after upload fails due to not length or trash folder.
sentry-5565009205The Moroccan payroll update process now reloads required partner information before payroll rules are updated. This prevents scheduled payroll data updates from failing if the National Social Security Fund partner record was deleted, improving reliability for payroll administrators.
Original PR description
Currently an exception was generated when the user deleted partner 'National Social Security Fund' and tries to run CRON `Payroll: Update data`.
Error:
`KeyError: ('ir.model.data', <function IrModelData._xmlid_lookup at 0x70b447a20720>, 'l10n_ma_hr_payroll.hr_CNSS_register')`
This is because above CRON tries to update data from a file. Record id "l10n_ma_hr_payroll_rules_employee_cnss" which is used above the partner record reference (see [1]) but the user already deleted the partner.
This commit will fix the above issue by loading partner data before loading payroll rule data. It is always ensured partner data was available before loading payroll rule data.
[1] - https://github.com/odoo/enterprise/blob/348d404ef738e9a4008eda7f4a829b2c00649317/l10n_ma_hr_payroll/data/hr_salary_rule_data.xml#L169
sentry-5877715925Payroll users with Administrator access can now cancel payslips that are marked as done. This fixes an access check that incorrectly required full system administrator status, helping payroll teams complete corrections without unnecessary escalation.
Original PR description
steps to reproduce: ------------------- 1. Install payroll 2. Create a user and grant "Administrator" access to Payroll. 3. Log in as the new user and try to cancel a 'Done' payslip. issue: ------ A UserError is raised: "Cannot cancel a payslip that is done." observation: ------------ A user with Payroll "Administrator" access is unable to cancel a payroll payslip cause of the issue: ------------------- During cancellation, the system checks whether the user is "Admin" instead of verifying if the user has Payroll "Administrator" access. https://github.com/odoo/enterprise/blob/13832d80570956e504e1c09f41acbeb0bc4baedc/hr_payroll/models/hr_payslip.py#L509-L513 solution: ---------- Check that the user has Payroll "Administrator" access. opw-5040029
The Spanish Mod347 tax report now correctly includes withholding tax amounts when calculating report totals. This prevents understated figures for customers or suppliers with withholding taxes, improving the accuracy of Spanish tax reporting.
Original PR description
Withholding taxes should be taken into account in mod347 tax report. Steps: - Create a bill for a spanish customer - Set the amount of 40000, tax 21% and 15% withholding tax - Go to mod347 tax report -> Line "B - Sales of goods and services greater than 3.005,06 €" is showing 42,400.00 instead of 48,400.00 (same goes for other lines with similar configuration) Before this commit, custom engines domains were only including aml with payable or receivable account. With this commit, we include tax lines that are of type 'retencion' in the custom engines domains. opw-4448662