Sha256: 6c99894694e9c90379c871febf1708b09e87ad97876c638538151a3bfeeca63b

Contents?: true

Size: 1.08 KB

Versions: 28

Compression:

Stored size: 1.08 KB

Contents

ConstructorPages::Engine.routes.draw do
  scope '/admin' do
    resources :pages, :except => [:show]
    resources :templates, :except => [:show]
    resources :fields, :except => [:show, :new, :edit]

    scope '/fields' do
      get ':template_id/new/' => 'fields#new', :as => :new_field
      get ':id/:template_id/edit/' => 'fields#edit', :as => :edit_field

      get 'move/up/:id' => "fields#move_up", :as => :field_move_up
      get 'move/down/:id' => "fields#move_down", :as => :field_move_down
    end

    scope '/pages' do
      post 'move/up/:id' => "pages#move_up", :as => :page_move_up
      post 'move/down/:id' => "pages#move_down", :as => :page_move_down
      
      get ':page/new' => "pages#new", :as => :new_child_page
    end

    scope '/templates' do
      post 'move/up/:id' => "templates#move_up", :as => :template_move_up
      post 'move/down/:id' => "templates#move_down", :as => :template_move_down
    end
  end

  root :to => "pages#show"
  get '*all/search/:what_search' => "pages#search", :format => false
  get '*all.:format' => "pages#show"
  get '*all' => "pages#show"
end

Version data entries

28 entries across 28 versions & 2 rubygems

Version Path
constructor-pages-0.6.1 config/routes.rb
constructor-cms-0.6.1 pages/config/routes.rb
constructor-pages-0.6.0 config/routes.rb
constructor-cms-0.6.0 pages/config/routes.rb
constructor-pages-0.5.8 config/routes.rb
constructor-cms-0.5.8 pages/config/routes.rb
constructor-pages-0.5.7 config/routes.rb
constructor-pages-0.5.6 config/routes.rb
constructor-pages-0.5.5 config/routes.rb
constructor-pages-0.5.4 config/routes.rb
constructor-pages-0.5.3 config/routes.rb
constructor-pages-0.5.2 config/routes.rb
constructor-pages-0.5.1 config/routes.rb
constructor-pages-0.5.0 config/routes.rb
constructor-pages-0.4.0 config/routes.rb
constructor-pages-0.3.3 config/routes.rb
constructor-pages-0.3.2 config/routes.rb
constructor-pages-0.3.1 config/routes.rb
constructor-pages-0.3.0 config/routes.rb
constructor-pages-0.2.14 config/routes.rb