Hi.
For a long time I was working with render strategy set to
REDIRECT_TO_RENDER. Now I've switched to REDIRECT_TO_BUFFER and found
out, that removing items from ListViews no longer works.
I've code like
IModel customersModel = new LoadableDetachableModel() {
protected Object load() {
return CustomerDAO.getAllCustomers();
}
};
add (new ListView("customers", customersModel) {
protected void populateItem(ListItem item) {
Customer customer = (Customer) item.getModelObject();
...
item.add(new Link("delete") {
public void onClick() {
Customer customer = (Customer)
getParent().getModelObject();
CustomerDAO.delete(customer);
}
});
}
});
The problem is, that after deleting a cutomer, the list is not updated
until page refresh (the model doesn't get reloaded and list refreshed).
What's the recommended solution to this?
Thanks.
-Matej
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Wicket-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-user