config/routes.rb in community_engine-3.0.0 vs config/routes.rb in community_engine-3.2.0
- old
+ new
@@ -1,6 +1,8 @@
Rails.application.routes.draw do
+ ActiveAdmin.routes(self)
+
concern :paginatable do
get '(page/:page)', :action => :index, :on => :collection
end
get '/base/:action' => 'base'
@@ -42,29 +44,19 @@
get 'sitemap.xml' => 'sitemap#index', :format => 'xml'
get 'sitemap' => 'sitemap#index'
get '/' => 'base#site_index', :as => :home
- scope "/admin" do
- get 'dashboard' => 'homepage_features#index', :as => :admin_dashboard
- match 'users' => 'admin#users', :as => :admin_users, :via => [:post, :get]
- get 'messages' => 'admin#messages', :as => :admin_messages
- match 'comments' => 'admin#comments', :as => :admin_comments, :via => [:post, :get]
- match 'tags' => 'tags#manage', :as => :admin_tags, :via => [:post, :get]
- get 'events' => 'admin#events', :as => :admin_events
- get 'clear_cache' => 'admin#clear_cache', :as => :admin_clear_cache
- get 'subscribers(.:format)' => "admin#subscribers", :as => :admin_subscribers
- get 'activate_user' => "admin#activate_user", :as => :admin_activate_user
- get 'deactivate_user' => 'admin#deactivate_user', :as => :admin_deactivate_user
+ root to: "base#site_index"
- resources :pages, :as => :admin_pages do
- member do
- get :preview
- end
- end
- end
+
+ # scope "/admin" do
+ # get 'dashboard' => 'homepage_features#index', :as => :admin_dashboard
+ # get 'clear_cache' => 'admin#clear_cache', :as => :admin_clear_cache
+ # end
+
get 'pages/:id' => 'pages#show', :as => :pages
get '/login' => 'sessions#new', :as => :login
get '/signup' => 'users#new', :as => :signup
@@ -74,11 +66,11 @@
get '/forgot_password' => 'password_resets#new', :as => :forgot_password
resources :password_resets
match '/forgot_username' => 'users#forgot_username', :as => :forgot_username, :via => [:get, :post]
- post '/resend_activation' => 'users#resend_activation', :as => :resend_activation
+ post '/resend_activation/:id' => 'users#resend_activation', :as => :resend_activation
get '/new_clipping' => 'clippings#new_clipping'
post '/load_images_from_uri' => 'clippings#load_images_from_uri', :format => 'js'
get '/clippings(/page/:page)' => 'clippings#site_index', :as => :site_clippings
get '/clippings.rss' => 'clippings#site_index', :as => :rss_site_clippings, :format => 'rss'
@@ -98,10 +90,12 @@
get '/friendships.xml' => 'friendships#index', :as => :friendships_xml, :format => 'xml'
get '/friendships' => 'friendships#index', :as => :friendships
get 'manage_photos' => 'photos#manage_photos', :as => :manage_photos
+ post 'manage_photos' => 'photos#create_photos', :as => :create_photos
+
post 'create_photo.js' => 'photos#create', :as => :create_photo, :format => 'js'
resources :sessions
resources :statistics do
collection do
@@ -249,7 +243,8 @@
resources :votes
resources :invitations
get '/users/:user_id/posts/category/:category_name' => 'posts#index', :as => :users_posts_in_category
post '/users/metro_area_update' => 'users#metro_area_update', :as => :users_metro_area_update
+
end