This commit is contained in:
BC
2019-01-24 22:03:47 -08:00
parent 03051ab3c6
commit d8251c5414

View File

@@ -54,13 +54,14 @@
(map <-graphql (d-vendors/get-graphql {}))) (map <-graphql (d-vendors/get-graphql {})))
(GET "/transactions/export" {:keys [query-params identity]} (GET "/transactions/export" {:keys [query-params identity]}
(assert-admin identity) (assert-admin identity)
(let [transactions (map <-graphql (d-transactions/get-graphql {:client-id (query-params "client") (let [[transactions] (d-transactions/get-graphql {:client-id (Long/parseLong (query-params "client"))
:original-id (Integer/parseInt (query-params "original")) #_#_:original-id (Integer/parseInt (query-params "original"))
:limit Integer/MAX_VALUE}))] :limit Integer/MAX_VALUE})
transactions (map <-graphql transactions)]
(map (fn [i] (map (fn [i]
(-> i (-> i
(update :date to-date) (update :transaction/date to-date)
(update :post-date to-date))) (update :transaction/post-date to-date)))
transactions)))) transactions))))