fixes tests.
This commit is contained in:
@@ -45,8 +45,7 @@
|
||||
:where '[[?e :payment/client ?c]]}
|
||||
:args [db
|
||||
(:exact-match-id args)
|
||||
(map :db/id (:clients args))]
|
||||
}
|
||||
(map :db/id (:clients args))]}
|
||||
(cond-> {:query {:find []
|
||||
:in ['$]
|
||||
:where []}
|
||||
@@ -67,7 +66,7 @@
|
||||
:where []}
|
||||
:args [(:exact-match-id args)]})
|
||||
|
||||
(seq (:clients args))
|
||||
true
|
||||
(merge-query {:query {:in ['[?xx ...]]
|
||||
:where ['[?e :payment/client ?xx]]}
|
||||
:args [(map :db/id (:clients args))]})
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
"fee" ['[?e :expected-deposit/fee ?sort-fee]]}
|
||||
args)
|
||||
|
||||
(seq (:clients args))
|
||||
true
|
||||
(merge-query {:query {:in ['[?xx ...]]
|
||||
:where ['[?e :expected-deposit/client ?xx]]}
|
||||
:args [(set (map :db/id (:clients args)))]})
|
||||
|
||||
@@ -99,7 +99,7 @@
|
||||
:where ['[?e :invoice/due ?due]
|
||||
'[(<= ?due ?end-due)]]}
|
||||
:args [(coerce/to-date (:end (:due-range args)))]})
|
||||
(seq (:clients args))
|
||||
true
|
||||
(merge-query {:query {:in ['[?xx ...]]
|
||||
:where ['[?e :invoice/client ?xx]]}
|
||||
:args [ (map :db/id (:clients args))]})
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
:where []}
|
||||
:args [db]}
|
||||
|
||||
(seq (:clients args))
|
||||
true
|
||||
(merge-query {:query {:in ['[?xx ...]]
|
||||
:where ['[?e :journal-entry/client ?xx]]}
|
||||
:args [(set (map :db/id (:clients args)))]})
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
(merge-query {:query {:in '[[?e ...]]}
|
||||
:args [potential-duplicates]})
|
||||
|
||||
(seq (:clients args))
|
||||
true
|
||||
(merge-query {:query {:in ['[?xx ...]]
|
||||
:where ['[?e :transaction/client ?xx]]}
|
||||
:args [(set (map :db/id (:clients args)))]})
|
||||
|
||||
@@ -454,6 +454,7 @@
|
||||
(let [transaction (d-transactions/get-by-id (:transaction_id args))
|
||||
_ (assert-can-see-client (:id context) (:transaction/client transaction))
|
||||
[payments _] (d-checks/get-graphql {:client-id (:db/id (:transaction/client transaction))
|
||||
:clients [{:db/id (:db/id (:transaction/client transaction))}]
|
||||
:bank-account-id (:db/id (:transaction/bank-account transaction))
|
||||
:amount (- (:transaction/amount transaction))
|
||||
:status :payment-status/pending
|
||||
|
||||
@@ -256,6 +256,7 @@
|
||||
(let [ids (some-> args
|
||||
:filters
|
||||
(<-graphql)
|
||||
(assoc :clients (:clients args))
|
||||
(update :status enum->keyword "invoice-status")
|
||||
(assoc :per-page Integer/MAX_VALUE)
|
||||
d-invoices/raw-graphql-ids
|
||||
|
||||
Reference in New Issue
Block a user