I didn't quite understand what you meant.

 However, this whole approach is having numerous problems, though I
did get an rjs focus to work. I'm not sure if it's because there is a
table inside the form, but the basic thing is I want to change form
fields using ajax. If you have a some text fields and some selects
like say:

 <%= select_tag :data_format, options_for_select
(['t1','b1','ascii'],@fmt) %>

 <%= select_tag 'transaction[level]', options_for_select
(['','level-1','level-2'], level)

 If you select ascii, I want to dynamically change the transaction
[level] select to be a different set of selections through an
observer. and then add a checkbox:

<%= check_box_tag 'transaction[EOG]', eog, checked %>

It doesn't seem to work that I can update part of a form when there is
a table involved.

If I try to re render the whole form, the current problem is that I
send the data back from the form_observer, but say a user types in an
input field and he types 'abc'. The observer calls the server and
sends 'abc', but after that he types 'xyz'. The server in this
strategy will re render the form, and that field will go back to 'abc'
erasing part of the users input.

 When I have tried to just use field observers and save all the fields
in session variables, if I have a button that looks like a submit
button, what sometimes happens is the user can rapidly type something
and hit the submit button and submit will fire before the observer and
it won't submit all of the data.

 The page I'm having the problem with seemed like it was working ok
along time ago until someone may have changed it, they may have added
a table. I'm not sure, but it may be the table that is giving me the
trouble.





On Sep 25, 2:46 pm, Hassan Schroeder <hassan.schroe...@gmail.com>
wrote:
> On Fri, Sep 25, 2009 at 9:29 AM, Jedrin <jrubia...@gmail.com> wrote:
> > I don't suppose there is any easy way to tell what the focus was when
> > observe_form sends the call to the server ?
>
> Uh, the suggestion in my previous message?  :-)
>
> --
> Hassan Schroeder ------------------------ hassan.schroe...@gmail.com
> twitter: @hassan
--~--~---------~--~----~------------~-------~--~----~
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