Following code works fine on jettty 6.1.22 but not on tomcat 6.0.24 with
Liferay 5.2
To be specific, the following line always returns string "optionB" although
other option is selected.
String selectedOption = searchChoice.getModelObject(); 

Can anybody please point out reason for this behaviour? related code snippet
from wicket Page is given below:
-------------------------------------------------------------------------
final RadioChoice<String> searchChoice = new
RadioChoice<String>("searchChoice", new Model<String>("optionA"),
searchOptions);

searchChoice.add(new AjaxFormChoiceComponentUpdatingBehavior() {

                        @Override
                        protected void onUpdate(AjaxRequestTarget target) {
                                String selectedOption = 
searchChoice.getModelObject(); //***
                                if(selectedOption .equals("optionA")){
                                        // doSomething                          
        
                                }else if(selectedSearch.equals("optionB")){
                                        // doSomethingElse
                                }                                               
        
                        }                       
                });

-------------------------------------------------------------------------
Thank you.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/RadioChoice-model-not-updated-in-tomcat-with-liferay-portal-tp3565419p3565419.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to