Question:
Can a child window manipulate its parent window with RJS?
Example:
In an application a parent/master window shows a list of records. When
the users press ‘edit’, a greybox windows pops up where they can update
one item attributes.
Problem: after the ‘save’ and child window closing, the parent window
still contains the old attributes values.
I know how to trigger plain javascript execution in the parent, to clean
the parent window f.ex, but RJS is really what I need.
Question:
Can a child window manipulate its parent window with RJS?
As a workaround, I have the children execute some javascript code
that in turn has the parent execute some javascript code where I
inserted an Ajax call to a controller action that refreshes the parent
contents.
=> when the user submit the action in the child/greybox window, it
calls an action :
file:contact_controller.rb
def update
…
render :partial =>
‘hide_greybox_and_refresh_details_in_parent’
…
end