report updates for nick the greek.
This commit is contained in:
@@ -304,8 +304,9 @@
|
||||
(if (-> pnl-data :args :column-per-location)
|
||||
(mapcat
|
||||
(fn [p]
|
||||
(cond-> [(merge {:value (or (
|
||||
-> p :filters :location) "Total")
|
||||
(cond-> [(merge {:value (or (when (-> p :filters :location)
|
||||
(str ((-> p :client-codes) (-> p :filters :client-id)) "-" (-> p :filters :location)))
|
||||
"Total")
|
||||
:align :right}
|
||||
(:cell-args p))
|
||||
(merge {:value "%"
|
||||
@@ -470,8 +471,9 @@
|
||||
(if (-> pnl-data :args :column-per-location)
|
||||
[(location-summary-table (mapcat identity (for [[period i] (map vector (-> pnl-data :args :periods ) (range))]
|
||||
(concat
|
||||
(for [location (set (map second (client-locations pnl-data)))]
|
||||
(for [[client-id location] (client-locations pnl-data)]
|
||||
(-> pnl-data
|
||||
(filter-client client-id)
|
||||
(filter-location location)
|
||||
(filter-period period)
|
||||
(zebra i)))
|
||||
@@ -488,9 +490,10 @@
|
||||
:details
|
||||
(doall (if (-> pnl-data :args :column-per-location)
|
||||
[(location-detail-table (mapcat identity (for [[period i] (map vector (-> pnl-data :args :periods ) (range))]
|
||||
(concat
|
||||
(for [location (set (map second (client-locations pnl-data)))]
|
||||
(concat
|
||||
(for [[client-id location] (client-locations pnl-data)]
|
||||
(-> pnl-data
|
||||
(filter-client client-id)
|
||||
(filter-location location)
|
||||
(filter-period period)
|
||||
(zebra i)))
|
||||
@@ -557,4 +560,4 @@
|
||||
:rows table}))
|
||||
|
||||
|
||||
(defrecord PNLData [args data client-names])
|
||||
(defrecord PNLData [args data client-codes])
|
||||
|
||||
Reference in New Issue
Block a user