Forum: Ruby on Rails update_attributes! does not update nested model

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
D69427b79304a88db972c5ba75b70e53?d=identicon&s=25 darkofabijan (Guest)
on 2009-02-03 15:53
(Received via mailing list)
Hi!

I have updated my app to rails 2.3. I have form that has few nested
models and I am happy that I can just write
accepts_nested_attributes_for :tasks, :allow_destroy => true, but
update_attributes! does not update my nested model. I have tried
update_attributes, and it works. Any ideas?

Few lines from log:

update_attributes:

 SQL (0.1ms)   BEGIN
  Education Update (0.3ms)   UPDATE `educations` SET `institution` =
'ins', `updated_at` = '2009-02-03 13:34:08' WHERE `id` = 4
  SQL (0.4ms)   COMMIT

update_attributes!:
  SQL (0.1ms)   BEGIN
  SQL (0.1ms)   COMMIT
424a9ce662b059c35063b405e160461d?d=identicon&s=25 Eloy Duran (el-oy)
on 2009-02-05 10:33
(Received via mailing list)
Hi,

I have uploaded a patch to fix this. Thanks for bringing it to my
attention.
http://rails.lighthouseapp.com/projects/8994/tickets/1877

Cheers,
Eloy
This topic is locked and can not be replied to.