What do you do if both people submit the form at the same time? Wouldn't lock_version do a better job?
On Fri, Nov 19, 2010 at 11:01, Eaden McKee <[email protected]> wrote: > What I do is when making an edit form, I have a hidden field - last > changed at - this is the last updated at field from rails. > > On edit submit, I load the last updated time of the object I'm saving. > If it has changed then I know someone has edited the object since. > Could use some ajax to poll for this change and warn the user before > they submit too. > > Eaden > > -- > You received this message because you are subscribed to the Google Groups > "Ruby or Rails Oceania" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/rails-oceania?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Ruby or Rails Oceania" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/rails-oceania?hl=en.
