Adding list() to client & api route.

This commit is contained in:
Matthew Dillon 2014-09-30 09:51:07 -08:00
parent da7be2e150
commit 76d5264474
5 changed files with 98 additions and 2 deletions

View file

@ -4,6 +4,7 @@ import "github.com/gorilla/mux"
func API() *mux.Router {
m := mux.NewRouter()
m.Path("/users").Methods("GET").Name(Users)
m.Path("/users/{Id:.+}").Methods("GET").Name(User)
return m
}

View file

@ -1,5 +1,6 @@
package router
const (
User = "user"
User = "user"
Users = "users"
)