Pettanr::Application.routes.draw do
+ devise_for :users
devise_for :admins
- devise_for :authors
-
- match 'original_pictures/:id(.:format)/refresh' => 'original_pictures#refresh'
-
- resources :artists, except: [:new, :edit]
- resources :speaches, only: [:index]
- resources :balloons, only: [:index]
- resources :speach_templates, only: [:index]
- resources :balloon_templates, only: [:index]
- resources :speach_balloons, except: [:new, :edit]
- resources :panel_pictures, only: [:index]
- resources :resource_pictures, only: [:index, :show]
- resources :original_pictures, except: [:new]
- resources :panels, except: [:new, :edit]
- resources :comics, except: [:new, :edit]
- resources :lisences, only: [:index]
- resources :original_lisences
- resources :common_lisences
-
+ devise_for :demand_users
+
+ Pettanr::Application.licenses.each do |name, klass|
+ mount Module.const_get(klass)::Engine => "/#{name}"
+ end
+ Pettanr::Application.speech_balloons.each do |klass , name|
+ mount Module.const_get(klass)::Engine => "/#{name}"
+ end
+
+ resources :authors do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ get :count
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ get :scrolls
+ get :scroll_panels
+ get :panels
+ get :panel_pictures
+ get :speech_balloons
+ get :ground_pictures
+ get :ground_colors
+ end
+ end
+ resources :artists do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ get :count
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ get :resource_pictures
+ end
+ end
+ resources :comics do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ get :count
+ post :create
+ get :list
+ end
+ member do
+ get :play
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :stories do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :sheets do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ get :count
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :sheet_panels do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :scrolls do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ get :count
+ post :create
+ get :list
+ end
+ member do
+ get :play
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :scroll_panels do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :panels do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ get :count
+ post :create
+ get :list
+ end
+ member do
+ get :catch
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :panel_pictures do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :speech_balloons do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :balloons do
+ collection do
+ get :index
+ get :show
+ get :list
+ end
+ member do
+ get :browse
+ end
+ end
+ resources :speeches do
+ collection do
+ get :index
+ get :show
+ get :list
+ end
+ member do
+ get :browse
+ end
+ end
+ resources :ground_colors do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :ground_pictures do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :browse
+ end
+ end
+ resources :original_pictures do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ post :create
+ get :list
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ get :history
+ get :browse
+ end
+ end
+ resources :resource_pictures do
+ collection do
+ get :index
+ get :show
+ get :new
+ post :create
+ get :count
+ get :list
+ end
+ member do
+ delete :destroy
+ get :credit
+ get :browse
+ end
+ end
+ resources :pictures do
+ collection do
+ get :show
+ get :credit
+ get :search
+ get :list
+ end
+ member do
+ get :credit
+ get :browse
+ end
+ end
+ resources :speech_balloon_templates do
+ collection do
+ get :index
+ get :show
+ get :list
+ end
+ member do
+ get :browse
+ delete :destroy
+ end
+ end
+ resources :licenses do
+ collection do
+ get :index
+ get :show
+ get :search
+ get :list
+ end
+ member do
+ get :browse
+ end
+ end
+ resources :license_groups do
+ collection do
+ get :index
+ get :show
+ get :list
+ end
+ member do
+ get :browse
+ delete :destroy
+ end
+ end
+ resources :original_picture_license_groups do
+ new do
+ post :new
+ end
+ collection do
+ post :create
+ end
+ end
+ resources :system_pictures do
+ collection do
+ get :index
+ get :show
+ get :list
+ end
+ member do
+ get :browse
+ delete :destroy
+ end
+ end
+ resources :provider_sources do
+ collection do
+ get :index
+ post :import
+ get :list
+ get :browse
+ end
+ member do
+ end
+ end
+ resources :providers do
+ collection do
+ get :index
+ get :show
+ get :list
+ get :browse
+ end
+ member do
+ delete :destroy
+ end
+ end
+ resources :provider_statuses do
+ collection do
+ get :index
+ get :show
+ get :list
+ get :browse
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ post :licenses_import
+ post :artists_import
+ post :original_pictures_import
+ post :import
+ end
+ end
+ resources :demanders do
+ new do
+ get :new
+ end
+ collection do
+ get :index
+ get :show
+ post :create
+ get :list
+ get :browse
+ post :req
+ get :licenses_export
+ get :artists_export
+ get :original_pictures_export
+ get :pictures_export
+ get :export
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ end
+ end
+ resources :demander_statuses do
+ collection do
+ get :index
+ get :show
+ get :list
+ get :browse
+ end
+ member do
+ get :edit
+ put :update
+ delete :destroy
+ end
+ end
# The priority is based upon order of creation:
# first created -> highest priority.
# Sample of regular route:
# match 'products/:id' => 'catalog#view'
# Keep in mind you can assign values other than :controller and :action
- match 'comics/:id(.:format)/play' => 'comics#play'
match 'resource_pictures/:subdir/:id(.:format)/' => 'resource_pictures#show'
+ match 'pictures/:subdir/:id(.:format)/' => 'pictures#show'
+ #match 'scroll_panels/scroll/:id(.:format)' => 'scroll_panels#scroll'
+ match 'top/(:action)', :controller => 'top'
match 'home/(:action)', :controller => 'home'
- match 'help/(:action)', :controller => 'help'
- controller 'system' do
- get 'start'
-# match 'start', :to => 'system#start'
- end
+ match 'system/(:action)', :controller => 'system'
+ #match 'authors/(:action(/:id))', :controller => 'authors'
# Sample of named route:
# match 'products/:id/purchase' => 'catalog#purchase', :as => :purchase
# You can have the root of your site routed with "root"
# just remember to delete public/index.html.
- root :to => 'comics#top'
+ root :to => 'top#index'
# See how all your routes lay out with "rake routes"
# This is a legacy wild controller route that's not recommended for RESTful applications.
# Note: This route will make all actions in every controller accessible via GET requests.
-# match ':controller(/:action(/:id(.:format)))'
+ match ':controller(/:action(/:id(.:format)))'
end