Migrates back to datomic on-prem

This commit is contained in:
2023-04-29 07:12:51 -07:00
parent aca8f7c92c
commit b2ad7790cf
88 changed files with 2289 additions and 2286 deletions

View File

@@ -6,10 +6,11 @@
apply-sort-3
conn
merge-query
pull-many]]
pull-many
query2]]
[auto-ap.graphql.utils :refer [limited-clients]]
[clojure.string :as str]
[datomic.client.api :as dc]))
[datomic.api :as dc]))
(defn <-datomic [result]
result)
@@ -82,8 +83,7 @@
:where ['[?e :transaction-rule/transaction-approval-status]]}}))]
(cond->> query
true (dc/q)
(cond->> (query2 query)
true (apply-sort-3 args)
true (apply-pagination args))))
@@ -109,10 +109,10 @@
(defn get-all []
(mapv first
(dc/q {:query {:find [(list 'pull '?e default-read )]
:in ['$]
:where ['[?e :transaction-rule/transaction-approval-status]]}
:args [(dc/db conn)]})))
(dc/q {:find [(list 'pull '?e default-read )]
:in ['$]
:where ['[?e :transaction-rule/transaction-approval-status]]}
(dc/db conn))))
(defn get-all-for-client [client-id]
(mapv first