Finished separating out manual import.
This commit is contained in:
@@ -37,6 +37,16 @@
|
||||
(assoc edit-transaction :class "live-added")
|
||||
t))
|
||||
ts))))))
|
||||
|
||||
(re-frame/reg-event-fx
|
||||
::manual-import-completed
|
||||
(fn [{:keys [db]} [_ {:keys [imported errors]}]]
|
||||
(println "MANUAL FINISHED")
|
||||
{:dispatch [::params-change {}]
|
||||
:db (-> db
|
||||
(assoc-in [::notification :message] (str "Successfully imported " imported " transactions"))
|
||||
(assoc-in [::notification :errors] errors))}))
|
||||
|
||||
(re-frame/reg-sub
|
||||
::transaction-page
|
||||
(fn [db]
|
||||
@@ -208,9 +218,9 @@
|
||||
[:li (:description-original transaction) "-" (:details error)])]])))
|
||||
[:div.is-pulled-right
|
||||
[:div.buttons
|
||||
[:button.button.is-danger {:on-click (dispatch-event [::manual/manual-yodlee-import])}
|
||||
[:button.button.is-danger {:on-click (dispatch-event [::manual/opening])}
|
||||
"Manage Rules"]
|
||||
[:button.button.is-danger {:on-click (dispatch-event [::manual/manual-yodlee-import])}
|
||||
[:button.button.is-danger {:on-click (dispatch-event [::manual/opening])}
|
||||
"Manual Yodlee Import"]]]))
|
||||
[transaction-table {:id :transactions
|
||||
:params (re-frame/subscribe [::params])
|
||||
@@ -218,7 +228,7 @@
|
||||
:status (re-frame/subscribe [::subs/status])
|
||||
:on-params-change (fn [params]
|
||||
(re-frame/dispatch [::params-change params]))}]
|
||||
[manual/manual-yodlee-import-modal]]))
|
||||
[manual/modal {:import-completed [::manual-import-completed ]}]]))
|
||||
{:component-will-mount #(re-frame/dispatch-sync [::params-change {}]) }))
|
||||
|
||||
(defn transactions-page []
|
||||
|
||||
Reference in New Issue
Block a user