You can, as well, create a column Decorator[1] putting more parameters there:
<quote>
column.setDecorator(new Decorator() {
public String render(Object row, Context context) {
Customer customer = (Customer) row;
String id = String.valueOf(customer.getPerson().getId());
editLink.setParameter("id", id);
deleteLink.setValue(id);
return editLink.toString() + " | "
+ deleteLink.toString();
}
});
table.addColumn(column);
</quote>
Hth,
Gilberto
[1]
http://click.apache.org/docs/click-api/org/apache/click/control/Decorator.html
On Sun, Mar 11, 2012 at 8:04 PM, Malcolm Edgar <[email protected]> wrote:
> Is this a DataGrid type problem where the user is making a selection?
>
> http://click.avoka.com/click-examples/table/form-table.htm
>
> regards
>
>
> On Sun, Mar 11, 2012 at 11:22 PM, Alexander Untch <[email protected]> wrote:
>>
>> Hello everybody,
>>
>> I created a click page with a table. The table has 5 columns and x rows.
>> The table is filled by using table.setRowList(resultList);
>>
>> Up to this point everything works fine.
>> But now I need some help. On the rendered page with the table I need
>> to pick values from the table and pass them to another service (for
>> example by selecting them in the table and pressing a submit button).
>>
>> The table looks like this:
>> col1 col2 col2 col4 col5
>> -----------------------------------
>> val1 val2 val3 val4 val5
>> val6 val7 val8 val9 val10
>>
>> I need to select val4 and val9 (same column but different rows) and pass
>> them.
>>
>> At the moment I don't know how to achieve this. Has anybody a great
>> and simple idea?
>>
>> Thanks a lot!
>> Alex
>
>