Browse Source

statistics template fixed

master
Christian Müller 11 years ago
parent
commit
4d7d84948e
  1. 9
      src/notehub/views.clj

9
src/notehub/views.clj

@ -83,16 +83,17 @@
(let [page-title (get-message :statistics) (let [page-title (get-message :statistics)
info (assoc stats :publisher publisher)] info (assoc stats :publisher publisher)]
(layout :no-js {} page-title (layout :no-js {} page-title
[:h2.central-element note-title] [:div.central-element.helvetica {:style "width: 80%"}
[:h3.central-element.helvetica page-title] [:h2 note-title]
[:table#stats.helvetica.central-element [:h3.helvetica page-title]
[:table#stats
(map (map
#(when-let [v (% info)] #(when-let [v (% info)]
[:tr [:tr
[:td (str (get-message %) ":")] [:td (str (get-message %) ":")]
[:td (if (or (= % :published) (= % :edited)) [:td (if (or (= % :published) (= % :edited))
(str (java.util.Date. (Long/parseLong v))) v)]]) (str (java.util.Date. (Long/parseLong v))) v)]])
[:published :edited :publisher :views])]))) [:published :edited :publisher :views])]])))
(defn note-update-page [note-id note] (defn note-update-page [note-id note]
(input-form "/update-note" (input-form "/update-note"

Loading…
Cancel
Save