mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
[balsheet-pnl] show most recent period first by default
This commit is contained in:
parent
bd75b08fc2
commit
9b41733622
@ -62,6 +62,9 @@ https://bugs.gnucash.org/")))
|
|||||||
(define optname-period (N_ "Period duration"))
|
(define optname-period (N_ "Period duration"))
|
||||||
(define opthelp-period (N_ "Duration between time periods"))
|
(define opthelp-period (N_ "Duration between time periods"))
|
||||||
|
|
||||||
|
(define optname-reverse-chrono (N_ "Period order is most recent first"))
|
||||||
|
(define opthelp-reverse-chrono (N_ "Period order is most recent first"))
|
||||||
|
|
||||||
(define optname-dual-columns (N_ "Enable dual columns"))
|
(define optname-dual-columns (N_ "Enable dual columns"))
|
||||||
(define opthelp-dual-columns (N_ "Selecting this option will enable double-column \
|
(define opthelp-dual-columns (N_ "Selecting this option will enable double-column \
|
||||||
reporting."))
|
reporting."))
|
||||||
@ -202,6 +205,8 @@ also show overall period profit & loss."))
|
|||||||
options
|
options
|
||||||
gnc:pagename-general optname-dual-columns
|
gnc:pagename-general optname-dual-columns
|
||||||
(not x))
|
(not x))
|
||||||
|
(gnc-option-db-set-option-selectable-by-name
|
||||||
|
options gnc:pagename-general optname-reverse-chrono x)
|
||||||
(case report-type
|
(case report-type
|
||||||
((balsheet)
|
((balsheet)
|
||||||
(gnc-option-db-set-option-selectable-by-name
|
(gnc-option-db-set-option-selectable-by-name
|
||||||
@ -229,6 +234,11 @@ also show overall period profit & loss."))
|
|||||||
gnc:pagename-general optname-dual-columns
|
gnc:pagename-general optname-dual-columns
|
||||||
"c4" opthelp-dual-columns #t))
|
"c4" opthelp-dual-columns #t))
|
||||||
|
|
||||||
|
(add-option
|
||||||
|
(gnc:make-simple-boolean-option
|
||||||
|
gnc:pagename-general optname-reverse-chrono
|
||||||
|
"c5" opthelp-reverse-chrono #t))
|
||||||
|
|
||||||
(add-option
|
(add-option
|
||||||
(gnc:make-multichoice-option
|
(gnc:make-multichoice-option
|
||||||
gnc:pagename-general optname-options-summary
|
gnc:pagename-general optname-options-summary
|
||||||
@ -350,6 +360,7 @@ also show overall period profit & loss."))
|
|||||||
|
|
||||||
(define* (add-multicolumn-acct-table
|
(define* (add-multicolumn-acct-table
|
||||||
table title accountlist maxindent get-cell-monetary-fn cols-data #:key
|
table title accountlist maxindent get-cell-monetary-fn cols-data #:key
|
||||||
|
(reverse-cols? #f)
|
||||||
(omit-zb-bals? #f)
|
(omit-zb-bals? #f)
|
||||||
(show-zb-accts? #t)
|
(show-zb-accts? #t)
|
||||||
(disable-account-indent? #f)
|
(disable-account-indent? #f)
|
||||||
@ -427,7 +438,7 @@ also show overall period profit & loss."))
|
|||||||
(list account-cell)
|
(list account-cell)
|
||||||
(gnc:html-make-empty-cells
|
(gnc:html-make-empty-cells
|
||||||
(if amount-indenting? (1- amount-indent) 0))
|
(if amount-indenting? (1- amount-indent) 0))
|
||||||
rest
|
(if reverse-cols? (reverse rest) rest)
|
||||||
(gnc:html-make-empty-cells
|
(gnc:html-make-empty-cells
|
||||||
(if amount-indenting? (- maxindent amount-indent) 0)))))
|
(if amount-indenting? (- maxindent amount-indent) 0)))))
|
||||||
(if row-markup
|
(if row-markup
|
||||||
@ -749,6 +760,8 @@ also show overall period profit & loss."))
|
|||||||
((eq? report-type 'pnl) (list startdate enddate))
|
((eq? report-type 'pnl) (list startdate enddate))
|
||||||
(else (list enddate))))
|
(else (list enddate))))
|
||||||
|
|
||||||
|
(reverse-chrono? (get-option gnc:pagename-general optname-reverse-chrono))
|
||||||
|
|
||||||
(report-dates-vec (list->vector report-dates))
|
(report-dates-vec (list->vector report-dates))
|
||||||
(num-report-dates (vector-length report-dates-vec))
|
(num-report-dates (vector-length report-dates-vec))
|
||||||
|
|
||||||
@ -1057,6 +1070,7 @@ also show overall period profit & loss."))
|
|||||||
table title accounts
|
table title accounts
|
||||||
maxindent get-cell-monetary-fn
|
maxindent get-cell-monetary-fn
|
||||||
(iota num-report-dates)
|
(iota num-report-dates)
|
||||||
|
#:reverse-cols? reverse-chrono?
|
||||||
#:omit-zb-bals? omit-zb-bals?
|
#:omit-zb-bals? omit-zb-bals?
|
||||||
#:show-zb-accts? show-zb-accts?
|
#:show-zb-accts? show-zb-accts?
|
||||||
#:disable-account-indent? disable-account-indent?
|
#:disable-account-indent? disable-account-indent?
|
||||||
@ -1231,6 +1245,7 @@ also show overall period profit & loss."))
|
|||||||
(> num-report-dates 2))
|
(> num-report-dates 2))
|
||||||
'(overall-period)
|
'(overall-period)
|
||||||
'()))
|
'()))
|
||||||
|
#:reverse-cols? reverse-chrono?
|
||||||
#:omit-zb-bals? omit-zb-bals?
|
#:omit-zb-bals? omit-zb-bals?
|
||||||
#:show-zb-accts? show-zb-accts?
|
#:show-zb-accts? show-zb-accts?
|
||||||
#:disable-account-indent? disable-account-indent?
|
#:disable-account-indent? disable-account-indent?
|
||||||
|
@ -475,6 +475,7 @@
|
|||||||
(define (multicol-balsheet-tests)
|
(define (multicol-balsheet-tests)
|
||||||
(define (default-testing-options)
|
(define (default-testing-options)
|
||||||
(let ((options (gnc:make-report-options multicol-balsheet-uuid)))
|
(let ((options (gnc:make-report-options multicol-balsheet-uuid)))
|
||||||
|
(set-option! options "General" "Period order is most recent first" #f)
|
||||||
(set-option! options "General" "Start Date"
|
(set-option! options "General" "Start Date"
|
||||||
(cons 'absolute (gnc-dmy2time64 1 1 1970)))
|
(cons 'absolute (gnc-dmy2time64 1 1 1970)))
|
||||||
(set-option! options "General" "End Date"
|
(set-option! options "General" "End Date"
|
||||||
@ -557,6 +558,7 @@
|
|||||||
(define (multicol-pnl-tests)
|
(define (multicol-pnl-tests)
|
||||||
(define (default-testing-options)
|
(define (default-testing-options)
|
||||||
(let ((options (gnc:make-report-options multicol-pnl-uuid)))
|
(let ((options (gnc:make-report-options multicol-pnl-uuid)))
|
||||||
|
(set-option! options "General" "Period order is most recent first" #f)
|
||||||
(set-option! options "General" "Start Date"
|
(set-option! options "General" "Start Date"
|
||||||
(cons 'absolute (gnc-dmy2time64 1 1 1980)))
|
(cons 'absolute (gnc-dmy2time64 1 1 1980)))
|
||||||
(set-option! options "General" "End Date"
|
(set-option! options "General" "End Date"
|
||||||
|
Loading…
Reference in New Issue
Block a user