mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Bug 642292 - General Ledger report - 'Primary Sort Key' value is not persistent
This commit is contained in:
parent
e003cb07db
commit
0e91583754
@ -75,6 +75,7 @@
|
||||
(export gnc:option-value-get-index)
|
||||
(export gnc:option-number-of-indices)
|
||||
(export gnc:option-default-value)
|
||||
(export gnc:option-set-default-value)
|
||||
(export gnc:restore-form-generator)
|
||||
(export gnc:value->string)
|
||||
(export gnc:make-string-option)
|
||||
|
@ -177,6 +177,17 @@
|
||||
(let ((getter (gnc:option-default-getter option)))
|
||||
(getter)))
|
||||
|
||||
;; Attention: this function can only be used with restrictions
|
||||
;; - only during option generation, not in arbitrary code
|
||||
;; - only for option types for which no conversion is required
|
||||
;; between default-value and value. In the various gnc:make-option
|
||||
;; functions below this is ok when
|
||||
;; 1. there's (value default-value) in the let* call
|
||||
;; 2. default-getter is set to (lambda() default-value)
|
||||
(define (gnc:option-set-default-value option default-value)
|
||||
(vector-set! option 7 (lambda() default-value))
|
||||
(gnc:option-set-value option default-value))
|
||||
|
||||
|
||||
(define (gnc:restore-form-generator value->string)
|
||||
(lambda () (string-append
|
||||
|
@ -53,7 +53,7 @@
|
||||
)
|
||||
|
||||
(define (set-option! section name value)
|
||||
(gnc:option-set-value
|
||||
(gnc:option-set-default-value
|
||||
(gnc:lookup-option options section name) value))
|
||||
|
||||
;; Match, by default, all non-void transactions ever recorded in
|
||||
|
@ -57,7 +57,7 @@
|
||||
|
||||
(define pagename-sorting (N_ "Sorting"))
|
||||
(define (set-option! section name value)
|
||||
(gnc:option-set-value
|
||||
(gnc:option-set-default-value
|
||||
(gnc:lookup-option options section name) value))
|
||||
|
||||
;; set options in the accounts tab...
|
||||
|
Loading…
Reference in New Issue
Block a user