3

Java:

item.add(new AjaxLink("edit"){
   @Override
   public void onClick(AjaxRequestTarget target) {
      setResponsePage(new UnitPage(unit));
   }
 });

HTML:

<td><button wicket:id="edit">Edit</button></td>

This worked fine in 1.4 - clicking the button would take me to the new page with a "unit" object passed as parameter.

In 1.5 this is no longer working - it doesn't look like the onClick is firing.

Stijn Geukens
  • 15,454
  • 8
  • 66
  • 101
NeillR
  • 107
  • 7

1 Answers1

4

Setting the response page will cause a full page refresh so you could use a standard Link instead of AjaxLink.

That said, the wicket examples have such an example which seems to work.

bernardn
  • 1,701
  • 5
  • 19
  • 23