Re: Passing parameters dynamically to jquery dialog

2012-01-26 Thread Russell John-Baptistr
Thanks for the direction...Got it working!! Cheers!

On Jan 26, 2012, at 4:03 AM, François Facon  wrote:

> And also
> 
> The handler of
> 
>class="report" t:zone="myZone" t:context="${host.hostid}">
>  
>  Delete ${host.hostid}
>  
> 
> something like
> 
> @OnEvent(value = EventConstants.ACTION)
> Object showDetail(int hostid)
> {
>if (!request.isXHR()) { return this; }
>host.hostid = hostid;
>return myZone;
> }
> 
> on server side you have to reassign the host id received in context
> into host.hostid
> in order to refresh the zone with the right id.
> 
> 
> 
> regards
> François
> 
> 
> 2012/1/26 Taha Hafeez Siddiqi :
>> Hi
>> 
>> If your dialog is in some kind of a loop you have to ensure t:clientId is 
>> unique for each dialog
>> 
>> something like
>> 
>> 
>>  ...
>> 
>> 
>> Link
>> 
>> and then in your java file
>> 
>> public String getDialogId(){
>>   return "myDialog" + loopIndex;
>> }
>> 
>> regards
>> Taha
>> 
>> On Jan 26, 2012, at 2:43 AM, Russell John-Baptistr wrote:
>> 
>>> trying to wrap my brain around how I should pass IDs from my
>>> jquery.dialogajaxlink to my jquery.dialog.
>>> 
>>> I am using query builder to build a list of hosts. I can display the id and 
>>> other host information of each host, per row.
>>> However whenever the delete dialog box is called via clicking "delete"
>>> on a row, only the first ID and the first hostname in the list gets
>>> passed to the dialog. This happens regardless of which row's delete
>>> link is clicked.
>>> 
>>> I feel there is something simple I'm missing. Thanks in advance for any 
>>> input!
>>> 
>>> 
>>> 
>>> 
>>>   
>>> 
>>>   
>>>   
>>>
>>>   >> context="${host.hostId}" t:mixins="jquery/button">
>>>Delete Host ${host.hostid}
>>>   
>>>
>>>   
>>>   
>>> 
>>>  >> class="report" t:zone="myZone" t:context="${host.hostid}">
>>>   
>>>   Delete ${host.hostid}
>>>   
>>>   
>>> 
>>>   
>>> 
>>> 
>>> 
>>> -
>>> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
>>> For additional commands, e-mail: users-h...@tapestry.apache.org
>>> 
>> 
>> 
>> -
>> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
>> For additional commands, e-mail: users-h...@tapestry.apache.org
>> 
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
> 

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Passing parameters dynamically to jquery dialog

2012-01-26 Thread François Facon
And also

The handler of

   
  
  Delete ${host.hostid}
  

something like

@OnEvent(value = EventConstants.ACTION)
Object showDetail(int hostid)
{
if (!request.isXHR()) { return this; }
host.hostid = hostid;
return myZone;
}

on server side you have to reassign the host id received in context
into host.hostid
in order to refresh the zone with the right id.



regards
François


2012/1/26 Taha Hafeez Siddiqi :
> Hi
>
> If your dialog is in some kind of a loop you have to ensure t:clientId is 
> unique for each dialog
>
> something like
>
> 
>  ...
> 
>
> Link
>
> and then in your java file
>
> public String getDialogId(){
>   return "myDialog" + loopIndex;
> }
>
> regards
> Taha
>
> On Jan 26, 2012, at 2:43 AM, Russell John-Baptistr wrote:
>
>> trying to wrap my brain around how I should pass IDs from my
>> jquery.dialogajaxlink to my jquery.dialog.
>>
>> I am using query builder to build a list of hosts. I can display the id and 
>> other host information of each host, per row.
>> However whenever the delete dialog box is called via clicking "delete"
>> on a row, only the first ID and the first hostname in the list gets
>> passed to the dialog. This happens regardless of which row's delete
>> link is clicked.
>>
>> I feel there is something simple I'm missing. Thanks in advance for any 
>> input!
>>
>>
>>     
>>
>>               
>>
>>                   
>>                       
>>                            
>>                       > context="${host.hostId}" t:mixins="jquery/button">
>>                            Delete Host     ${host.hostid}
>>                       
>>                            
>>                   
>>               
>>
>>              > class="report" t:zone="myZone" t:context="${host.hostid}">
>>                   
>>                   Delete ${host.hostid}
>>               
>>               
>>
>>           
>>
>>
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
>> For additional commands, e-mail: users-h...@tapestry.apache.org
>>
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Passing parameters dynamically to jquery dialog

2012-01-25 Thread Taha Hafeez Siddiqi
Hi

If your dialog is in some kind of a loop you have to ensure t:clientId is 
unique for each dialog

something like


 ...


Link

and then in your java file

public String getDialogId(){
   return "myDialog" + loopIndex;
}

regards
Taha

On Jan 26, 2012, at 2:43 AM, Russell John-Baptistr wrote:

> trying to wrap my brain around how I should pass IDs from my
> jquery.dialogajaxlink to my jquery.dialog.
> 
> I am using query builder to build a list of hosts. I can display the id and 
> other host information of each host, per row.
> However whenever the delete dialog box is called via clicking "delete"
> on a row, only the first ID and the first hostname in the list gets
> passed to the dialog. This happens regardless of which row's delete
> link is clicked.
> 
> I feel there is something simple I'm missing. Thanks in advance for any input!
> 
> 
> 
> 
>   
> 
>   
>   
>
>context="${host.hostId}" t:mixins="jquery/button">
>Delete Host ${host.hostid}
>   
>
>   
>   
> 
>   class="report" t:zone="myZone" t:context="${host.hostid}">
>   
>   Delete ${host.hostid}
>   
>   
> 
>   
> 
> 
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
> 


-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Passing parameters dynamically to jquery dialog

2012-01-25 Thread François Facon
Hi

Did you check the code related to http://tapestry5-jquery.com/core/docsgrid?


2012/1/25 Russell John-Baptistr :
> trying to wrap my brain around how I should pass IDs from my
> jquery.dialogajaxlink to my jquery.dialog.
>
> I am using query builder to build a list of hosts. I can display the id and 
> other host information of each host, per row.
> However whenever the delete dialog box is called via clicking "delete"
> on a row, only the first ID and the first hostname in the list gets
> passed to the dialog. This happens regardless of which row's delete
> link is clicked.
>
> I feel there is something simple I'm missing. Thanks in advance for any input!
>
>
>     
>
>               
>
>                   
>                       
>                            
>                        context="${host.hostId}" t:mixins="jquery/button">
>                            Delete Host     ${host.hostid}
>                       
>                            
>                   
>               
>
>               class="report" t:zone="myZone" t:context="${host.hostid}">
>                   
>                   Delete ${host.hostid}
>               
>               
>
>           
>
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org