Bug 797197 - Transaction report: Error message when sorting on month

guile's strftime is/was buggy; cannot handle non-UTF8 locales. Use
gnc_print_time64 instead. see the following

http://lists.gnu.org/archive/html/bug-guile/2019-05/msg00003.html
This commit is contained in:
Christopher Lam 2019-05-27 20:58:54 +08:00
parent 8447f42674
commit ed42f8acb6

View File

@ -68,7 +68,7 @@
(gnc:date-get-year-day (gnc-localtime t64)))
(define (gnc:date-get-year-string datevec)
(gnc-locale-to-utf8 (strftime "%Y" datevec)))
(gnc-print-time64 (gnc-mktime datevec) "%Y"))
(define (gnc:date-get-quarter-string datevec)
(format #f "Q~d" (gnc:date-get-quarter datevec)))
@ -80,10 +80,10 @@
(gnc:date-get-year-string datevec)))
(define (gnc:date-get-month-string datevec)
(gnc-locale-to-utf8 (strftime "%B" datevec)))
(gnc-print-time64 (gnc-mktime datevec) "%B"))
(define (gnc:date-get-month-year-string datevec)
(gnc-locale-to-utf8 (strftime "%B %Y" datevec)))
(gnc-print-time64 (gnc-mktime datevec) "%B %Y"))
(define (gnc:date-get-week-year-string datevec)
(let* ((beginweekt64 (* (gnc:time64-get-week