Tap 5.3 : AjaxResponseRenderer error when updating two zones with chaining

2011-12-10 Thread Shing Hing Man
I am using the mixin zoneRefresh  and AjaxResponseRenderer to update zone  
pricesZone and zone currentTimeZone. 

( I have read the excellent blog by Taha on  AjaxResponseRenderer.)

But I get the following error.


 Ajax failure: Status 200 for 
http://localhost:8080/tapestry5Demo/test/core/mixin/stockwatcher2.priceszone:zonerefresh:
 undefined
Communication with the server failed: undefined


t:zone  t:id=pricesZone  id=pricesZone  t:update=show 
t:mixins=ZoneRefresh t:period='3' 
table  class=watchList cellpadding=6
.. tr class=watchListHeader
td class=watchListHeaderSymbol/td 
td   Price/td 
td  class=watchListNumericColumnChange/td
td class=watchListRemoveColumnRemove/td 
/tr

tr t:type=loop source=stockPrices  t:id=stockPrices value=stockPrice
td ${stockPrice.symbol} /td
td class=watchListNumericColumn t:output value=stockPrice.price 
format=priceFormatter/t:output /td
td style=${changeStyle} class=watchListNumericColumn 
t:output value=stockPrice.change format=changeFormatter/
(t:output value=stockPrice.changePercent format=changeFormatter/%)
/td
td class=watchListRemoveColumn
t:actionlink  t:id=remove context=stockPrice.symbol t:zone=pricesZone 
class=gwt-Button gwt-Button-remove  x /t:actionlink
/td
/tr 
/table 
/t:zone

t:zone t:id=currentTimeZone t:update=show id=currentTimeZone
Last update : ${currentTime}
/t:zone


In java class : 
@InjectComponent
private Zone pricesZone;


protected void onRefreshFromPricesZone() {
refreshWatchList();
if (request.isXHR()) {
// This does not work 
ajaxResponseRenderer.addRender(currentTimeZone).addRender(pricesZone); 
}

}

Is it meant to be an error ? Any explanation on why the above does not work 
would be appreciated !


However,  the following works. 

protected Object onRefreshFromPricesZone() {
refreshWatchList();
if (request.isXHR()) {
ajaxResponseRenderer.addRender(currentTimeZone);
return pricesZone.getBody();

}

return null;
}


If the table, in zone pricesZone,  is wrapped in a block, then the following 
also works.

protected void onRefreshFromPricesZone() {
refreshWatchList();
if (request.isXHR()) {
ajaxResponseRenderer.addRender(currentTimeZone, timeBlock).
addRender(pricesZone, pricesBlock);
}

}



 Thanks in advance for any assistance! 

Shing 


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



Re: Tap 5.3 : AjaxResponseRenderer error when updating two zones with chaining

2011-12-10 Thread Thiago H. de Paula Figueiredo

Hi!

Have you noticed you're still sending e-mails to  
tapestry-u...@jakarta.apache.org instead of users@tapestry.apache.org?  
Tapestry has been a top level Apache project for years! :D


On Sat, 10 Dec 2011 13:46:21 -0200, Shing Hing Man mat...@yahoo.com  
wrote:


 Ajax failure: Status 200 for  
http://localhost:8080/tapestry5Demo/test/core/mixin/stockwatcher2.priceszone:zonerefresh:  
undefined

Communication with the server failed: undefined


What's the console output?

--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor

Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

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



Re: Tap 5.3 : AjaxResponseRenderer error when updating two zones with chaining

2011-12-10 Thread Shing Hing Man
Hi Thiago,
    I am not  aware  the mailing list email address have changed since my first 
post back in 2004.   Thanks for pointing it out ! 
I will use the current email address  from next post. 

Back to my problem. There is no error on the server side. Hence there is no 
(new big) popup window on he client browser  to show the stack trace. 
The following messages are displayed like the new alert message  on the client 
browser. 

Ajax failure: Status 200 for 
http://localhost:8080/tapestry5Demo/test/core/mixin/stockwatcher2.priceszone:zonerefresh:
 undefined
 Communication with the server failed: undefined


Shing 



- Original Message -
From: Thiago H. de Paula Figueiredo thiag...@gmail.com
To: tapestry Tapestry tapestry-u...@jakarta.apache.org; Shing Hing Man 
mat...@yahoo.com
Cc: 
Sent: Saturday, December 10, 2011 5:28 PM
Subject: Re: Tap 5.3 : AjaxResponseRenderer error when updating two zones with 
chaining

Hi!

Have you noticed you're still sending e-mails to 
tapestry-u...@jakarta.apache.org instead of users@tapestry.apache.org? Tapestry 
has been a top level Apache project for years! :D

On Sat, 10 Dec 2011 13:46:21 -0200, Shing Hing Man mat...@yahoo.com wrote:

  Ajax failure: Status 200 for 
http://localhost:8080/tapestry5Demo/test/core/mixin/stockwatcher2.priceszone:zonerefresh:
 undefined
 Communication with the server failed: undefined

What's the console output?

--Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and 
instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br


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



Re: Tap 5.3 : AjaxResponseRenderer error when updating two zones with chaining

2011-12-10 Thread Thiago H. de Paula Figueiredo
On Sat, 10 Dec 2011 16:12:09 -0200, Shing Hing Man mat...@yahoo.com  
wrote:



Hi Thiago,


Hi!

I am not  aware  the mailing list email address have changed since  
my first post back in 2004.   Thanks for pointing it out !

I will use the current email address  from next post.


Nice!

Back to my problem. There is no error on the server side. Hence there is  
no (new big) popup window on he client browser  to show the stack trace.
The following messages are displayed like the new alert message  on the  
client browser.


Ajax failure: Status 200 for  
http://localhost:8080/tapestry5Demo/test/core/mixin/stockwatcher2.priceszone:zonerefresh:  
undefined

Communication with the server failed: undefined


The URL is weird, as it ends in 'undefined'. It seems some variable in  
JavaScript wasn't set and then added to the URL. I'd start investigating  
from this point.


Cheers!

--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor

Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

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



Re: Tap 5.3 : AjaxResponseRenderer error when updating two zones with chaining

2011-12-10 Thread Shing Hing Man
For now,  I can live with the other two work around. 

Shing    



- Original Message -
From: Thiago H. de Paula Figueiredo thiag...@gmail.com
To: tapestry Tapestry tapestry-u...@jakarta.apache.org; Shing Hing Man 
mat...@yahoo.com
Cc: 
Sent: Saturday, December 10, 2011 6:47 PM
Subject: Re: Tap 5.3 : AjaxResponseRenderer error when updating two zones with 
chaining

On Sat, 10 Dec 2011 16:12:09 -0200, Shing Hing Man mat...@yahoo.com wrote:

 Hi Thiago,

Hi!

     I am not  aware  the mailing list email address have changed since my 
first post back in 2004.   Thanks for pointing it out !
 I will use the current email address  from next post.

Nice!

 Back to my problem. There is no error on the server side. Hence there is no 
 (new big) popup window on he client browser  to show the stack trace.
 The following messages are displayed like the new alert message  on the 
 client browser.
 
 Ajax failure: Status 200 for 
 http://localhost:8080/tapestry5Demo/test/core/mixin/stockwatcher2.priceszone:zonerefresh:
  undefined
 Communication with the server failed: undefined

The URL is weird, as it ends in 'undefined'. It seems some variable in 
JavaScript wasn't set and then added to the URL. I'd start investigating from 
this point.

Cheers!

--Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and 
instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br


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