OSDN Git Service

t#32046:
[pettanr/pettanr.git] / config / routes.rb
index 38fe01c..48f61d0 100644 (file)
@@ -7,6 +7,9 @@ Pettanr::Application.routes.draw do
   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
@@ -24,13 +27,13 @@ Pettanr::Application.routes.draw do
       put :update
       delete :destroy
       get :browse
-      get :comics
-      get :stories
+      get :scrolls
+      get :scroll_panels
       get :panels
       get :panel_pictures
+      get :speech_balloons
       get :ground_pictures
       get :ground_colors
-      get :panel_colors
     end
   end
   resources :artists do
@@ -64,6 +67,7 @@ Pettanr::Application.routes.draw do
       get :list
     end
     member do
+      get :play
       get :edit
       put :update
       delete :destroy
@@ -82,7 +86,77 @@ Pettanr::Application.routes.draw do
     end
     member do
       get :edit
-      get :comic
+      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
@@ -125,12 +199,19 @@ Pettanr::Application.routes.draw do
     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
@@ -170,11 +251,17 @@ Pettanr::Application.routes.draw do
     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
@@ -357,7 +444,7 @@ Pettanr::Application.routes.draw do
   # Keep in mind you can assign values other than :controller and :action
   match 'resource_pictures/:subdir/:id(.:format)/' => 'resource_pictures#show'
   match 'pictures/:subdir/:id(.:format)/' => 'pictures#show'
-  #match 'stories/comic/:id(.:format)' => 'stories#comic'
+  #match 'scroll_panels/scroll/:id(.:format)' => 'scroll_panels#scroll'
   match 'top/(:action)', :controller => 'top'
   match 'home/(:action)', :controller => 'home'
   match 'system/(:action)', :controller => 'system'