User can set up sales queries on their own now.

This commit is contained in:
2022-04-07 08:22:50 -07:00
parent a4c823c9ff
commit 45cf97a480
7 changed files with 288 additions and 224 deletions

View File

@@ -40,13 +40,12 @@
:user/name (:name profile)})
]
(log/info "authenticated as user" user)
;; TODO - these namespaces are not being transmitted/deserialized properly
(if (and token user)
(let [jwt (jwt/sign {:user (:name profile)
:exp (time/plus (time/now) (time/days 30))
:user/clients (map (fn [c]
(dissoc c :client/bank-accounts :client/location-matches :client/forecasted-transactions :client/matches :client/week-a-debits :client/week-a-credits :client/week-b-debits :client/week-b-credits :client/signature-file :client/address :client/emails :client/square-auth-token :client/square-locations))
(select-keys c [:client/code :db/id :client/name :client/locations]))
(:user/clients user))
:user/role (name (:user/role user))
:user/name (:name profile)}