Progress on reporst

This commit is contained in:
2022-11-16 06:46:42 -08:00
parent dbedfec0da
commit 86532d2f74
3 changed files with 27 additions and 19 deletions

View File

@@ -244,7 +244,7 @@
(conj [:paragraph {:color [128 0 0] :size 9} (:warning report)]) (conj [:paragraph {:color [128 0 0] :size 9} (:warning report)])
(conj (conj
(table->pdf report (table->pdf report
[20 80 20 20 20]))) [80 25 80 20 20 20])))
output-stream) output-stream)
(.toByteArray output-stream))) (.toByteArray output-stream)))

View File

@@ -556,7 +556,8 @@
(defn journal-detail-report [args data client-codes] (defn journal-detail-report [args data client-codes]
{:header [[{:value "Date"} {:header [[{:value "Category"}
{:value "Date"}
{:value "Description"} {:value "Description"}
{:value "Debit"} {:value "Debit"}
{:value "Credit"} {:value "Credit"}
@@ -566,14 +567,17 @@
(into rows (into rows
;; TODO colspan ? ;; TODO colspan ?
(concat (when (seq (:journal-entries category)) (concat (when (seq (:journal-entries category))
[[{:value (str "" )} [[
{:value (str (client-codes (:client-id category)) " - " (:location category) " - " (:name (:account category)))} {:value (str (client-codes (:client-id category)) " - " (:location category) " - " (:name (:account category)))}
{:value ""} {:value ""}
{:value ""} {:value ""}
{:value ""}
{:value ""}
{:value ""}]]) {:value ""}]])
(map (map
(fn [je] (fn [je]
[{:value (user-friendly-date (:date je))} [{:value ""}
{:value (user-friendly-date (:date je))}
{:value (:description je "")} {:value (:description je "")}
{:value (get je :debit) {:value (get je :debit)
:format :dollar} :format :dollar}
@@ -582,20 +586,24 @@
{:value (get je :running-balance) {:value (get je :running-balance)
:format :dollar}]) :format :dollar}])
(:journal-entries category)) (:journal-entries category))
[[{:value (str "Total" ) (when (seq (:journal-entries category))
:bold true [[
:border [:top]} {:value (str (client-codes (:client-id category)) " - " (:location category) " - " (:name (:account category)))
{:value (str (client-codes (:client-id category)) " - " (:location category) " - " (:name (:account category))) :bold true
:bold true :border [:top]}
:border [:top]} {:value ""
{:value "" :border [:top]}
:border [:top]} {:value (str "Total" )
{:value "" :bold true
:border [:top]} :border [:top]}
{:value (:total category) {:value ""
:format :dollar :border [:top]}
:bold true {:value ""
:border [:top]}]])) :border [:top]}
{:value (:total category)
:format :dollar
:bold true
:border [:top]}]])))
) )
[] []

View File

@@ -193,7 +193,7 @@ NOTE: Please review the transactions we may have question for you here: https://
(when (:warning report) (when (:warning report)
[:div.notification.is-warning.is-light [:div.notification.is-warning.is-light
(:warning report)]) (:warning report)])
[rtable/table {:widths [20 60 20 20 20] [rtable/table {:widths [20 10 20 8 8 8]
:table report}]])) :table report}]]))