Add total debt display to -info.
This commit is contained in:
parent
54497b8bc8
commit
878f64f00c
1 changed files with 17 additions and 5 deletions
|
@ -372,12 +372,24 @@
|
||||||
(list (ansi-string "\t" #:magenta #:bold "Debtors:")
|
(list (ansi-string "\t" #:magenta #:bold "Debtors:")
|
||||||
(format "~A" (length debtor-mrs))
|
(format "~A" (length debtor-mrs))
|
||||||
(table->string
|
(table->string
|
||||||
(members-attrs-table debtor-mrs
|
(append
|
||||||
brmember-format
|
(members-attrs-table debtor-mrs
|
||||||
(list "Name" "Balance" "Last Payment")
|
brmember-format
|
||||||
(list "~N" "\t~B" "~L"))
|
(list "Name" "Balance" "Last Payment")
|
||||||
|
(list "~N" "\t~B" "~L"))
|
||||||
|
(list
|
||||||
|
(list
|
||||||
|
"Total"
|
||||||
|
(format
|
||||||
|
"\t~A"
|
||||||
|
(foldr
|
||||||
|
(lambda (v a)
|
||||||
|
(+ (member-total-balance v) a))
|
||||||
|
0
|
||||||
|
debtor-mrs)))))
|
||||||
#:border '(((#:bottom #:right light) ... (#:bottom light))
|
#:border '(((#:bottom #:right light) ... (#:bottom light))
|
||||||
((#:right light) ... none) ...)
|
((#:right light) ... none) ...
|
||||||
|
((#:top #:right light) ... (#:top light)))
|
||||||
#:ansi-reset? #t)))
|
#:ansi-reset? #t)))
|
||||||
))
|
))
|
||||||
#:border '(((#:bottom #:right light) ... (#:bottom light))
|
#:border '(((#:bottom #:right light) ... (#:bottom light))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue