Use new options-fancy-date to retrieve date format

Use the new function so we do not need to test for valid format
This commit is contained in:
Robert Fewell 2016-11-28 19:42:07 +00:00 committed by Geert Janssens
parent 354694b744
commit 7f4b656815
7 changed files with 12 additions and 10 deletions

View File

@ -704,7 +704,7 @@
(income-accounts (opt-val pagename-incomeaccounts optname-incomeaccounts))
(all-accounts (append income-accounts expense-accounts))
(book (gnc-account-get-book (car all-accounts)))
(date-format (gnc:fancy-date-info book gnc:*fancy-date-format*))
(date-format (gnc:options-fancy-date book))
(type (opt-val "__reg" "owner-type"))
(reverse? (opt-val "__reg" "reverse?"))
(ownerlist (gncBusinessGetOwnerList

View File

@ -728,7 +728,8 @@
(if (not (null? invoice))
(let* ((book (gncInvoiceGetBook invoice))
(date-format (gnc:fancy-date-info book gnc:*fancy-date-format*)))
(date-format (gnc:options-fancy-date book)))
; invoice number and ID String table
(add-html! document "<table width='100%'><tr>")
(add-html! document "<td align='left'>")

View File

@ -798,10 +798,11 @@
(if (not (null? invoice))
(let* ((book (gncInvoiceGetBook invoice))
(date-object #f)
(date-format (gnc:fancy-date-info book gnc:*fancy-date-format*))
(date-format (gnc:options-fancy-date book))
(helper-table (gnc:make-html-table))
(title (title-string default-title custom-title)))
(set! table (make-entry-table invoice
(set! table (make-entry-table invoice
(gnc:report-options report-obj)
add-order cust-doc? credit-note?))

View File

@ -692,7 +692,8 @@
(if (not (null? invoice))
(let* ((book (gncInvoiceGetBook invoice))
(date-format (gnc:fancy-date-info book gnc:*fancy-date-format*)))
(date-format (gnc:options-fancy-date book)))
(set! table (make-entry-table invoice
(gnc:report-options report-obj)
add-order cust-doc? credit-note?))

View File

@ -553,11 +553,10 @@
(gnc:date-option-absolute-time
(opt-val gnc:pagename-general (N_ "To")))))
(book (gnc-account-get-book account))
(date-format (gnc:fancy-date-info book gnc:*fancy-date-format*))
(date-format (gnc:options-fancy-date book))
(type (opt-val "__reg" "owner-type"))
(type-str "")
(report-title-str ""))
(cond
((eqv? type GNC-OWNER-CUSTOMER)
(set! type-str (N_ "Customer"))

View File

@ -757,10 +757,10 @@
(gnc:date-option-absolute-time
(opt-val gnc:pagename-general optname-to-date))))
(book (gnc-account-get-book account))
(date-format (gnc:fancy-date-info book gnc:*fancy-date-format*))
(date-format (gnc:options-fancy-date book))
(type (opt-val "__reg" "owner-type"))
(owner-descr (owner-string type))
(date-type (opt-val gnc:pagename-general optname-date-driver))
(date-type (opt-val gnc:pagename-general optname-date-driver))
(owner (opt-val owner-page owner-descr))
(report-title (string-append (doctype-str type) " " (_ "Report"))))

View File

@ -47,7 +47,7 @@
(currency (gncInvoiceGetCurrency opt-invoice))
(entries (gncInvoiceGetEntries opt-invoice))
(splits '());'
(dateformat (gnc:fancy-date-info book gnc:*fancy-date-format*))
(dateformat (gnc:options-fancy-date book))
(coyname (gnc:company-info book gnc:*company-name*))
(coycontact (gnc:company-info book gnc:*company-contact*))
(coyaddr (gnc:company-info book gnc:*company-addy*))