Sha256: cccaf46a0af1a88f7de61773608cc91802c690cd2dd1d36769f4a5aed3777738

Contents?: true

Size: 1.81 KB

Versions: 35

Compression:

Stored size: 1.81 KB

Contents

Rails.application.routes.draw do
  mount Scrivito::SdkEngine, at: '/', as: :scrivito_engine
end

Scrivito::SdkEngine.routes.draw do
  get 'scrivito', to: 'scrivito/ui#index'
  get 'scrivito/*application_path', to: 'scrivito/ui#index', format: false

  scope '__scrivito', module: 'scrivito' do
    get ':id', to: 'cms_dispatch#index', as: :base_id, constraints: {id: /\h{16}/}

    resources :objs, controller: 'objs', only: [], defaults: {format: :json} do
      collection do
        get :page_class_selection
        get :valid_page_classes
        get :search
      end

      member do
        get :widget
        get :widget_class_selection
        get :widget_modification
      end
    end

    resources :sessions, controller: 'sessions', only: [:update], defaults: {format: :json}

    get 'obj_class/:obj_class_name/defaults', to: 'obj_class#defaults'
    get 'obj_class/thumbnails', to: 'obj_class#thumbnails'

    put 'resolve_paths' => 'resolve_paths#resolve', defaults: {format: :json}

    get 'workspaces/:id/check', to: 'workspaces#check', defaults: {format: :json}
    put 'workspaces/:id/publish_approval',
      to: 'workspaces#publish_approval', defaults: {format: :json}

    put 'users/mget' => 'users#mget', defaults: {format: :json}
    get 'users/suggest' => 'users#suggest', defaults: {format: :json}

    put 'ui_configs/mget' => 'ui_configs#mget', defaults: {format: :json}
    put 'publish_abilities/mget' => 'publish_abilities#mget', defaults: {format: :json}

    get 'render_widget/:id/show_widget/:widget_id' => 'cms_dispatch#show_widget'
    get 'render_widget/:id/widget_details/:widget_id' => 'cms_dispatch#widget_details'

    get 'page_details/:id' => 'cms_dispatch#page_details'
    get 'resource_details/:resource_id', to: 'ui#index'

    get 'to_binary' => 'binary_redirect#to_binary', as: :binary
  end
end

Version data entries

35 entries across 35 versions & 1 rubygems

Version Path
scrivito_sdk-1.18.0 config/precedence_routes.rb
scrivito_sdk-1.18.0.rc1 config/precedence_routes.rb
scrivito_sdk-1.17.0 config/precedence_routes.rb
scrivito_sdk-1.17.0.rc3 config/precedence_routes.rb
scrivito_sdk-1.17.0.rc2 config/precedence_routes.rb
scrivito_sdk-1.17.0.rc1 config/precedence_routes.rb
scrivito_sdk-1.16.0 config/precedence_routes.rb
scrivito_sdk-1.16.0.rc2 config/precedence_routes.rb
scrivito_sdk-1.16.0.rc1 config/precedence_routes.rb
scrivito_sdk-1.15.0 config/precedence_routes.rb
scrivito_sdk-1.15.0.rc2 config/precedence_routes.rb
scrivito_sdk-1.15.0.rc1 config/precedence_routes.rb
scrivito_sdk-1.14.0 config/precedence_routes.rb
scrivito_sdk-1.14.0.rc3 config/precedence_routes.rb
scrivito_sdk-1.14.0.rc2 config/precedence_routes.rb
scrivito_sdk-1.14.0.rc1 config/precedence_routes.rb
scrivito_sdk-1.13.0 config/precedence_routes.rb
scrivito_sdk-1.13.0.rc2 config/precedence_routes.rb
scrivito_sdk-1.13.0.rc1 config/precedence_routes.rb
scrivito_sdk-1.12.0 config/precedence_routes.rb