hledger-lib-1.2: Core data types, parsers and functionality for the hledger accounting tools

Safe Haskell | None
Language | Haskell2010

Hledger.Data.Timeclock

Contents

- Orphan instances

Description

A `TimeclockEntry` is a clock-in, clock-out, or other directive in a timeclock file (see timeclock.el or the command-line version). These can be converted to `Transactions` and queried like a ledger.

Synopsis

- timeclockEntriesToTransactions :: LocalTime -> [TimeclockEntry] -> [Transaction]
- entryFromTimeclockInOut :: TimeclockEntry -> TimeclockEntry -> Transaction
- tests_Hledger_Data_Timeclock :: Test

# Documentation

timeclockEntriesToTransactions :: LocalTime -> [TimeclockEntry] -> [Transaction] Source #

Convert time log entries to journal transactions. When there is no clockout, add one with the provided current time. Sessions crossing midnight are split into days to give accurate per-day totals.

entryFromTimeclockInOut :: TimeclockEntry -> TimeclockEntry -> Transaction Source #

Convert a timeclock clockin and clockout entry to an equivalent journal transaction, representing the time expenditure. Note this entry is not balanced, since we omit the "assets:time" transaction for simpler output.

tests_Hledger_Data_Timeclock :: Test Source #

# Orphan instances

Read TimeclockCode Source # |
Methods readsPrec :: Int -> ReadS TimeclockCode # readList :: ReadS [TimeclockCode] # readPrec :: ReadPrec TimeclockCode # readListPrec :: ReadPrec [TimeclockCode] #
Show TimeclockEntry Source # |
Methods showsPrec :: Int -> TimeclockEntry -> ShowS # show :: TimeclockEntry -> String # showList :: [TimeclockEntry] -> ShowS #
Show TimeclockCode Source # |
Methods showsPrec :: Int -> TimeclockCode -> ShowS # show :: TimeclockCode -> String # showList :: [TimeclockCode] -> ShowS #