fixed warnings.
This commit is contained in:
@@ -3,23 +3,22 @@
|
||||
[auto-ap.datomic.expected-deposit :as d-expected-deposit]
|
||||
[auto-ap.graphql.utils
|
||||
:refer [->graphql <-graphql assert-admin ident->enum-f result->page]]
|
||||
[com.walmartlabs.lacinia.util :refer [attach-resolvers]]
|
||||
[clojure.tools.logging :as log]))
|
||||
[com.walmartlabs.lacinia.util :refer [attach-resolvers]]))
|
||||
|
||||
(def status->graphql (ident->enum-f :expected-deposit/status))
|
||||
|
||||
(defn get-expected-deposit [context args value]
|
||||
(defn get-expected-deposit [context args _]
|
||||
(let [args (assoc args :id (:id context))
|
||||
[sales-orders sales-orders-count] (d-expected-deposit/get-graphql (<-graphql args))]
|
||||
(result->page sales-orders sales-orders-count :data args)))
|
||||
|
||||
(defn get-all-expected-deposits [context args value]
|
||||
(defn get-all-expected-deposits [context args _]
|
||||
(assert-admin (:id context))
|
||||
(map
|
||||
(comp ->graphql status->graphql)
|
||||
(first (d-expected-deposit/get-graphql (assoc (<-graphql args) :count Integer/MAX_VALUE)))))
|
||||
|
||||
(defn get-expected-deposit-page [context args value]
|
||||
(defn get-expected-deposit-page [context args _]
|
||||
(let [args (assoc args :id (:id context))
|
||||
[expected-deposits expected-deposit-count] (d-expected-deposit/get-graphql (<-graphql args))
|
||||
expected-deposits (map status->graphql expected-deposits)]
|
||||
|
||||
Reference in New Issue
Block a user