I use a datatable with FilterColumn. I specially made a IntegerColumn. It
works fine, but if the user enters a blank or nothing the table is not
refreshed. I can see that the old value is used.
If a enter a zero or another integer value it works like i expected.
How can I repair this problem

My source is
        @SuppressWarnings({ "unchecked", "rawtypes", "serial" })
        public TextFilteredPropertyColumn getInteger(String header,String
sort,final String field,final int inputsize,final boolean formatOutput,final
String format) {
                return new TextFilteredPropertyColumn<String,IModel>(
                                new Model<String>(header), sort, field) {
                        
                        @Override public void populateItem(final 
Item<ICellPopulator&lt;String>>
item, final String componentId,final IModel<String> rowModel)
                                {
                                    Label label = new Label(componentId, 
createLabelModel(rowModel)){
                                        public <C> IConverter<C> 
getConverter(Class<C> type){
                                                IConverter converter = new
MyIntegerConverter(formatOutput,format);
                                                return converter;
                                        }       
                                    };
                                        item.add(label); 
                                }
 
                        @Override
                        public String getCssClass() {  
                                return "numeric "+field; 
                        };              
                        @Override 
            public Component getFilter(final String varComponentId, final
FilterForm varForm) { 
                         
                TextFilter<Integer> filter = (TextFilter<Integer>)
super.getFilter(varComponentId, varForm); 
                filter.getFilter().add(new AttributeModifier("size", new
Model<String>(""+inputsize)));
                filter.getFilter().add(new AttributeModifier("style", new
Model<String>("text-align:right;")));
                filter.getFilter().add(new AttributeModifier("class", new
Model<String>("numeric")));
                
                return filter; 
            } 
                };        
        }       



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Datatable-Filtercolumn-is-not-reacting-tp4657285.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