You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by 丁振波 <ze...@gmail.com> on 2009/03/04 08:34:04 UTC
component parameter binding question
Hello guys, below is my case code:
<t:parameter name="nameCell">
<t:pagelink page="edit" context="user.id">${user.name}</t:pagelink>
</t:parameter>
my question is, how can I pass mutil param value in context , is there any
format like "user.id; user.name"?
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: component parameter binding question
Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
On Wed, Mar 4, 2009 at 5:15 AM, dhning <ni...@gmail.com> wrote:
> 1. Do in java
> public Object [] getContextValue() {
> return new Object[2]{user.id, user.name};
> }
You can also return a List.
--
Thiago
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: component parameter binding question
Posted by 丁振波 <ze...@gmail.com>.
Got it! thanks!
----- Original Message -----
From: "dhning" <ni...@gmail.com>
To: "Tapestry users" <us...@tapestry.apache.org>
Sent: Wednesday, March 04, 2009 5:28 PM
Subject: Re: component parameter binding question
> welcome:)
>
> Like <t:actionlink t:id="delete"
> context="contextValue">Delete</t:actionlink>
> Since context is prop binding, it will map getContextValue() method in
> java.
>
> Thanks,
>
> DH
>
>
> ----- Original Message -----
> From: "丁振波" <ze...@gmail.com>
> To: "Tapestry users" <us...@tapestry.apache.org>
> Sent: Wednesday, March 04, 2009 5:23 PM
> Subject: Re: component parameter binding question
>
>
>> Thanks for your reply :)
>>
>> I used 5.0.18 release version. What param should set in tml's context
>> field
>> when I use the way do in java?
>>
>> <t:parameter name="delete">
>> <t:actionlink t:id="delete" context="???">Delete</t:actionlink>
>> </t:parameter>
>>
>>
>>
>> ----- Original Message -----
>> From: "dhning" <ni...@gmail.com>
>> To: "Tapestry users" <us...@tapestry.apache.org>
>> Sent: Wednesday, March 04, 2009 4:15 PM
>> Subject: Re: component parameter binding question
>>
>>
>>> Are you using latest t5 snapshot or 5.0.X.X release?
>>>
>>> If latest snapshot, just use like context="[user.id,user.name]"
>>> If not, there are 2 ways:
>>> 1. Do in java
>>> public Object [] getContextValue() {
>>> return new Object[2]{user.id, user.name};
>>> }
>>> 2. Use list binding in t5commons library
>>> http://code.google.com/p/tapestry5-components/
>>>
>>> Thanks
>>>
>>> DH
>>>
>>>
>>> ----- Original Message -----
>>> From: "丁振波" <ze...@gmail.com>
>>> To: "Tapestry users" <us...@tapestry.apache.org>
>>> Sent: Wednesday, March 04, 2009 3:34 PM
>>> Subject: component parameter binding question
>>>
>>>
>>>> Hello guys, below is my case code:
>>>>
>>>> <t:parameter name="nameCell">
>>>> <t:pagelink page="edit" context="user.id">${user.name}</t:pagelink>
>>>> </t:parameter>
>>>>
>>>> my question is, how can I pass mutil param value in context , is there
>>>> any
>>>> format like "user.id; user.name"?
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>>
>>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: component parameter binding question
Posted by dhning <ni...@gmail.com>.
welcome:)
Like <t:actionlink t:id="delete" context="contextValue">Delete</t:actionlink>
Since context is prop binding, it will map getContextValue() method in java.
Thanks,
DH
----- Original Message -----
From: "丁振波" <ze...@gmail.com>
To: "Tapestry users" <us...@tapestry.apache.org>
Sent: Wednesday, March 04, 2009 5:23 PM
Subject: Re: component parameter binding question
> Thanks for your reply :)
>
> I used 5.0.18 release version. What param should set in tml's context field
> when I use the way do in java?
>
> <t:parameter name="delete">
> <t:actionlink t:id="delete" context="???">Delete</t:actionlink>
> </t:parameter>
>
>
>
> ----- Original Message -----
> From: "dhning" <ni...@gmail.com>
> To: "Tapestry users" <us...@tapestry.apache.org>
> Sent: Wednesday, March 04, 2009 4:15 PM
> Subject: Re: component parameter binding question
>
>
>> Are you using latest t5 snapshot or 5.0.X.X release?
>>
>> If latest snapshot, just use like context="[user.id,user.name]"
>> If not, there are 2 ways:
>> 1. Do in java
>> public Object [] getContextValue() {
>> return new Object[2]{user.id, user.name};
>> }
>> 2. Use list binding in t5commons library
>> http://code.google.com/p/tapestry5-components/
>>
>> Thanks
>>
>> DH
>>
>>
>> ----- Original Message -----
>> From: "丁振波" <ze...@gmail.com>
>> To: "Tapestry users" <us...@tapestry.apache.org>
>> Sent: Wednesday, March 04, 2009 3:34 PM
>> Subject: component parameter binding question
>>
>>
>>> Hello guys, below is my case code:
>>>
>>> <t:parameter name="nameCell">
>>> <t:pagelink page="edit" context="user.id">${user.name}</t:pagelink>
>>> </t:parameter>
>>>
>>> my question is, how can I pass mutil param value in context , is there
>>> any
>>> format like "user.id; user.name"?
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>
>>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>
Re: component parameter binding question
Posted by 丁振波 <ze...@gmail.com>.
Thanks for your reply :)
I used 5.0.18 release version. What param should set in tml's context field
when I use the way do in java?
<t:parameter name="delete">
<t:actionlink t:id="delete" context="???">Delete</t:actionlink>
</t:parameter>
----- Original Message -----
From: "dhning" <ni...@gmail.com>
To: "Tapestry users" <us...@tapestry.apache.org>
Sent: Wednesday, March 04, 2009 4:15 PM
Subject: Re: component parameter binding question
> Are you using latest t5 snapshot or 5.0.X.X release?
>
> If latest snapshot, just use like context="[user.id,user.name]"
> If not, there are 2 ways:
> 1. Do in java
> public Object [] getContextValue() {
> return new Object[2]{user.id, user.name};
> }
> 2. Use list binding in t5commons library
> http://code.google.com/p/tapestry5-components/
>
> Thanks
>
> DH
>
>
> ----- Original Message -----
> From: "丁振波" <ze...@gmail.com>
> To: "Tapestry users" <us...@tapestry.apache.org>
> Sent: Wednesday, March 04, 2009 3:34 PM
> Subject: component parameter binding question
>
>
>> Hello guys, below is my case code:
>>
>> <t:parameter name="nameCell">
>> <t:pagelink page="edit" context="user.id">${user.name}</t:pagelink>
>> </t:parameter>
>>
>> my question is, how can I pass mutil param value in context , is there
>> any
>> format like "user.id; user.name"?
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: component parameter binding question
Posted by dhning <ni...@gmail.com>.
Are you using latest t5 snapshot or 5.0.X.X release?
If latest snapshot, just use like context="[user.id,user.name]"
If not, there are 2 ways:
1. Do in java
public Object [] getContextValue() {
return new Object[2]{user.id, user.name};
}
2. Use list binding in t5commons library http://code.google.com/p/tapestry5-components/
Thanks
DH
----- Original Message -----
From: "丁振波" <ze...@gmail.com>
To: "Tapestry users" <us...@tapestry.apache.org>
Sent: Wednesday, March 04, 2009 3:34 PM
Subject: component parameter binding question
> Hello guys, below is my case code:
>
> <t:parameter name="nameCell">
> <t:pagelink page="edit" context="user.id">${user.name}</t:pagelink>
> </t:parameter>
>
> my question is, how can I pass mutil param value in context , is there any
> format like "user.id; user.name"?
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>