I'm trying to modify an attribute on the HTML element that goes with my
DataView:

HTML
<div wicket:id="dataview" id="dynamic">
   <span wicket:id="myLabel" />
</div>

JAVA
new DataView<POJO>("dataview", dataProvider) {
   protected void populateItem(Item<POJO> item) {
      item.add(new Label("myLabel", item.getModelObject().getValue()));
   }
   protected void onComponentTag(ComponentTag tag) {
      super.onComponentTag(tag);
      tag.put("id", "dynamicValue");
   }
}

I thought this would do it, but I never even hit DataView.onComponentTag().
Any other suggestions?

-Matt

Reply via email to