Im not sure using :dependent => delete_all is correct here but I want
to delete all the ApptEdits when an Appointment is updated in a
certain situation.  so i have:

@appt_to_edit.update_attributes(appointment_info)

and then i want to do something like:

@appt_to_edit.appt_edits.destroy

but this does not work.  i was thinking about something like
using :dependent => :delete_all, but i only want to do this after a
specific update_attributes call and not every one so i dont think this
is appropriate.  what is the best way to write the equivalent to the
pseudocode: @appt_to_edit.appt_edits.destroy?




--~--~---------~--~----~------------~-------~--~----~
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@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to