Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # parameters that are being sent:
- Processing by ExamTemplatesController#create as HTML
- Parameters: {"commit"=>"Create Exam Template", "authenticity_token"=>"XGTV17fAkOxLt4Z8Of4BNXBbh3iAILxhMJFKTL1yVBw=", "utf8"=>"\342\234\223", "exam_sheet_template"=>{"category_id"=>"2"}, "exam_template"=>{"name"=>"test", "exam_sheet_template_attributes"=>{"0"=>{"amount"=>"2", "_destroy"=>"0"}, "1"=>{"amount"=>"2", "_destroy"=>"0"}, "2"=>{"amount"=>"2", "_destroy"=>"0"}}}}
- # as you can see, "exam_sheet_template"=>{"category_id"=>"2"}" is set only once, outside the exam_sheet_template attributes section, where i expect it.
- <p>
- <%= collection_select(:exam_sheet_template, :category_id, Category.all, "id", "category_name") %>
- <%= f.text_field :amount, :size => 2 %>
- <%= f.check_box :_destroy %>
- <%= f.label :_destroy, "Remove Exam Sheet" %><br/>
- </p>
Add Comment
Please, Sign In to add comment