starting work on cash flow.
This commit is contained in:
@@ -47,6 +47,7 @@
|
||||
:address/state (:state (:address edit_client))
|
||||
:address/zip (:zip (:address edit_client))})
|
||||
|
||||
|
||||
:client/bank-accounts (map #(remove-nils
|
||||
{:db/id (:id %)
|
||||
:bank-account/code (:code %)
|
||||
@@ -67,7 +68,14 @@
|
||||
}
|
||||
) (:bank_accounts edit_client))
|
||||
|
||||
})]
|
||||
})
|
||||
[:reset id :client/forecasted-transactions (map #(remove-nils
|
||||
{:db/id (:id %)
|
||||
:forecasted-transaction/day-of-month (:day_of_month %)
|
||||
:forecasted-transaction/identifier (:identifier %)
|
||||
:forecasted-transaction/amount (:amount %)}
|
||||
)
|
||||
(:forecasted_transactions edit_client))]]
|
||||
result @(d/transact (d/connect uri) transactions)]
|
||||
(println result "ID" id)
|
||||
(-> result :tempids (get id) (or id) d-clients/get-by-id
|
||||
|
||||
@@ -17,8 +17,9 @@
|
||||
(defn get-invoice-page [context args value]
|
||||
|
||||
(let [args (assoc args :id (:id context))
|
||||
[invoices invoice-count] (d-invoices/get-graphql (update (<-graphql (assoc args :id (:id context))) :status enum->keyword "invoice-status"))]
|
||||
[invoices invoice-count outstanding] (d-invoices/get-graphql (update (<-graphql (assoc args :id (:id context))) :status enum->keyword "invoice-status"))]
|
||||
[{:invoices (map ->graphql invoices)
|
||||
:outstanding outstanding
|
||||
:total invoice-count
|
||||
:count (count invoices)
|
||||
:start (:start args 0)
|
||||
|
||||
Reference in New Issue
Block a user