adding ability to choose location

This commit is contained in:
Bryce Covert
2018-07-23 13:36:02 -07:00
parent ecc5dc7d77
commit 695cd38227
6 changed files with 34 additions and 6 deletions

View File

@@ -75,10 +75,9 @@
(re-frame/reg-event-db
::change-form
(fn [db [_ location field value]]
(println location field value)
(if value
(assoc-in db (into location field) value)
(update-in db location dissoc field))))
(update-in db (into location (butlast field)) dissoc (last field)))))
(re-frame/reg-event-db
::modal-status