add this in ur loop:
@todoitem.done = value
You forgot to save the value that you are changing.
One thing but, you might want to wrap that in a transaction, if one of
your loops fails, you'll end up in a strange database state.
Keep up to date with Rails on Twitter and This Week in Rails
Policies: Conduct, License, Maintenance, Security, Trademarks