Re: component paramter frustrations

2013-12-07 Thread John
I see what you mean Lance, yes that would be a neat solution so long as it is performant. John - Original Message - From: Lance Java To: Tapestry users Sent: Saturday, December 07, 2013 10:29 AM Subject: Re: component paramter frustrations Yep, I know. Which is why I

Re: component paramter frustrations

2013-12-07 Thread Lance Java
n > - Original Message - > From: Lance Java > To: Tapestry users > Sent: Saturday, December 07, 2013 8:04 AM > Subject: Re: component paramter frustrations > > > Perhaps you could write your own persistance strategy. > > @Persist(MyPersistConstants.EVENT

Re: component paramter frustrations

2013-12-07 Thread John
- Original Message - From: Lance Java To: Tapestry users Sent: Saturday, December 07, 2013 8:04 AM Subject: Re: component paramter frustrations Perhaps you could write your own persistance strategy. @Persist(MyPersistConstants.EVENT_CONTEXT) Which implicitly appends to the

Re: component paramter frustrations

2013-12-07 Thread Lance Java
Perhaps you could write your own persistance strategy. @Persist(MyPersistConstants.EVENT_CONTEXT) Which implicitly appends to the actionlink / eventlink context clientside and updates the fields serverside before delegating to the event.

Re: component paramter frustrations

2013-12-06 Thread John
ike method? > > - Original Message - > From: Thiago H de Paula Figueiredo > To: Tapestry users > Sent: Monday, December 02, 2013 11:00 AM > Subject: Re: component paramter frustrations > > > On Mon, 02 Dec 2013 07:21:27 -0200, John wrote: >

Re: component paramter frustrations

2013-12-06 Thread Dmitry Gusev
enueIdParm != null) { >> venueId = venueIdParm; >> } >> >> Is there something neater than doing this? Like maybe capturing those >> initial parameter values with a constructor like method? >> >> - Original Message - >> From

Re: component paramter frustrations

2013-12-06 Thread Dmitry Gusev
ueId = venueIdParm; > } > > Is there something neater than doing this? Like maybe capturing those > initial parameter values with a constructor like method? > > - Original Message - > From: Thiago H de Paula Figueiredo > To: Tapestry users > Sent:

Re: component paramter frustrations

2013-12-06 Thread Lance Java
"what would the value IF the @Parameter be" should be "what would the value OF the @Parameter be" (smartphone typo) On 6 Dec 2013 13:54, "Lance Java" wrote: > Let's consider that your component was being used in a t:loop and that the > current loop value was passed to your component as a @Paramet

Re: component paramter frustrations

2013-12-06 Thread Lance Java
Let's consider that your component was being used in a t:loop and that the current loop value was passed to your component as a @Parameter. We know that tapestry's static structure / dynamic behaviour means that there is only 1 instance of your component (rendered multiple times). So, what would t

Re: component paramter frustrations

2013-12-06 Thread Thiago H de Paula Figueiredo
On Fri, 06 Dec 2013 10:56:32 -0200, John wrote: Hi Lance, Hi! I am resistant to passing these parameters in the t:context to my event handlers because: 1) it is boilerplate stuff and Tapestry is supposed to handle that without me writing code That's very, very, very wrong. See my mes

Re: component paramter frustrations

2013-12-06 Thread Thiago H de Paula Figueiredo
On Fri, 06 Dec 2013 11:02:27 -0200, John wrote: Hi, Hi! I am not very CSS savy Thiago, but I think center is code efficient vs the css way? I disagree. HTML is structure, CSS is layout. is something that shouldn't be used anymore. Please see my previous response to Lance as to why I

Re: component paramter frustrations

2013-12-06 Thread John
parameters between requests. Just saying ;) John - Original Message - From: Thiago H de Paula Figueiredo To: Tapestry users Sent: Friday, December 06, 2013 11:28 AM Subject: Re: component paramter frustrations On Thu, 05 Dec 2013 21:53:44 -0200, John wrote: > here is

Re: component paramter frustrations

2013-12-06 Thread John
riday, December 06, 2013 8:36 AM Subject: Re: component paramter frustrations I've said this many times now. You must pass the parameters in the event context. onActionFromFoo(String param1, Foo param2, Bar param3) BTW: IMHO actionlink is deprecated and shouldn't be used

Re: component paramter frustrations

2013-12-06 Thread Thiago H de Paula Figueiredo
On Thu, 05 Dec 2013 21:53:44 -0200, John wrote: here is the template with the problematic actionlink highlighted Thanks! ${message:text.diarydenied} I haven't seen the very deprecated HTML tag for many years . . . I felt like in 1998 when I read it. :P t:zone="dateZon

