diff --git a/hledger-lib/Hledger/Data/Journal.hs b/hledger-lib/Hledger/Data/Journal.hs index 7dbd70904..6901534a6 100644 --- a/hledger-lib/Hledger/Data/Journal.hs +++ b/hledger-lib/Hledger/Data/Journal.hs @@ -1097,6 +1097,7 @@ postingPivot fieldortagname p = p{paccount = pivotedacct, poriginal = Just $ ori | Just t <- ptransaction p, fieldortagname == "description" = tdescription t | Just t <- ptransaction p, fieldortagname == "payee" = transactionPayee t | Just t <- ptransaction p, fieldortagname == "note" = transactionNote t + | Just t <- ptransaction p, fieldortagname == "status" = T.pack . show . tstatus $ t | Just (_, value) <- postingFindTag fieldortagname p = value | otherwise = "" diff --git a/hledger/hledger.m4.md b/hledger/hledger.m4.md index f4996bfc7..6f920c07c 100644 --- a/hledger/hledger.m4.md +++ b/hledger/hledger.m4.md @@ -1469,7 +1469,7 @@ Related: Normally hledger sums amounts, and organizes them in a hierarchy, based on account name. The `--pivot FIELD` option causes it to sum and organize hierarchy based on the value of some other field instead. FIELD can be: -`code`, `description`, `payee`, `note`, +`status`, `code`, `description`, `payee`, `note`, or the full name (case insensitive) of any [tag](#tags). As with account names, values containing `colon:separated:parts` will be displayed hierarchically in reports.