12 lines
249 B
Ruby
12 lines
249 B
Ruby
class MoviesController < ApplicationController
|
|
def index
|
|
@choices, @movies = Movie.all, []
|
|
(0..10).each{ |num|
|
|
@movies.append(@choices.sample())
|
|
}
|
|
end
|
|
def show
|
|
@movie = Movie.find(params[:id])
|
|
end
|
|
end
|