lots of QOL improvements.

This commit is contained in:
Bryce Covert
2020-07-31 18:26:57 -07:00
parent 98f0d40313
commit be9c789003
15 changed files with 302 additions and 282 deletions

View File

@@ -38,7 +38,13 @@
(re-frame/reg-sub
::invoice-page
(fn [db]
(-> db ::invoice-page)))
(-> (::invoice-page db)
(update :invoices
(fn [is]
(mapv
(fn [i]
(assoc i :checkable? (not (:automatically-paid-when-due i))))
is))))))
(re-frame/reg-sub
::invoice
@@ -112,8 +118,7 @@
(re-frame/reg-event-fx
::unmounted
(fn [{:keys [db]} _]
(println "UNMOUNTING?")
{:db (dissoc db ::invoice-page ::table/table-params ::side-bar/filters ::last-params)}))
{:db (dissoc db ::invoice-page ::table/table-params ::side-bar/filters ::side-bar/settled-filters ::last-params)}))
(re-frame/reg-event-db
::received