editing users uses datomic.

This commit is contained in:
BC
2018-09-20 23:17:45 -07:00
parent ebb9a191f1
commit 4a237a8224
8 changed files with 63 additions and 99 deletions

View File

@@ -5,23 +5,11 @@
[com.walmartlabs.lacinia :refer [execute]]
[com.walmartlabs.lacinia.executor :as executor]
[com.walmartlabs.lacinia.resolve :as resolve]
[auto-ap.db.transactions :as transactions]
[auto-ap.db.vendors :as vendors]
[auto-ap.db.checks :as checks]
[auto-ap.utils :refer [by]]
[auto-ap.db.companies :as companies]
[auto-ap.time :refer [parse normal-date]]))
(defn get-check-for-transaction [context args value]
(->graphql
(checks/get-by-id (:check_id value))))
(defn get-company-for-transaction [context args value]
(->graphql
(if-let [company-cache (:company-cache context)]
(company-cache (:company_id value))
(companies/get-by-id (:company_id value)))))
(defn get-transaction-page [context args value]
(let [args (assoc args :id (:id context))
transactions (map