Tuesday, December 17, 2024
6 changes · 18.0
Resolved issues and error corrections
This fixes an issue where some Calendar email templates could show an unintended blue background. The change ensures template formatting is saved in a browser-friendly way, so emails display as intended for users.
Original PR description
Steps to reproduce ----- 1. On a fresh database, install Calendar 2. Go to Email Templates > "Calendar : Event update" ** The content of the mail has a blue background ** Cause ----- Since commit 24731938f75358fd3c72b91465b72ab80d62d208, the `body_html` of the `mail.template` is stored in a xhtml format while it was previously saved in HTML. This means self-closing t tags, which were previously saved as `<t></t>`, are now saved as <t .../> in database. Since self closing t tags are not valid HTML, they get turned into opening t tags when viewed as HTML and the `data-oe-t-inline` attribute that prevents the blue background color styling to be applied are not present on these t tags. Solution ----- In case `output_format` is xml, transform the self closing t tags into empty elements which will be valid html. opw-4348482
This fixes an error that occurred when users started a timesheet timer, chose a Helpdesk project, and then selected a task. The Timesheets kanban view now includes the needed company information again, preventing the crash and keeping time tracking workflows uninterrupted.
Original PR description
Steps to reproduce: - In Timesheets app, go to kanban view. - Start the timer. - Select any Helpdesk project. - Try to select a task. Issue: - A traceback is thrown. Fix: - It is due to the fact that company_id field is removed from the kanban xml. - Thus not getting the value is throwing out a traceback. Solution: - Inject back the field into the kanban view. Issue from the PR: https://github.com/odoo/odoo/pull/172375 task-4382051
Fixes an issue where filtering or grouping accounting data by distributed analytic accounts did not actually narrow the results. Users can now rely on journal item filters and balance sheet horizontal groups to show the correct figures per analytic account.
Original PR description
**Steps to reproduce:** - Install Accounting - Create an analytic plan (e.g. XYZ) - Create 2 associated analytic accounts (e.g. XYZ_1 and XYZ_2) - Create a journal entry with the first analytic…
**Steps to reproduce:**
- Install Accounting
- Create an analytic plan (e.g. XYZ)
- Create 2 associated analytic accounts (e.g. XYZ_1 and XYZ_2)
- Create a journal entry with the first analytic account:
* Journal: Miscellaneous Operations
* Journal Items:
| Account | Analytic Distribution | Debit | Credit |
| ------------- | ------------ | ----------------- | --------------------- |
| 101000 Current Assets | XYZ_1 | 100 | 0 |
| 600000 Expenses | | 0 | 100 |
- Create another journal entry with the second analytic account:
* Journal: Miscellaneous Operations
* Journal Items:
| Account | Analytic Distribution | Debit | Credit |
|----------------|-----------------|---------------|---------------|
| 101000 Current Assets | XYZ_2 | 200 | 0 |
| 600000 Expenses | | 0 | 200 |
**Use case 1:**
- Go to "Accounting / Accounting / Journal Items"
- Add a custom filter: [("Distribution Analytic Account", "is in", "XYZ_1")]
**Issue 1:**
Nothing happens. The filter doesn't work.
**Use case 2:**
- Go to "Accounting / Configuration / Accounting / Horizontal Groups"
- Create a group:
* Reports: Balance Sheet
* Field: Distribution Analytic Account
* Domain: [("Plan", "is in", "XYZ")]
- Go to "Accounting / Reporting / Statement Reports / Balance Sheet"
- Set Horizontal Group to the created one
**Issue 2:**
A grouping is done by analytic account (visually) but no filter is done on the data.
The value on all the columns are the same.
The configuration of field "Distribution Analytic Account" in the horizontal group doesn't apply.
**Cause:**
`distribution_analytic_account_ids` is a computed field without a search defined.
opw-4302877
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prFixed an issue where POS preparation screens could go blank when an order included notes spanning multiple lines. Staff can now view and process these orders normally, reducing disruption in kitchen or preparation workflows.
Original PR description
Steps to reproduce: - Create a pos order with multiple line order notes - Send the order to preparation - Open preparation display screen Current behaviour: - Blank preparation display screen Expected behaviour: - Show the order with mutliple lines order notes Explanation: - Order note is using split to display the note in point form. So inside the t-foreach loop, the t-key should be the value of the splited note value. Instead of using generate_note which is underfined. If multiple lines of order note, all lines generate_note will be underfined thus error thrown because t-key needs to be unique. X-original-commit: de85be7
Deleting a folder and its contained documents from Trash no longer triggers an error when both are selected together. This helps users clean up archived Documents records reliably without interruption.
Original PR description
Currently, an exception is generated when the user archives a document and its folder and tries to delete both folder and document once from Trash. Steps to produce: - Open document and create folder…
Currently, an exception is generated when the user archives a document and its folder and tries to delete both folder and document once from Trash. Steps to produce: - Open document and create folder and add document in folder - Now delete document and folder - Go to Trash > open list view > Select all records > Click on Delete error ``` MissingError: Record does not exist or has been deleted. (Record: documents.document(1,), User: 1) ``` This is because 'to_delete' contains all documents (self), including the folder that we deleted, and `removable_parent_folders` contains only the folder that we deleted. Now when cleaning records, [1] unlinks all files, including folders, and [2] again tries to delete the folder that we already deleted with [1]. This commit will fix the above issue by filtering `removable_parent_folders` now it is filtering records folders thats id not in self ids. [1] - https://github.com/odoo/enterprise/blob/5ba1aa66ab17d686da648025c8921995938115ed/documents/models/documents_document.py#L1935 [2] - https://github.com/odoo/enterprise/blob/5ba1aa66ab17d686da648025c8921995938115ed/documents/models/documents_document.py#L1941 sentry-6048388238
Canceled invoices are no longer counted when calculating sales commissions. This prevents overstated commission amounts and keeps commission reports aligned with valid invoicing activity.
Original PR description
Steps: - Create a sales commission plan and assign salespeople. - Create SO and invoice and assign the salesperson to the plan. This will give this person a commission. - Cancel the invoice the commission is still on the commission report. Issue: - Cancelled invoices were being included in commission calculations, which resulted in inaccurate commission amounts. Cause: - The existing SQL query did not account for the state of the invoices, leading to all invoices (including canceled ones) being considered for commission calculations. Fix: - Updated the SQL query by adding a filter to exclude invoices where the state is `canceled`. This ensures only valid invoices are used for commission calculations, providing accurate results. opw-4261999