Skip to content

Instantly share code, notes, and snippets.

@sergiomichels
Created September 23, 2013 20:14
Show Gist options
  • Select an option

  • Save sergiomichels/6676249 to your computer and use it in GitHub Desktop.

Select an option

Save sergiomichels/6676249 to your computer and use it in GitHub Desktop.
Magic to access request inside UrlMappings
class UrlMappings {
static mappings = {
"/$controller/$action?/$id?"{
constraints {
// apply constraints here
}
}
"/" {
println request //Nope, just Chuck Testa!
controller = {
println request //Oh yeah
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment