# HG changeset patch # User Steve Losh # Date 1317258606 14400 # Node ID 3c52063ee45ef54a21191a44dedf52ec6687d559 # Parent 8d6cf4d81909a2ae61a7c88ba693d4c37e2c9389 Moar. diff -r 8d6cf4d81909 -r 3c52063ee45e resources/public/css/style.less --- a/resources/public/css/style.less Wed Sep 28 21:02:32 2011 -0400 +++ b/resources/public/css/style.less Wed Sep 28 21:10:06 2011 -0400 @@ -20,3 +20,8 @@ } } } +section.message { + border-bottom: 2px solid #ddd; + margin-top: -12px; + margin-bottom: 32px; +} diff -r 8d6cf4d81909 -r 3c52063ee45e src/newseasons/models/users.clj diff -r 8d6cf4d81909 -r 3c52063ee45e src/newseasons/templates/main.clj --- a/src/newseasons/templates/main.clj Wed Sep 28 21:02:32 2011 -0400 +++ b/src/newseasons/templates/main.clj Wed Sep 28 21:10:06 2011 -0400 @@ -1,4 +1,5 @@ (ns newseasons.templates.main + (:require [noir.session :as sess]) (:use noir.core hiccup.core hiccup.page-helpers @@ -27,6 +28,9 @@ [:body [:div.container.clearfix [:header.sixteen.columns [:h1 (link-to "/" "New Seasons")]] + (when-let [message (sess/flash-get)] + [:section.message.sixteen.columns + [:p message]]) content [:footer.sixteen.columns [:p diff -r 8d6cf4d81909 -r 3c52063ee45e src/newseasons/views/main.clj --- a/src/newseasons/views/main.clj Wed Sep 28 21:02:32 2011 -0400 +++ b/src/newseasons/views/main.clj Wed Sep 28 21:10:06 2011 -0400 @@ -2,6 +2,7 @@ (:require [newseasons.templates.main :as t]) (:use noir.core) (:require [noir.response :as resp]) + (:require [noir.session :as sess]) (:require [clj-http.client :as client]) (:use [cheshire.core :only (parse-string)])) @@ -43,7 +44,6 @@ ; Search ---------------------------------------------------------------------- - (defpage [:get "/search"] {:keys [query]} ; TODO: Images. (let [results (itunes-search-show query) @@ -54,4 +54,5 @@ ; Add ------------------------------------------------------------------------- (defpage [:post "/add"] {:as show} + (sess/flash-put! "Added a show to your list.") (resp/redirect "/"))