filter transaction by vendor

This commit is contained in:
Bryce Covert
2020-03-21 12:21:22 -07:00
parent 228fda8f65
commit f0ac926700
4 changed files with 27 additions and 11 deletions

View File

@@ -54,6 +54,11 @@
(merge-query {:query {:in ['?client-id]
:where ['[?e :transaction/client ?client-id]]}
:args [(:client-id args)]})
(:vendor-id args)
(merge-query {:query {:in ['?vendor-id]
:where ['[?e :transaction/vendor ?vendor-id]]}
:args [(:vendor-id args)]})
(:start (:date-range args))
(merge-query {:query {:in ['?start-date]
:where ['[?e :transaction/date ?date]

View File

@@ -396,6 +396,7 @@
:transaction_page {:type '(list :transaction_page)
:args {:client_id {:type :id}
:vendor_id {:type :id}
:bank_account_id {:type :id}
:date_range {:type :date_range}
:start {:type 'Int}

View File

@@ -278,15 +278,6 @@
(context "/invoices" []
(POST "/upload"
<<<<<<< HEAD
{{ file :file } :params :as params}
#_(clojure.pprint/pprint params)
(let [{:keys [filename tempfile]} file]
(import-uploaded-invoice (parse/parse-file (.getPath tempfile) filename))
{:status 200
:body (pr-str {})
:headers {"Content-Type" "application/edn"}}))
=======
{{ files "file"} :params :as params}
(let [{:keys [filename tempfile]} files]
(try
@@ -300,7 +291,6 @@
:data (ex-data e)})
:headers {"Content-Type" "application/edn"}}))
))
>>>>>>> master
(POST "/upload-integreat"
{{:keys [excel-rows]} :edn-params user :identity}
(assert-admin user)