adding authorization
This commit is contained in:
@@ -25,14 +25,15 @@
|
||||
(companies/get-by-id (:company_id value)))))
|
||||
|
||||
(defn get-check-page [context args value]
|
||||
(let [extra-context
|
||||
(let [args (assoc args :id (:id context))
|
||||
extra-context
|
||||
(cond-> {}
|
||||
(executor/selects-field? context :invoice/vendor) (assoc :vendor-cache (by :id (vendors/get-all)))
|
||||
(executor/selects-field? context :invoice/company) (assoc :company-cache (by :id (companies/get-all))))
|
||||
|
||||
checks (map
|
||||
->graphql
|
||||
(checks/get-graphql (<-graphql args)))
|
||||
(checks/get-graphql (<-graphql args)))
|
||||
checks-count (checks/count-graphql (<-graphql args))]
|
||||
(resolve/with-context
|
||||
[{:checks checks
|
||||
|
||||
Reference in New Issue
Block a user