better RawLedger string representation

This commit is contained in:
Simon Michael 2008-10-09 09:25:58 +00:00
parent 3fcb1aaa6c
commit 165945cf20

View File

@ -17,10 +17,13 @@ import Ledger.Transaction
instance Show RawLedger where instance Show RawLedger where
show l = printf "RawLedger with %d entries" show l = printf "RawLedger with %d entries, %d accounts: %s"
((length $ entries l) + ((length $ entries l) +
(length $ modifier_entries l) + (length $ modifier_entries l) +
(length $ periodic_entries l)) (length $ periodic_entries l))
(length accounts)
(show accounts)
where accounts = flatten $ rawLedgerAccountNameTree l
rawLedgerTransactions :: RawLedger -> [Transaction] rawLedgerTransactions :: RawLedger -> [Transaction]
rawLedgerTransactions = txns . entries rawLedgerTransactions = txns . entries