lib: multiBalanceReport: Remove unnecessary addition of parent accounts.
This commit is contained in:
parent
e079c8b808
commit
fcaec1540a
@ -344,7 +344,7 @@ displayedAccounts ropts q valuedaccts
|
|||||||
| otherwise = HM.mapWithKey (\a _ -> displayedName a) displayedAccts
|
| otherwise = HM.mapWithKey (\a _ -> displayedName a) displayedAccts
|
||||||
where
|
where
|
||||||
-- Accounts which are to be displayed
|
-- Accounts which are to be displayed
|
||||||
displayedAccts = HM.filterWithKey keep (valuedaccts <> allParents)
|
displayedAccts = HM.filterWithKey keep valuedaccts
|
||||||
where
|
where
|
||||||
keep name amts = isInteresting name amts || isInterestingParent name
|
keep name amts = isInteresting name amts || isInterestingParent name
|
||||||
|
|
||||||
@ -381,10 +381,6 @@ displayedAccounts ropts q valuedaccts
|
|||||||
| empty_ ropts || no_elide_ ropts = const True
|
| empty_ ropts || no_elide_ ropts = const True
|
||||||
| otherwise = (`HM.member` interestingParents)
|
| otherwise = (`HM.member` interestingParents)
|
||||||
|
|
||||||
allParents
|
|
||||||
| tree_ ropts = HM.fromList [(a,[]) | a <- expandAccountNames $ HM.keys interestingAccounts]
|
|
||||||
| otherwise = mempty
|
|
||||||
|
|
||||||
isZeroRow balance = all (mixedAmountLooksZero . balance)
|
isZeroRow balance = all (mixedAmountLooksZero . balance)
|
||||||
keepEmpty = empty_ ropts || depth == 0
|
keepEmpty = empty_ ropts || depth == 0
|
||||||
depth = queryDepth q
|
depth = queryDepth q
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user