From df84a417d79fb58ade49714ace8ff93457fb2191 Mon Sep 17 00:00:00 2001 From: Stephen Morgan Date: Sun, 5 Jul 2020 18:25:23 +1000 Subject: [PATCH] doc: Remove references to old limitations of boring parent ellision. --- .../Hledger/Reports/MultiBalanceReport.hs | 16 ++++++++-------- hledger/Hledger/Cli/Commands/Balance.md | 4 ---- hledger/Hledger/Cli/CompoundBalanceCommand.hs | 1 + 3 files changed, 9 insertions(+), 12 deletions(-) diff --git a/hledger-lib/Hledger/Reports/MultiBalanceReport.hs b/hledger-lib/Hledger/Reports/MultiBalanceReport.hs index b4d88b9c8..ed85fe1a7 100644 --- a/hledger-lib/Hledger/Reports/MultiBalanceReport.hs +++ b/hledger-lib/Hledger/Reports/MultiBalanceReport.hs @@ -86,11 +86,11 @@ type ClippedAccountName = AccountName -- | Generate a multicolumn balance report for the matched accounts, -- showing the change of balance, accumulated balance, or historical balance --- in each of the specified periods. Does not support tree-mode boring parent eliding. --- If the normalbalance_ option is set, it adjusts the sorting and sign of amounts --- (see ReportOpts and CompoundBalanceCommand). --- hledger's most powerful and useful report, used by the balance --- command (in multiperiod mode) and (via multiBalanceReport') by the bs/cf/is commands. +-- in each of the specified periods. If the normalbalance_ option is set, it +-- adjusts the sorting and sign of amounts (see ReportOpts and +-- CompoundBalanceCommand). hledger's most powerful and useful report, used +-- by the balance command (in multiperiod mode) and (via compoundBalanceReport) +-- by the bs/cf/is commands. multiBalanceReport :: Day -> ReportOpts -> Journal -> MultiBalanceReport multiBalanceReport today ropts j = multiBalanceReportWith ropts q j (journalPriceOracle infer j) @@ -548,9 +548,9 @@ postprocessReport ropts displaynames = -- | Generates a simple non-columnar BalanceReport, but using multiBalanceReport, --- in order to support --historical. Does not support tree-mode boring parent eliding. --- If the normalbalance_ option is set, it adjusts the sorting and sign of amounts --- (see ReportOpts and CompoundBalanceCommand). +-- in order to support --historical. If the normalbalance_ option is set, it +-- adjusts the sorting and sign of amounts (see ReportOpts and +-- CompoundBalanceCommand). balanceReportFromMultiBalanceReport :: ReportOpts -> Query -> Journal -> ([(AccountName, AccountName, Int, MixedAmount)], MixedAmount) balanceReportFromMultiBalanceReport ropts q j = (rows', total) diff --git a/hledger/Hledger/Cli/Commands/Balance.md b/hledger/Hledger/Cli/Commands/Balance.md index 08b551ff0..045687dbe 100644 --- a/hledger/Hledger/Cli/Commands/Balance.md +++ b/hledger/Hledger/Cli/Commands/Balance.md @@ -309,10 +309,6 @@ Balance changes in 2008: (Average is rounded to the dollar here since all journal amounts are) ``` -A limitation of multicolumn balance reports: eliding of boring parent -accounts in tree mode, as in the classic balance report, is not yet -supported. - The `--transpose` flag can be used to exchange the rows and columns of a multicolumn report. diff --git a/hledger/Hledger/Cli/CompoundBalanceCommand.hs b/hledger/Hledger/Cli/CompoundBalanceCommand.hs index fc7e272c5..2d734a8a3 100644 --- a/hledger/Hledger/Cli/CompoundBalanceCommand.hs +++ b/hledger/Hledger/Cli/CompoundBalanceCommand.hs @@ -105,6 +105,7 @@ compoundBalanceCommand CompoundBalanceCommandSpec{..} opts@CliOpts{reportopts_=r -- are used in single column mode, since in that situation we will be using -- balanceReportFromMultiBalanceReport which does not support eliding boring parents, -- and tree mode hides this.. or something.. XXX + -- This limitation on longer exists. Should this be changed? ropts' = ropts{ balancetype_=balancetype, accountlistmode_=if not (flat_ ropts) && interval_==NoInterval && balancetype `elem` [CumulativeChange, HistoricalBalance] then ALTree else accountlistmode_,