Skip to content

Instantly share code, notes, and snippets.

@tkawa
Created July 16, 2012 06:02
Show Gist options
  • Save tkawa/3120981 to your computer and use it in GitHub Desktop.
Save tkawa/3120981 to your computer and use it in GitHub Desktop.
class GroupsController < AppController
resources_path 'users/groups', 'my/groups'
def index
end
def show
end
def update
end
end
# Class method and HTTP-style methods.
class ReportsController < AppController
before_filter :authenticate
get "/reports" do
end
get "/reports/:id" do
end
put "/reports/:id" do
end
end
Hoge::Application.routes.draw do
namespace :admin do
namespace :special do
resources :licenses
end
resources :users
end
resources :users
end
class UsersController < AppController
resources_path 'users'
resource_path 'my'
def index
end
def show
end
def update
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment