mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-20 11:48:30 -06:00
[balsheet-pnl] fix: hide Equity sections when not needed
* If currencies are not converted, Unrealized Gains are meaningless. Hide them. * If there are no income/expense accounts, retained earnings will be nil. Remove row.
This commit is contained in:
parent
7853f5a24a
commit
54c4575f27
@ -1125,11 +1125,14 @@ also show overall period profit & loss."))
|
||||
(add-to-table
|
||||
multicol-table-right (_ "Equity")
|
||||
(append equity-accounts
|
||||
(list
|
||||
(vector (_ "Unrealized Gains")
|
||||
unrealized-gain-fn)
|
||||
(vector (_ "Retained Earnings")
|
||||
retained-earnings-fn)))
|
||||
(if common-currency
|
||||
(list (vector (_ "Unrealized Gains")
|
||||
unrealized-gain-fn))
|
||||
'())
|
||||
(if (null? income-expense)
|
||||
'()
|
||||
(list (vector (_ "Retained Earnings")
|
||||
retained-earnings-fn))))
|
||||
#:negate-amounts? #t)
|
||||
|
||||
(if (and common-currency show-rates?)
|
||||
|
@ -497,7 +497,7 @@
|
||||
"Root.Asset.House" "Total For Asset" "Liability" "Root.Liability"
|
||||
"Root.Liability.Bank2" "Root.Liability.Bank2.CreditCard"
|
||||
"Root.Liability.Bank2.Loan" "Total For Liability" "Equity" "Root.Equity"
|
||||
"Unrealized Gains" "Retained Earnings" "Total For Equity")
|
||||
"Retained Earnings" "Total For Equity")
|
||||
(sxml->table-row-col sxml 1 #f 1))
|
||||
(test-equal "default balances"
|
||||
'("#200.00" "$106,709.00" "30 FUNDS" "#200.00" "$106,709.00" "30 FUNDS"
|
||||
|
Loading…
Reference in New Issue
Block a user