No description, website, or topics provided.
Ruby CoffeeScript JavaScript
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.idea
app
config
db
doc
lib
log
public
script
test
vendor
.gitignore
Gemfile
Gemfile.lock
README
Rakefile
config.ru

README

Rails 3.1 _ids Bug

When adding an association using `_ids = [association_ids]` for a has_many through relationship, ActiveRecord throws a
RecordInvalid error if one of the association_id records does not validate.  When used with a nested form, the update action
will not render the edit action when `object.update_attributes` fails.

Setup:
1. Install the bundled gems and rake the database
2. Run `Classroom.setup_data` in the console to add the default data

Reproduce In Console:
1. Run `Classroom.add_invalid_teacher_to_classroom`

Reproduce In Browser:
1. Navigate to `/classrooms/1/edit`
2. Check the Teachers box for ` Teacher ids 2`
3. Click `Update Classroom`

Simple Form is used as a convenience to create the check box fields.