Skip to content

Instantly share code, notes, and snippets.

@xumingming
Created May 8, 2012 11:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xumingming/2634328 to your computer and use it in GitHub Desktop.
Save xumingming/2634328 to your computer and use it in GitHub Desktop.
routes
(defroutes main-routes
(GET "/" []
(-> (main-page)
ui-template))
(GET "/topology/:id" [id & m]
(-> (topology-page id (:window m) true)
ui-template))
(GET "/topology/:id/component/:component" [id component & m]
(log-message "REQUEST: " request)
(-> (component-page id component (:window m) true)
ui-template))
(GET "/topology/:id/task/:task" [id task & m]
(-> (task-page id (Integer/parseInt task) (:window m))
ui-template))
(route/resources "/")
(route/not-found "Page not found"))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment