Expand description
View projections shared across report consumers.
Flattens ReportData / ActivityData / BreakdownData server
responses into small row-oriented structs. Report table handlers, the
chart adapters in the plotting crate, and the CLI all consume these
instead of re-walking the tree.
Structs§
Functions§
- flatten_
activity_ data - Flatten an
ActivityDatainto per-period / per-group row lists with totals.flip_signis applied to amounts and to the per-period net, following the convention documented indoc/reporting.org:Net = sum(group_total * (flip_sign ? +1 : -1)). - flatten_
breakdown_ data - Flatten a
BreakdownDatainto per-period row lists. The uncategorized sentinel bucket is translated intois_uncategorized = trueso consumers can render it differently without knowing the sentinel value. - flatten_
report_ data - Flatten a point-in-time or period-activity
ReportDatainto a single row list. The outerPeriodDatawrapper collapses because Balance always returns exactly one period.