change rooms#index to rooms#show

This commit is contained in:
Josh 2018-05-23 16:13:24 -04:00
parent 434021239c
commit 3dd7b33363
3 changed files with 6 additions and 15 deletions

View File

@ -4,7 +4,7 @@ class RoomsController < ApplicationController
skip_before_action :verify_room_ownership, only: [:show, :join, :wait]
# GET /r/:room_uid
def index
def show
opts = default_meeting_options
if @meeting.is_running?
@ -63,7 +63,7 @@ class RoomsController < ApplicationController
end
end
# GET /r/:room_uid/wait
# GET/POST /r/:room_uid/wait
def wait
if @meeting.is_running?
if current_user
@ -84,6 +84,7 @@ class RoomsController < ApplicationController
# GET /r/:room_uid/sessions
def sessions
end
private

View File

@ -3,10 +3,10 @@ Rails.application.routes.draw do
# Room routes.
scope '/r/:room_uid' do
get '/', to: 'rooms#show', as: :room
match '/start', to: 'rooms#start', as: :start_room, via: [:get, :post]
match '/join', to: 'rooms#join', as: :join_room, via: [:get, :post]
get '/start', to: 'rooms#start', as: :start_room
get '/join', to: 'rooms#join', as: :join_room
match '/wait', to: 'rooms#wait', as: :wait_room, via: [:get, :post]
match '/logout', to: 'rooms#logout', as: :logout_room, via: [:get, :post]
get '/logout', to: 'rooms#logout', as: :logout_room
get '/sessions', to: 'rooms#sessions', as: :sessions
end

View File

@ -5,13 +5,3 @@
#
# movies = Movie.create([{ name: 'Star Wars' }, { name: 'Lord of the Rings' }])
# Character.create(name: 'Luke', movie: movies.first)
User.create(
provider: "greenlight",
name: "Test User",
uid: "someuid",
username: "testuser",
email: "test@user.com",
password: "password",
password_confirmation: "password",
)