Adds ability to find expected deposits and link them
This commit is contained in:
@@ -22,6 +22,7 @@
|
||||
{:start (:start params 0)
|
||||
:sort (:sort params)
|
||||
:per-page (:per-page params)
|
||||
:exact-match-id (some-> (:exact-match-id params) str)
|
||||
:total-gte (:amount-gte (:total-range params))
|
||||
:total-lte (:amount-lte (:total-range params))
|
||||
:date-range (:date-range params)
|
||||
|
||||
@@ -51,5 +51,12 @@
|
||||
"Uber Eats"]
|
||||
[:a.panel-block {:on-click (dispatch-event [::data-page/filter-changed data-page :processor "grubhub"])}
|
||||
[:span.panel-icon [:img.level-item {:src "/img/grubhub.png"}]]
|
||||
"Grubhub"]]]])]]))
|
||||
"Grubhub"]]]])
|
||||
|
||||
(when-let [exact-match-id @(re-frame/subscribe [::data-page/filter data-page :exact-match-id])]
|
||||
[:div
|
||||
[:p.menu-label "Specific Expected Deposit"]
|
||||
[:span.tag.is-medium exact-match-id " "
|
||||
[:button.delete.is-small {:on-click
|
||||
(dispatch-event [::data-page/filter-changed data-page :exact-match-id nil])}]]])]]))
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
:date
|
||||
[:yodlee_merchant [:name :yodlee-id :id]]
|
||||
:post_date
|
||||
[:expected-deposit [:id :date]]
|
||||
[:forecast-match [:id :identifier]]
|
||||
:status
|
||||
:description_original
|
||||
|
||||
@@ -92,9 +92,10 @@
|
||||
[grid/sortable-header-cell {:sort-key "status" :sort-name "Status" :style {:width "7em"}} "Status"]
|
||||
[grid/header-cell {:style {:width (action-cell-width 3)}}]]]
|
||||
[grid/body
|
||||
(for [{:keys [client account vendor approval-status payment status bank-account description-original date amount id yodlee-merchant ] :as i} (:data data)]
|
||||
(for [{:keys [client account vendor approval-status payment expected-deposit status bank-account description-original date amount id yodlee-merchant ] :as i} (:data data)]
|
||||
^{:key id}
|
||||
[grid/row {:class (:class i) :id id :entity i}
|
||||
(println expected-deposit)
|
||||
(when-not selected-client
|
||||
[grid/cell {} (:name client)])
|
||||
|
||||
@@ -124,7 +125,7 @@
|
||||
[buttons/fa-icon {:event [::intend-to-edit i]
|
||||
:class (status/class-for (get states id))
|
||||
:icon "fa-pencil"}]
|
||||
(when payment
|
||||
(when (some identity [payment expected-deposit])
|
||||
[drop-down {:id [::links id]
|
||||
:is-right? true
|
||||
:header [buttons/fa-icon {:class "badge"
|
||||
@@ -135,12 +136,23 @@
|
||||
[:div.dropdown-item
|
||||
[:table.table.grid.compact
|
||||
[:tbody
|
||||
[:tr
|
||||
[:td
|
||||
"Payment"]
|
||||
[:td (date->str (:date payment) pretty)]
|
||||
[:td
|
||||
[buttons/fa-icon {:icon "fa-external-link"
|
||||
:href (str (bidi/path-for routes/routes :payments )
|
||||
"?"
|
||||
(url/map->query {:exact-match-id (:id payment)}))}]]]]]]]])]]])]]]))
|
||||
(when payment
|
||||
[:tr
|
||||
[:td
|
||||
"Payment"]
|
||||
[:td (date->str (:date payment) pretty)]
|
||||
[:td
|
||||
[buttons/fa-icon {:icon "fa-external-link"
|
||||
:href (str (bidi/path-for routes/routes :payments )
|
||||
"?"
|
||||
(url/map->query {:exact-match-id (:id payment)}))}]]])
|
||||
(when expected-deposit
|
||||
[:tr
|
||||
[:td
|
||||
"Expected Deposit"]
|
||||
[:td (date->str (:date expected-deposit) pretty)]
|
||||
[:td
|
||||
[buttons/fa-icon {:icon "fa-external-link"
|
||||
:href (str (bidi/path-for routes/routes :expected-deposits )
|
||||
"?"
|
||||
(url/map->query {:exact-match-id (:id expected-deposit)}))}]]])]]]]])]]])]]]))
|
||||
|
||||
Reference in New Issue
Block a user