Despite so many topics on this one I have not been able to figure it out for struts 2.
I have 5 drop down lists, and I want that a change in the selection of any one of these, should cause change in the contents of other drop downs without loading the complete page again, i.e asynchronously.
What I am currently trying is (using dojo) :
1.) When the selection of any of drop downs changes, the onChange event publishes a dojo topic.
2.) A topic listener causes an action to be executed.
Up to this point its fine. The action gets executed and sets the lists for the drop downs as expected.
Now what should happen is that :
--> When the action has completely executed it should come back to the same page (set in the struts config file) and update the lists of the drop downs with the new lists set in the action class.
I can not figure out how to do this.
Also if there is a better way of doing it please help me out with it, along with the codes please.
Here is the code of what I have done:
The jsp page containing the drop downs.
the struts config file:
The action class just sets the lists for the drop downs. I have checked that it works fine.