How to display different input type in one column
I have a column that needs to display either dropDownChoice or text.
dataViewPanel.html
<tr wicket:id="datatable">
<td>
</td>
<td>
<input type="text" wicket:id="value" />
</td>
</tr>
</table>
dataView.java
protected void populateItem(Item item)
{
Config gc = (Config) item.getModelObject();
item.setModel(new CompoundPropertyModel(gc));
item.add(new Label("name"));
item.add(new TextField("value"));
}
My question is: depends on value of "name", I like to render the "value" column as either dropDownChoice or text.
thanks,
richard