odoo/enterprise#76497
Created by fw-bot
Statuses:
- legal/cla: Contributor License Agreement check
- ci/runbot: Odoo Test Suite
- ci/upgrade_enterprise: Test upgrades for enterprise master
- ci/template: Contact runbot team on discord for help.
- ci/style: Optional style check. Ignore it only if strictly necessary.
- ci/security: Required security check. Can only be ignored by security team.
- ci/l10n: (runtime 1s)
- label
- odoo-dev:saas-18.1-17.0-composite_report_options_at_creation-hupo-1gQO-fw
- head
- d5e652889c7bcb99eb8707f64e707372dd2b9079
- merged
- 10 months ago by Accounting, Hugo Poncelet (hupo)
| odoo/odoo | odoo/enterprise | |
|---|---|---|
| 17.0 | #188476 | #74826 |
| saas-17.2 | #192368 | #76475 |
| saas-17.4 | #192390 | #76485 |
| 18.0 | #192404 | #76494 |
| saas-18.1 | #192414 | #76497 |
| saas-18.2 | ||
| saas-18.3 | ||
| saas-18.4 | ||
| 19.0 | ||
| master | #192420 | #76501 |
[FW][FIX] account_report: options on composite report export
Steps to reproduce
- Activate developer mode
- Go to Accounting -> Configuration -> Accounting Reports
- Create a composite report with 2 existing reports that
have the "filter_unfold_all" activated, i.e. "Balance Sheet" and "Profit and Loss"
- Create a menu item in the action of the report
- Open the report
- Press the filter "Unfold All"
- Press the "PDF" button
-> Results: the pdf has no line unfolded while they should (the web UI works as expected)
Reason of the issue:
In the dispatch_report_action() function, the get_options() was wrong and unnecessary. This function
is first called on the first section, then called on the composite report with its own options.
This led to use the options of the composite report which does not have the filter_unfold_all field
set to True.
This also handles the case where a composite report has reports A and B, A having the
filter_unfold_all while B doesn't have it. The expected result when printing it is
that only report A has unfolded lines.
Forward-Port-Of: #74826