Safe Haskell | None |
---|---|
Language | Haskell2010 |
A transactions report. Like an EntriesReport, but with more information such as a running balance.
Synopsis
- type TransactionsReport = [TransactionsReportItem]
- type TransactionsReportItem = (Transaction, Transaction, Bool, Text, MixedAmount, MixedAmount)
- transactionsReport :: ReportOpts -> Journal -> Query -> TransactionsReport
- transactionsReportByCommodity :: TransactionsReport -> [(CommoditySymbol, TransactionsReport)]
- triOrigTransaction :: (a, b, c, d, e, f) -> a
- triDate :: (a, Transaction, c, d, e, f) -> Day
- triAmount :: (a, b, c, d, e, f) -> e
- triBalance :: (a, b, c, d, e, f) -> f
- triCommodityAmount :: CommoditySymbol -> (a, b, c, d, MixedAmount, f) -> MixedAmount
- triCommodityBalance :: CommoditySymbol -> (a, b, c, d, e, MixedAmount) -> MixedAmount
- tests_TransactionsReport :: TestTree
Documentation
type TransactionsReport = [TransactionsReportItem] Source #
A transactions report includes a list of transactions touching multiple accounts (posting-filtered and unfiltered variants), a running balance, and some other information helpful for rendering a register view with or without a notion of current account(s). Two kinds of report use this data structure, see transactionsReport and accountTransactionsReport below for details.
type TransactionsReportItem = (Transaction, Transaction, Bool, Text, MixedAmount, MixedAmount) Source #
transactionsReport :: ReportOpts -> Journal -> Query -> TransactionsReport Source #
Select transactions from the whole journal. This is similar to a "postingsReport" except with transaction-based report items which are ordered most recent first. XXX Or an EntriesReport - use that instead ? This is used by hledger-web's journal view.
transactionsReportByCommodity :: TransactionsReport -> [(CommoditySymbol, TransactionsReport)] Source #
Split a transactions report whose items may involve several commodities, into one or more single-commodity transactions reports.
triOrigTransaction :: (a, b, c, d, e, f) -> a Source #
triDate :: (a, Transaction, c, d, e, f) -> Day Source #
triBalance :: (a, b, c, d, e, f) -> f Source #
triCommodityAmount :: CommoditySymbol -> (a, b, c, d, MixedAmount, f) -> MixedAmount Source #
triCommodityBalance :: CommoditySymbol -> (a, b, c, d, e, MixedAmount) -> MixedAmount Source #