Sha256: 23c2b0bddf9b50bf87b28a6abd260f44cbb08d83055a4e264924ec132919a4ce

Contents?: true

Size: 2 KB

Versions: 3

Compression:

Stored size: 2 KB

Contents

TrustyCms::Application.routes.draw do
  root to: 'site#show_page'
  devise_for :users, module: :devise, skip: :registration
  as :user do
    post 'authenticate', to: 'devise/sessions#create', as: :authenticate
  end
  post '/page-status/refresh' => 'page_status#refresh'
  get '/rad_social/mail' => 'social_mailer#social_mail_form', as: :rad_social_mail_form
  post '/rad_social/mail' => 'social_mailer#create_social_mail', as: :rad_create_social_mail
  TrustyCms::Application.config.enabled_extensions.each do |ext|
  end
  namespace :admin do
    resources :pages do
      resources :children, controller: 'pages'
      get 'remove', on: :member
    end
    resources :layouts do
      get 'remove', on: :member
    end
    resources :users do
      get 'remove', on: :member
    end
    resources :snippets do
      get :remove, on: :member
    end
    post 'save-table-position' => 'pages#save_table_position', as: 'save_tables_position'

    resources :assets do
      get :remove, on: :member
      get :refresh, on: :collection
      put :refresh, on: :member
    end
    resources :page_attachments, only: [:new] do
      get :remove, on: :member
    end
    resources :pages do
      get :remove, on: :member
      resources :page_attachments
    end
  end

  match 'admin/preview' => 'admin/pages#preview', :as => :preview, :via => %i[post put]
  get 'admin' => 'admin/pages#index'

  namespace :admin do
    resource :preferences
    resource :configuration, controller: 'configuration'
    resources :extensions, only: :index
    resources :page_parts
    resources :page_fields
    match '/reference/:type(.:format)' => 'references#show', :as => :reference, :via => :get

    resources :sites do
      get :remove, on: :member
      post :move_higher, on: :member
      post :move_lower, on: :member
      put :move_to_top, on: :member
      put :move_to_bottom, on: :member
    end
  end

  get 'error/404' => 'site#not_found', :as => :not_found
  get 'error/500' => 'site#error', :as => :error
  get '*url' => 'site#show_page'
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
trusty-cms-7.0.6 config/routes.rb
trusty-cms-7.0.5 config/routes.rb
trusty-cms-7.0.4 config/routes.rb