Wednesday, June 18, 2025
1 change · master
Code cleanup and technical improvements
The General Ledger report has been rewritten to use a cleaner, dedicated engine, making it easier to maintain and improve. Report line labeling can now be processed in batches for better performance and ordering, while the separate US Check Register report is removed because the same information is available through the General Ledger.
Original PR description
**[IMP] account_reports: batch label builder** When using a custom groupby, we can use a label builder using the grouping key. Before it was called once for each grouping key and some optimization…
**[IMP] account_reports: batch label builder** When using a custom groupby, we can use a label builder using the grouping key. Before it was called once for each grouping key and some optimization might have not been done as we could not batch it. The new way call the label builder once with all the grouping keys. This way it is batched and we can make optimization if required. The label builder function returns a dict with each grouping key containing the name of the line. The order of this dict is important as it will be the order rendered on the report. So another feature allowed by this is that we can manually order grouping keys and therefor lines. **[REF] l10n_us_reports: remove check register** It is a subset of the general ledger that is useless as a standalone report as it can be done in the General Ledger **[REF] account_reports: General Ledger Rewrite** Before this commit, the general ledger had lots of uselessly complex code that was coupled with the trial balance. See https://github.com/odoo/enterprise/pull/73298 for the trial balance rewrite. This commit aims to refactor the general ledger and use a custom engine. task-4251472