Hi All,
I am using acts_as_list to sort photographs within photo albums.
So I have two models:
Photograph (belongs_to :photo_album)
PhotoAlbum (has_many :photographs)
Everything works great, until I update the properties of a photograph by
linking it to a different album. acts_as_list is not recognizing that
the parent_id of my photograph has changed, thus the position field in
my photographs table is not being updated properly.
What is the proper way to update the parent/child records when a child
is being linked to a different parent?
Thanks in advance for your help.
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---