1
0
Fork 0
dokkan-data-rails/config/routes.rb

40 lines
1 KiB
Ruby

Rails.application.routes.draw do
get 'auth/:provider/callback', to: 'sessions#create'
get 'auth/failure', to: 'sessions#failure'
delete 'logout', to: 'sessions#destroy', as: 'logout'
get '/welcome', to: 'welcome#index'
root to: 'welcome#index'
namespace :admin do
root to: 'dashboard#index'
get '/dashboard', to: 'dashboard#index'
post '/versions/revert', to: 'versions#revert', as: 'revert_version'
resources :awaken_types
resources :cards
resources :characters
resources :evidences, except: [:show, :edit, :update]
resources :leader_skills
resources :links
resources :passive_skills
resources :rarities
resources :stat_types
resources :super_attacks
resources :types
resources :users, except: [:new, :create]
resources :versions, only: [:show]
end
constraints subdomain: /^api(\.|$)/ do
namespace :api, path: nil do
namespace :v1 do
resources :cards, only: [:index, :show]
resources :links, only: [:index, :show]
end
end
end
end