app/controllers/reviews_controller.rb
#ajax handler to make a review
ajax handler to make a review
ajax handler to make a review
def show
    @labels = ["Writing","Acting","Directing","Special Effects","Score","Artistic"]
    @review = Review.find(params[:id])
    @total = @review.ratings.split(',').map{|x| x.to_i}.reduce(:+)
  end
def show @labels = [ "Writing" , "Acting" , "Directing" , "Special Effects" , "Score" , "Artistic" ] @review = Review . find ( params [ :id ] ) @total = @review . ratings . split ( ',' ) . map { | x | x . to_i } . reduce ( :+ ) end
ajax handler to make a review
ajax handler to make a review