idea for cash flow linkage. makes invoices use uri parameters.
This commit is contained in:
@@ -17,6 +17,22 @@
|
||||
(fn [uri]
|
||||
(pushy/set-token! p/history uri)))
|
||||
|
||||
(re-frame/reg-fx
|
||||
:set-uri-params
|
||||
(fn [uri-params]
|
||||
(pushy/set-token! p/history
|
||||
(str (.-protocol (.-location js/window)) "//" (.-host (.-location js/window)) (.-pathname (.-location js/window))
|
||||
"?"
|
||||
(cemerick.url/map->query (into {} (filter (fn [[k v]] v) uri-params)))
|
||||
#_(reduce-kv (fn [result k v]
|
||||
(if v
|
||||
(str (or result "?")
|
||||
(when result "&")
|
||||
(name k) "=" (js/encodeURI v))
|
||||
result))
|
||||
nil
|
||||
uri-params)))))
|
||||
|
||||
(re-frame/reg-fx
|
||||
:new-window
|
||||
(fn [url]
|
||||
|
||||
Reference in New Issue
Block a user