2010-02-16 08:31:49 -05:00
|
|
|
Rails::Application.routes.draw do
|
2010-02-16 10:11:30 -05:00
|
|
|
resources :users, :only => [:index] do
|
|
|
|
get :expire, :on => :member
|
|
|
|
end
|
|
|
|
|
2010-02-17 07:15:19 -05:00
|
|
|
resources :admins, :only => [:index]
|
|
|
|
|
2010-02-16 08:31:49 -05:00
|
|
|
devise_for :users
|
2010-03-29 10:13:19 -04:00
|
|
|
devise_for :admin, :as => "admin_area", :controllers => { :sessions => "sessions" }, :skip => :passwords
|
2010-02-17 07:15:19 -05:00
|
|
|
devise_for :accounts, :scope => "manager", :path_prefix => ":locale",
|
2010-02-16 11:00:36 -05:00
|
|
|
:class_name => "User", :path_names => {
|
2010-02-17 07:15:19 -05:00
|
|
|
:sign_in => "login", :sign_out => "logout",
|
|
|
|
:password => "secret", :confirmation => "verification",
|
|
|
|
:unlock => "unblock", :sign_up => "register"
|
2010-01-13 13:45:24 -05:00
|
|
|
}
|
2009-10-12 20:49:51 -04:00
|
|
|
|
2010-02-17 07:15:19 -05:00
|
|
|
match "/admin_area/home", :to => "admins#index", :as => :admin_root
|
|
|
|
match "/sign_in", :to => "devise/sessions#new"
|
2009-10-18 13:25:16 -04:00
|
|
|
|
2010-03-12 03:54:57 -05:00
|
|
|
# Dummy route for new admin pasword
|
|
|
|
match "/anywhere", :to => "foo#bar", :as => :new_admin_password
|
|
|
|
|
2010-02-17 07:15:19 -05:00
|
|
|
root :to => "home#index"
|
|
|
|
end
|