When the user first visits the page I want all the checkboxes to be checked in my index page. Below is the code from my controller and index.html.haml
- by user1760920
I want the checkbox to be checked when the user visits the page for the first time.
-# This file is app/views/movies/index.html.haml
%h1 All Movies
= form_tag movies_path, :method => :get, :id => 'ratings_form' do
Include:
- @all_ratings.each do |rating|
= rating
= check_box_tag "ratings[#{rating}]", "1",…