Advertisement
Guest User

Untitled

a guest
Apr 27th, 2017
124
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. (defn ross-questions-page [customer-id {:keys [localize]} db]
  2.   (f/attempt-all [customer (db-cust/get-by-id db customer-id localize)
  3.                   _ (s-cust/validate-customer-belongs-to-user customer (sess/get :user-id) localize)
  4.                   questions (db-quest/get-by-customer-id db customer-id localize)
  5.                   rehashed-questions (quest/prepare-data-for-vec-of-ross-questions questions)
  6.                   question-headlines-and-points (quest/get-question-headlines-and-points quest/ross-questions)]
  7.                  (layout/render "customer/ross-questions.html" {:questions (vec questions)
  8.                                                                 :rehashed-questions rehashed-questions
  9.                                                                 :question-headlines-and-points question-headlines-and-points})
  10.                  (f/when-failed [e]
  11.                                 (layout/flash-result (:message e) "alert-danger")
  12.                                 (redirect "/customer"))))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement