mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
[equity-statement] remove dead code
* 'balance' in add-report-line was defined but never used * capital/drawing accounts are not defined. remove.
This commit is contained in:
parent
99b5d79a44
commit
c21d173c06
@ -265,20 +265,13 @@
|
|||||||
(equity-accounts
|
(equity-accounts
|
||||||
(assoc-ref split-up-accounts ACCT-TYPE-EQUITY))
|
(assoc-ref split-up-accounts ACCT-TYPE-EQUITY))
|
||||||
|
|
||||||
;; N.B.: equity-accounts will also contain drawing accounts
|
|
||||||
;; these must still be split-out and itemized separately
|
|
||||||
(capital-accounts #f)
|
|
||||||
(drawing-accounts #f)
|
|
||||||
|
|
||||||
(closing-pattern
|
(closing-pattern
|
||||||
(list (list 'str closing-str)
|
(list (list 'str closing-str)
|
||||||
(list 'cased closing-cased)
|
(list 'cased closing-cased)
|
||||||
(list 'regexp closing-regexp)
|
(list 'regexp closing-regexp)
|
||||||
(list 'positive #f)
|
(list 'positive #f)
|
||||||
(list 'closing #t)
|
(list 'closing #t)))
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
(doc (gnc:make-html-document))
|
(doc (gnc:make-html-document))
|
||||||
;; exchange rates calculation parameters
|
;; exchange rates calculation parameters
|
||||||
(start-exchange-fn
|
(start-exchange-fn
|
||||||
@ -364,14 +357,7 @@
|
|||||||
(gnc:accounts-get-comm-total-assets
|
(gnc:accounts-get-comm-total-assets
|
||||||
equity-accounts get-end-balance-fn))
|
equity-accounts get-end-balance-fn))
|
||||||
|
|
||||||
;; these variables wont be used until gnucash gets
|
(start-book-balance
|
||||||
;; conta account types
|
|
||||||
(start-capital-balance #f)
|
|
||||||
(end-capital-balance #f)
|
|
||||||
(start-drawing-balance #f)
|
|
||||||
(end-drawing-balance #f)
|
|
||||||
|
|
||||||
(start-book-balance
|
|
||||||
(gnc:collector+ start-asset-balance
|
(gnc:collector+ start-asset-balance
|
||||||
neg-start-liability-balance
|
neg-start-liability-balance
|
||||||
neg-start-equity-balance
|
neg-start-equity-balance
|
||||||
@ -440,31 +426,17 @@
|
|||||||
(define (add-report-line
|
(define (add-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* ((neg? (and amount neg-label
|
||||||
neg-label
|
(negative?
|
||||||
(gnc-numeric-negative-p
|
|
||||||
(gnc:gnc-monetary-amount
|
(gnc:gnc-monetary-amount
|
||||||
(gnc:sum-collector-commodity
|
(gnc:sum-collector-commodity
|
||||||
amount report-commodity exchange-fn)))))
|
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?
|
(pos-bal (if neg? (gnc:collector- amount) amount)))
|
||||||
(gnc:collector- amount)
|
|
||||||
amount))
|
|
||||||
(bal (gnc:sum-collector-commodity
|
|
||||||
pos-bal report-commodity exchange-fn))
|
|
||||||
(balance
|
|
||||||
(cond
|
|
||||||
((gnc:uniform-commodity? pos-bal report-commodity) bal)
|
|
||||||
(show-fcur? (gnc-commodity-table
|
|
||||||
pos-bal report-commodity exchange-fn))
|
|
||||||
(else bal)))
|
|
||||||
(column (or col 0)))
|
|
||||||
(gnc:html-table-add-labeled-amount-line!
|
(gnc:html-table-add-labeled-amount-line!
|
||||||
table 3 row-style rule?
|
table 3 row-style rule? label 0 1 "text-cell"
|
||||||
label 0 1 "text-cell"
|
(gnc:sum-collector-commodity pos-bal report-commodity exchange-fn)
|
||||||
bal (+ col 1) 1 "number-cell")
|
(1+ col) 1 "number-cell")))
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
(gnc:report-percent-done 30)
|
(gnc:report-percent-done 30)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user