Sha256: 555767a65ecb2fd258132f9a3c6e93bbba4ab075d961cd8647502ceb081b1caf

Contents?: true

Size: 1020 Bytes

Versions: 3

Compression:

Stored size: 1020 Bytes

Contents

PhcdevworksTutorials::Engine.routes.draw do

    # Tutorial Routes
    namespace :tutorial do
        resources :posts, class_name: "Tutorial::Post" do
            resources :steps, class_name: "Tutorial::Step"
        end
    end

    # Command Routes
    namespace :command do
        resources :posts, class_name: "Command::Post" do
            resources :items, class_name: "Command::Item"
        end
    end

    # Frontend Routes
    namespace :blog do
        resources :tutorials, only: [:index, :show]
        resources :commands, only: [:index, :show]
    end

    # API Routes
    namespace :api, :path => "", :constraints => {:subdomain => "tutorial_api"} do
        namespace :v1 do
            resources :posts, defaults: {format: "json"}
            resources :categories, defaults: {format: "json"}
        end
    end

    # Mount Routes
    mount PhcdevworksAccounts::Engine, :at => '/'
    mount PhcdevworksAccountsStripe::Engine, :at => '/'
    mount PhcdevworksCoreModules::Engine, :at => '/'

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
phcdevworks_tutorials-12.1.0 config/routes.rb
phcdevworks_tutorials-12.0.5 config/routes.rb
phcdevworks_tutorials-12.0.4 config/routes.rb