                                        (>! event-channel [:metric-selected selected-metric])))))))
     om/IRenderState
     (render-state [_ {:keys [event-channel]}]
+      (println "selecting")
       (html
        [:div.form-group
         [:label {:for "metrics-selector"} "Metric:"]

  (reify
    om/IDidMount
    (did-mount [_]
      (let [start-element (js/$ (om/get-node owner "start-date"))
            end-element (js/$ (om/get-node owner "end-date"))
            start-datepicker (.datepicker start-element #js {:format "yyyy-mm-dd"})
            end-datepicker (.datepicker end-element #js {:format "yyyy-mm-dd"})]
        start-datepicker))

    om/IRenderState

                   [cljs.core.match.macros :refer [match]]))

(ws-repl/connect "ws://localhost:9001" :verbose true)
(enable-console-print!)

(def date-formatter (timef/formatter "yyyy-MM-dd"))

(let [end-date (time/today-at 12 00)
      start-date (time/minus end-date (time/months 1))
      end-date (timef/unparse date-formatter end-date)
      start-date (timef/unparse date-formatter start-date)]
