Re: WicketExtensions DataTable : Creating a Links using Model value?
A somewhat similar question was asked just a couple of days ago [1] and, probably, has been asked and answered many times before on this list. Ernesto References [1] http://old.nabble.com/How-to-get-a-cell-work-as-a-link-in-AjaxFallbackDefaultDataTable-td27161378.html On Mon, Jan 18, 2010 at 7:24 AM, Ashika Umanga Umagiliya auma...@biggjapan.com wrote: Greetings, I was going through WicketExtensions DataTable source and I was wondering how to create a hyperlink using PropertyColumn. In docs it says: columns[0] = new PropertyColumn(new Model(Family Id), familyId); What I want to do is, 1) create a Link using the field value familyId,and directing to another page which display SubFamilies related to selected 'familyId' 2) create a Link which direct to another website . eg: http://www.ncbi.org/family?id=$familyid My domain model is as: One 'Family' has many 'SubFamily' objects. ||
WicketExtensions DataTable : Creating a Links using Model value?
Greetings, I was going through WicketExtensions DataTable source and I was wondering how to create a hyperlink using PropertyColumn. In docs it says: columns[0] = new PropertyColumn(new Model(Family Id), familyId); What I want to do is, 1) create a Link using the field value familyId,and directing to another page which display SubFamilies related to selected 'familyId' 2) create a Link which direct to another website . eg: http://www.ncbi.org/family?id=$familyid My domain model is as: One 'Family' has many 'SubFamily' objects. ||
Re: WicketExtensions DataTable : Creating a Links using Model value?
You can either override PropertyColumn's populateItem method, and add to the cell the link you want. Or you can use AbstractColumn. Eyal Golan egola...@gmail.com Visit: http://jvdrums.sourceforge.net/ LinkedIn: http://www.linkedin.com/in/egolan74 P Save a tree. Please don't print this e-mail unless it's really necessary On Mon, Jan 18, 2010 at 8:24 AM, Ashika Umanga Umagiliya auma...@biggjapan.com wrote: Greetings, I was going through WicketExtensions DataTable source and I was wondering how to create a hyperlink using PropertyColumn. In docs it says: columns[0] = new PropertyColumn(new Model(Family Id), familyId); What I want to do is, 1) create a Link using the field value familyId,and directing to another page which display SubFamilies related to selected 'familyId' 2) create a Link which direct to another website . eg: http://www.ncbi.org/family?id=$familyid My domain model is as: One 'Family' has many 'SubFamily' objects. ||