Hi,

I want to make a filter to update a table according to selected user.
I am filling a hashmap to retrieve some data from database. To accomplish
that
I overrided "wantOnSelectionChangedNotifications" method. But the problem
is;
when I choose the user1, the model value is updated as it is exptected and
hashmap
is updated. But after that I am choosing user2 but neither the model value
nor hashMap is not updated
and the selectbox is still showing user1..

I put a a breakpoint into propertyModel constructer but it didnt stop there
in debug mode.
Any idea?

Thanks
        
        private HashMap<String, String> criteriaMap= new HashMap<String, 
String>();
        Criteria criteria = new Criteria();
        
        List userFilter=new ArrayList();
    userFilter.add("user1");
    userFilter.add("user2");

        add(new DropDownChoice("selectByUser", new PropertyModel(criteria,
"userCriteria"),userFilter) {
        @Override
                protected boolean wantOnSelectionChangedNotifications() {
                        criteriaMap.put("user",criteria.getUserCriteria());
                        return true;
                }
        });
        
        
        public class Criteria implements Serializable{
        
        private String userCriteria;
        
        public String getUserCriteria() {
                return userCriteria;
        }
        public void setUserCriteria(String userCriteria) {
                this.userCriteria = userCriteria;
        }

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/DropDownChoice-model-is-not-updated-when-wantOnSelectionChangedNotifications-is-overriden-tp4031368p4031368.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to