fixing a number of bugs
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
(ns auto-ap.views.utils
|
||||
(:require [re-frame.core :as re-frame]))
|
||||
(:require [re-frame.core :as re-frame]
|
||||
[cljs-time.format :as format]))
|
||||
|
||||
(defn active-when= [active-page candidate]
|
||||
(when (= active-page candidate) " active"))
|
||||
@@ -18,3 +19,12 @@
|
||||
(fn [e]
|
||||
(.preventDefault e)
|
||||
(re-frame/dispatch event)))
|
||||
|
||||
(def pretty-long (format/formatter "MM/dd/yyyy HH:mm:ss"))
|
||||
(def pretty (format/formatter "MM/dd/yyyy"))
|
||||
|
||||
(defn date->str [d]
|
||||
(format/unparse pretty d))
|
||||
|
||||
(defn date-time->str [d]
|
||||
(format/unparse pretty-long d))
|
||||
|
||||
Reference in New Issue
Block a user