Re: component paramter frustrations

2013-12-06 Thread Lance Java
I've said this many times now. You must pass the parameters in the event context. onActionFromFoo(String param1, Foo param2, Bar param3) BTW: IMHO actionlink is deprecated and shouldn't be used. Use eventlink instead.

Re: component paramter frustrations

2013-12-05 Thread John
dRender(timeZone).addRender(formZone); } The page class thows a NPE on subsequent use of the workIdParm. I'd really like the @Paremeter members to be added to all the client side links by default, seems like boilerplate code to me. - Original Message - From: Thiago H de Paul

Re: component paramter frustrations

2013-12-05 Thread Thiago H de Paula Figueiredo
Without the code *and* template we cannot help you. We could only guess what's happening. -- Thiago H. de Paula Figueiredo Tapestry, Java and Hibernate consultant and developer http://machina.com.br Help me spend a whole month working on Tapestry bug fixes and improvements: http://igg.me/at/t

Re: component paramter frustrations

2013-12-05 Thread John
TimeConstants.MS_DAY) * TimeConstants.MS_DAY); log.debug("selected " + new Date(timeClicked) + " " + startDatex); loadTimes(15); loadCallInTimes(); ajaxResponseRenderer.addRender(timeZone).addRender(formZone); } ... } ----- Original Message --

Re: component paramter frustrations

2013-12-02 Thread Thiago H de Paula Figueiredo
On Mon, 02 Dec 2013 12:14:39 -0200, John wrote: Yes that's right, my page is passing some key id values to deeper components, but the paramter value is lost after the intitial component render. That's my challenge. How are you updating the page after the initial render? Zone updates? Eve

Re: component paramter frustrations

2013-12-02 Thread Lance Java
As I said, you just pass the parameters in the event context of you events.

Re: component paramter frustrations

2013-12-02 Thread John
on action links, then the parameter has gone null though. - Original Message - From: Thiago H de Paula Figueiredo To: Tapestry users Sent: Monday, December 02, 2013 12:05 PM Subject: Re: component paramter frustrations On Mon, 02 Dec 2013 09:35:03 -0200, John wrote: >

Re: component paramter frustrations

2013-12-02 Thread Thiago H de Paula Figueiredo
On Mon, 02 Dec 2013 09:35:03 -0200, John wrote: I hear that, but again my point is what do you do with the parameter to persist it into the page? Must you have 2 members for the same value? My point is that you're basing this thread in a wrong assumption, which is persisting parameters. Th

Re: component paramter frustrations

2013-12-02 Thread John
gt; > Is there something neater than doing this? Like maybe capturing those > initial parameter values with a constructor like method? > > - Original Message - > From: Thiago H de Paula Figueiredo > To: Tapestry users > Sent: Monday, December 02, 2013 1

Re: component paramter frustrations

2013-12-02 Thread Thiago H de Paula Figueiredo
ecember 02, 2013 11:00 AM Subject: Re: component paramter frustrations On Mon, 02 Dec 2013 07:21:27 -0200, John wrote: > Hi, Hi! > I pass parameters to some of my componenets but they don't persist by > default And that's a very good thing. The less state you keep

Re: component paramter frustrations

2013-12-02 Thread John
users Sent: Monday, December 02, 2013 11:00 AM Subject: Re: component paramter frustrations On Mon, 02 Dec 2013 07:21:27 -0200, John wrote: > Hi, Hi! > I pass parameters to some of my componenets but they don't persist by > default And that's a very good t

Re: component paramter frustrations

2013-12-02 Thread John
From: Lance Java To: Tapestry users Sent: Monday, December 02, 2013 9:27 AM Subject: Re: component paramter frustrations I avoid session usage at all costs (with the exception to the rule being the logged in userId) Why not pass the parameter values in your events so the app is stat

Re: component paramter frustrations

2013-12-02 Thread Thiago H de Paula Figueiredo
On Mon, 02 Dec 2013 07:21:27 -0200, John wrote: Hi, Hi! I pass parameters to some of my componenets but they don't persist by default And that's a very good thing. The less state you keep in memory, the better. You are the one who knows what should be persisted and what shouldn't. Ac

Re: component paramter frustrations

2013-12-02 Thread Lance Java
I avoid session usage at all costs (with the exception to the rule being the logged in userId) Why not pass the parameter values in your events so the app is stateless? Also, remember that page. onActivate(...) is called for page render and ajax events so sometimes it's better to initialise here