-
Notifications
You must be signed in to change notification settings - Fork 9
/
routes.rb
28 lines (23 loc) · 965 Bytes
/
routes.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
Rails.application.routes.draw do
root to: "welcome#home"
defaults export: true do
get "/hi" => redirect("/welcome")
end
resources :welcome
resources :video_clips, only: [:new, :edit, :create, :update, :destroy], export: true do
get :download, on: :member
patch :add_to_playlist, on: :member
patch :remove_from_playlist, on: :member
get :latest, on: :collection
get "/thumbnail/:thumbnail_id", as: :thumbnail, action: :thumbnail, on: :member
resources :comments, only: [:show, :index], shallow: true
end
namespace :settings, path: "/" do
resources :user_preferences, only: [], export: true do
patch :switch_to_classic_navbar, on: :collection
get :switch_to_beta_navbar, on: :collection, export: false
get "/switch_to_classic/:page", action: :switch_to_classic, on: :collection
get "/switch_to_beta/:page", action: :switch_to_beta, on: :collection, as: :switch_to_beta_page
end
end
end