mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
[income-statement] remove dead code, compact function
column and balance were unused. compact function.
This commit is contained in:
parent
2684e51dbf
commit
621c857b6a
@ -450,36 +450,16 @@
|
|||||||
(define (report-line
|
(define (report-line
|
||||||
table pos-label neg-label amount col
|
table pos-label neg-label amount col
|
||||||
exchange-fn rule? row-style)
|
exchange-fn rule? row-style)
|
||||||
(let* ((neg? (and amount
|
(let* ((mon (gnc:sum-collector-commodity
|
||||||
neg-label
|
amount report-commodity exchange-fn))
|
||||||
(gnc-numeric-negative-p
|
(neg? (and amount neg-label
|
||||||
(gnc:gnc-monetary-amount
|
(negative? (gnc:gnc-monetary-amount mon))))
|
||||||
(gnc:sum-collector-commodity
|
|
||||||
amount report-commodity exchange-fn)))))
|
|
||||||
(label (if neg? (or neg-label pos-label) pos-label))
|
(label (if neg? (or neg-label pos-label) pos-label))
|
||||||
(pos-bal (if neg?
|
(bal (if neg? (gnc:monetary-neg mon) mon)))
|
||||||
(let ((bal (gnc:make-commodity-collector)))
|
|
||||||
(bal 'minusmerge amount #f)
|
|
||||||
bal)
|
|
||||||
amount))
|
|
||||||
(bal (gnc:sum-collector-commodity
|
|
||||||
pos-bal report-commodity exchange-fn))
|
|
||||||
(balance
|
|
||||||
(or (and (gnc:uniform-commodity? pos-bal report-commodity)
|
|
||||||
bal)
|
|
||||||
(and show-fcur?
|
|
||||||
(gnc-commodity-table
|
|
||||||
pos-bal report-commodity exchange-fn))
|
|
||||||
bal
|
|
||||||
))
|
|
||||||
(column (or col 0))
|
|
||||||
)
|
|
||||||
(gnc:html-table-add-labeled-amount-line!
|
(gnc:html-table-add-labeled-amount-line!
|
||||||
table (* 2 tree-depth) row-style rule?
|
table (* 2 tree-depth) row-style rule?
|
||||||
label 0 1 "text-cell"
|
label 0 1 "text-cell"
|
||||||
bal (+ col 1) 1 "number-cell")
|
bal (+ col 1) 1 "number-cell")))
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
;; sum revenues and expenses
|
;; sum revenues and expenses
|
||||||
(set! revenue-closing
|
(set! revenue-closing
|
||||||
|
Loading…
Reference in New Issue
Block a user