Skip to content

Instantly share code, notes, and snippets.

@watson
Created October 19, 2011 08:59
Show Gist options
  • Save watson/1297786 to your computer and use it in GitHub Desktop.
Save watson/1297786 to your computer and use it in GitHub Desktop.
As per request by http://groups.google.com/group/activeadmin/msg/87ae141ae19e889d here's my Active Admin dashboard and routes
ActiveAdmin::Dashboards.build do
end
...
admin_dashboard /admin(.:format) {:action=>"index", :controller=>"admin/dashboard"}
...
new_user_session GET /users/sign_in(.:format) {:action=>"new", :controller=>"devise/sessions"}
user_session POST /users/sign_in(.:format) {:action=>"create", :controller=>"devise/sessions"}
destroy_user_session GET /users/sign_out(.:format) {:action=>"destroy", :controller=>"devise/sessions"}
user_password POST /users/password(.:format) {:action=>"create", :controller=>"devise/passwords"}
new_user_password GET /users/password/new(.:format) {:action=>"new", :controller=>"devise/passwords"}
edit_user_password GET /users/password/edit(.:format) {:action=>"edit", :controller=>"devise/passwords"}
PUT /users/password(.:format) {:action=>"update", :controller=>"devise/passwords"}
...
MyApp::Application.routes.draw do
filter :locale # add locale to the beginning of the url. e.g. /en/admin
ActiveAdmin.routes(self)
devise_for :users,
:controllers => {
:registrations => "registrations"
}
...
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment