Makes plaid user configurable

This commit is contained in:
Bryce
2023-07-24 20:55:40 -07:00
parent 445375d15e
commit 5b5b15cb27
15 changed files with 212 additions and 422 deletions

View File

@@ -51,7 +51,7 @@
))
"default sort"))
(defn table* [grid-spec user {:keys [start per-page client flash-id sort request]}]
(defn table* [grid-spec user {:keys [start per-page client flash-id sort request] :as params}]
(let [start (or start 0)
per-page (or per-page 30)
[entities total] ((:fetch-page grid-spec)
@@ -70,7 +70,7 @@
:subtitle [:div.flex.items-center.gap-2
[:span (format "Total %s: %d, " (:entity-name grid-spec) total)]
(sort-by-list sort)]
:action-buttons ((:action-buttons grid-spec) user)
:action-buttons ((:action-buttons grid-spec) user params)
:rows (for [entity entities]
(row* grid-spec user entity {:flash? (= flash-id ((:id-fn grid-spec) entity))}))
:thead-params {:hx-get (bidi/path-for ssr-routes/only-routes