use of com.revolsys.ui.html.fields.TextAreaField in project com.revolsys.open by revolsys.
the class FilterableTableView method initialize.
@Override
public void initialize(final HttpServletRequest request) {
if (this.searchFields != null) {
final ElementContainer searchContainer = new ElementContainer(new TableBodyLayout("search", this.model.getColumnCount()));
add(searchContainer);
for (final KeySerializer serializer : this.model.getSerializers()) {
final String name = serializer.getName();
Element element = this.searchFields.get(name);
if (element == null) {
element = NbspElement.INSTANCE;
} else {
element = element.clone();
if (element instanceof Field) {
final Field field = (Field) element;
field.setRequired(false);
}
if (element instanceof TextField) {
final TextField textField = (TextField) element;
textField.setSize(1);
}
if (element instanceof TextAreaField) {
final TextAreaField textField = (TextAreaField) element;
textField.setRows(1);
textField.setCols(1);
}
}
searchContainer.add(element);
}
}
super.initialize(request);
}
Aggregations