com.inmethod.grid.column.PageLinkColumn Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of wicketstuff-inmethod-grid Show documentation
Show all versions of wicketstuff-inmethod-grid Show documentation
Advanced grid components for Apache Wicket
The newest version!
package com.inmethod.grid.column;
import org.apache.wicket.PageReference;
import org.apache.wicket.model.IModel;
import org.apache.wicket.request.cycle.RequestCycle;
/**
* Displays a Link in the DataGrid to an Internal Wicket Page
* @author Tom Burton
*/
public class PageLinkColumn extends LinkColumn
{
private PageReference pageRef;
public PageLinkColumn(String columnId, String propertyLabel, IModel headerModel, PageReference page)
{
super(columnId, propertyLabel, headerModel);
this.pageRef = page;
}
public PageLinkColumn(String columnId, String propertyLabel, IModel headerModel, S sortProperty, PageReference page)
{
super(columnId, propertyLabel, headerModel, sortProperty);
this.pageRef = page;
}
@Override
public void onClick(IModel rowModel)
{
RequestCycle.get().setResponsePage(pageRef.getPage());
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy