added payment status and made checks sort correctly.
This commit is contained in:
@@ -375,7 +375,10 @@
|
||||
|
||||
(defn get-payment-page [context args value]
|
||||
(let [args (assoc args :id (:id context))
|
||||
[payments checks-count] (d-checks/get-graphql (update (<-graphql args) :payment-type enum->keyword "payment-type"))]
|
||||
[payments checks-count] (d-checks/get-graphql (-> args
|
||||
(<-graphql)
|
||||
(update :payment-type enum->keyword "payment-type")
|
||||
(update :status enum->keyword "payment-status")))]
|
||||
|
||||
[{:payments (->> payments
|
||||
(map (fn [payment]
|
||||
@@ -511,6 +514,7 @@
|
||||
:args {:client_id {:type :id}
|
||||
:vendor_id {:type :id}
|
||||
:payment_type {:type :payment_type}
|
||||
:status {:type :payment_status}
|
||||
:exact_match_id {:type :id}
|
||||
:date_range {:type :date_range}
|
||||
:amount_lte {:type :money}
|
||||
@@ -550,7 +554,11 @@
|
||||
{:payment_type {:values [{:enum-value :check}
|
||||
{:enum-value :cash}
|
||||
{:enum-value :debit}
|
||||
{:enum-value :credit}]}})
|
||||
{:enum-value :credit}]}
|
||||
:payment_status {:values [{:enum-value :voided}
|
||||
{:enum-value :pending}
|
||||
{:enum-value :cleared}]}})
|
||||
|
||||
|
||||
(def resolvers
|
||||
{:get-potential-payments get-potential-payments
|
||||
|
||||
Reference in New Issue
Block a user