Datatable Filtercolumn is not reacting

2013-03-15 Thread Delange
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 TextFilteredPropertyColumnString,IModel(
new ModelString(header), sort, field) {

@Override public void populateItem(final 
ItemICellPopulatorlt;String
item, final String componentId,final IModelString rowModel)
{
Label label = new Label(componentId, 
createLabelModel(rowModel)){
public C IConverterC 
getConverter(ClassC 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) { 
 
TextFilterInteger filter = (TextFilterInteger)
super.getFilter(varComponentId, varForm); 
filter.getFilter().add(new AttributeModifier(size, new
ModelString(+inputsize)));
filter.getFilter().add(new AttributeModifier(style, new
ModelString(text-align:right;)));
filter.getFilter().add(new AttributeModifier(class, new
ModelString(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



Re: Datatable Filtercolumn is not reacting

2013-03-15 Thread Sven Meier

What does your FilterForm's model object look like?

Sven

On 03/15/2013 09:04 PM, Delange wrote:

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 TextFilteredPropertyColumnString,IModel(
new ModelString(header), sort, field) {

@Override public void populateItem(final 
ItemICellPopulatorlt;String
item, final String componentId,final IModelString rowModel)
{
Label label = new Label(componentId, 
createLabelModel(rowModel)){
public C IConverterC 
getConverter(ClassC 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) {

 TextFilterInteger filter = (TextFilterInteger)
super.getFilter(varComponentId, varForm);
 filter.getFilter().add(new AttributeModifier(size, new
ModelString(+inputsize)));
 filter.getFilter().add(new AttributeModifier(style, new
ModelString(text-align:right;)));
 filter.getFilter().add(new AttributeModifier(class, new
ModelString(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




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