Hi Luka,
It's probably best to ditch the mental model of "rewind" and "render"
in T5. I think what you're after is covered in this thread on "Edit
page best practice":
http://thread.gmane.org/gmane.comp.java.tapestry.user/56176/focus=57580
It's discussed and demonstrated in Tapest
Luca,
Check the Form documentation for prepareForRender() and prepareForSubmit().
They can be better places to do heavy initialization than onActivate().
Also, take a look at @Persist("flash") which is meant to retain information
for only one additional cycle (like the render after a form submit)
I'll add to this and say that if you want sorting behavior, you can
implement Comparable and Comparator (I don't remember which you need - I
tend to implement both), and add "location" to your model.
IIRC, you will need to build your model in code to say that the "location"
column is sortable.
Wow, Josh. Thanks, that's a lot of work! I'll try.
On Fri, Apr 18, 2008 at 6:53 PM, Josh Canfield <[EMAIL PROTECTED]>
wrote:
> I'm not sure if there is an easier way to do this, but you could
> configure a MarkupRendererFilter that finds and moves your elements
> before the page is written. Thi
I'm not sure if there is an easier way to do this, but you could
configure a MarkupRendererFilter that finds and moves your elements
before the page is written. This is how pageRenderSupport.addScript
works, sortof...
Here's something I whipped up. You could push something on the
environment to st
Me again,
> That is an interface (Messages is not)
Huuh!! Bad, faux pas! I have to correct myself in fact Messages IS an
interface. But no matter it does not work.
Bye
- original Nachricht
Betreff: Re: Re: Re: [T5] Sending Email from Tapestry
Gesendet: Sa, 19. Apr 2008
Von: nille
Hi Thiago,
I am aware of the difference between App.properties and page specific
properties. As my App.properties tends to grow significantly, I try to keep
everything local unless it is needed by at least two components/pages.
BTW, using Messages as a parameter to a build method in AppModule.
Hi Lucca,
I'd been looking for a good example to use to write a wiki explaining
the integration javascript by Tapestry, and your request gave me what I
was looking for. Check out the article here:
http://wiki.apache.org/tapestry/Tapestry5AndJavaScriptExplained (project
source: http://thegodcode.ne
On Apr 18, 2008, at 4/189:56 AM , Jan Vissers wrote:
I think I'm getting a bit further now - sorry to spam this list by the
way...
If I pass the breadCrumb model in the Component class instead via the
Component Template something is happening.
So instead of:
I have a component that picks up a Block via
componentResources.getBlockParameter(String). No problem. But I need to
render this Block at the very bottom of the overall page, right before the
.
Any thoughts?
--
Bill @ PeoplePad
I'm getting an error after switching to 5.0.11. I'm using
BeanEditForm for a bean that has a field of type java.io.File, which I
want to render as a text box (that holds the file path). I do this in
AppModule:
public static void
contributeDefaultDataTypeAnalyzer(MappedConfiguration,
String>
perhaps this helps you
http://87.193.218.134:8080/t5components/t5c-contrib/howto_freemarkerservice.html
2008/4/18, nille hammer <[EMAIL PROTECTED]>:
>
>
> Dear List,
>
> I am currently buidling an ordinary booking application. When a customer
> books something I collect everything in a Booking obj
On 4/18/08, nille hammer <[EMAIL PROTECTED]> wrote:
> Hi Thiago,
Hi, Nille!
> thanks for the advice that makes perfect sense! What is left is my first
> question, where does Tapestry how to choose the right message catalogue? If I
> injected the ConfirmationMailSender in my BookingSummary Pa
On Fri, Apr 18, 2008 at 11:54 AM, Jonathan Barker <
[EMAIL PROTECTED]> wrote:
>
>
> You've been too active with technical issues on the list to be labeled a
> troll... unless Rob has a split personality and you are the side that
> actually knows something. Hmmm. An interesting email address, BT
Hi Thiago,
thanks for the advice that makes perfect sense! What is left is my first
question, where does Tapestry how to choose the right message catalogue? If I
injected the ConfirmationMailSender in my BookingSummary Page would Tapestry
use it´s message catalogue? So would I have to put the
HAHA... This honestly sounds like words comming out of Satan's mouth...
Wait a minute, I've heard that somewhere... "Needful Things" by Steven King.
Any movie fans out there? Robbie is emerging as Leland Gaunt driving
that nice old black Mercedes into the quiet town of Castle Rock...
Leland Gaun
On 4/18/08, nille hammer <[EMAIL PROTECTED]> wrote:
> And secondly as far as I understand only services can be parameters to build
> methods. Am I wrong or do I have to make my Booking class a service?
I suggest you a slightly different approach: create a
ConfirmationMailSender service. It will
On 4/18/08, Angelo Turetta <[EMAIL PROTECTED]> wrote:
> And why your hypothetical 1.0 need not to be compatible with 2.0, whereas
> just because Tapestry 4.0 is not compatible with 5.0 you feel like defending
> someone deliberately insulting Howard?
In my humble opinion, Yura is not defending Rob
Dear List,
I am currently buidling an ordinary booking application. When a customer books
something I collect everything in a Booking object. I display the data in a
page BookingSummary, which contains a link "confirm booking". When booking is
confirmed I want to create a confirmation email t
I want to call an event on that particular page.. not the current page.
nille hammer wrote:
Hi Fernando,
Why should it? Couldn´t you return the desired page from the event handler
method?
greetz nillehammer
- original Nachricht
Betreff: EventLink taking optional page
Gesendet:
Expressing dissent is not trolling. Sure one could argue that what
constitutes trolling is subjective, but almost any reasonable person can
discern when the line has been crossed. Francis is a lying mischievous
fool that periodically chimes in in hopes of pissing off users, or
scaring off newbies.
Hi Fernando,
Why should it? Couldn´t you return the desired page from the event handler
method?
greetz nillehammer
- original Nachricht
Betreff: EventLink taking optional page
Gesendet: Fr, 18. Apr 2008
Von: Fernando Padilla<[EMAIL PROTECTED]>
> Does anyone else want a patch to
Does anyone else want a patch to have the EventLink component take an
optional page parameter?
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
You've been too active with technical issues on the list to be labeled a
troll... unless Rob has a split personality and you are the side that
actually knows something. Hmmm. An interesting email address, BTW, given
the topic of conversation :-)
And he (Rob) does have a point on backward comp
Yura Tkachenko wrote:
I hope after reading my post you won't add me to this page -
http://wiki.apache.org/tapestry/Tapestry5Trolls
I really want to defend Rob :-) Since some of his points are real problems
of Tapestry.
I will say it again: backward compatibility.
Of course major releases shouldn'
I hope after reading my post you won't add me to this page -
http://wiki.apache.org/tapestry/Tapestry5Trolls
I really want to defend Rob :-) Since some of his points are real problems
of Tapestry.
I will say it again: backward compatibility.
Of course major releases shouldn't be compatible, i.e. 1.
your tapestry lib is in the shared tomcat lib-folder. Looks like this
leads to an old version of commons-pool being used. Either update to
the latest commons-pool, or, better, put all your web-app dependencies
including tapestry and all its dependencies into WEB-INF/lib
On 18/04/2008, abangkis <[E
It sounds like what you are describing is @Persist("flash") which
stores the object in the session until the next time its read
(generally on the render pass)
You can also take a look at
http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry/ComponentResourcesCommon.html#isRendering()
Just spent a lot of timing hammering away at a problem and with the help
of the great Tapestry community - which is building - finally got it
working. Wanting to say thank you to all of you and we'll keep on
rocking! Together we can make Tapestry 5 great!
-J.
Me too Jan, thank you.
I was also passing a list via the template loop component attribute 'source' as
well, and I was also wrapping it with ${} - I've obviously spent too long using
the JSP EL! This would be a good gotcha to add to the wiki or even possibly the
T5 documentation...?
Anyway it
Spot on! Now I also understand why the .tml passing didn't work. This is
a great 'a-ha' moment for me!
-J.
On Fri, 2008-04-18 at 17:03 +0200, Chris Lewis wrote:
> Ok I think I see the problem. In your layout replace this:
>
> t:breadCrumbs="${basePage.breadCrumbHolder.model}"
>
> with this:
>
>
Ok I think I see the problem. In your layout replace this:
t:breadCrumbs="${basePage.breadCrumbHolder.model}"
with this:
t:breadCrumbs="basePage.breadCrumbHolder.model"
Notice the lack of ${}. ${} is trying to convert it to a string, which
it's not. When passing params to components you don't u
I'm deeply sorry for keeping you guys busy, and really appreciate the
feedback. But I nailed it. It had to do with the way I'm passing the
model. Via the Layout class it works, but not so via the Layout
template. I'm sure (am I?) that this is by design of T5 - so sorry for
any inconvenience.
-J.
Wow this is a bit tangled. I remember this from the other thread now( [
BasePage -> Layout -> RealPage ] ). I don't mean to jerk you around, but
can you provide the exception report page? I think if we can see the
line causing this as well as the stack trace, we can nail down where T5
is expecting
I think I'm getting a bit further now - sorry to spam this list by the
way...
If I pass the breadCrumb model in the Component class instead via the
Component Template something is happening.
So instead of:
I do in .java
@Component(inheritInformalParameters = true, parameters =
{ "loginPage=inhe
The layout component that passes in the 'breadCrumb' model to the
'heading' component which should render the breadcrumbs...
http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
http://www.w3.org/1999/xhtml";
xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";>
Filled with all kinds of 'debug' stuff'
http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";>
${message:text-yourhere}
${message:text-loginpage}
A
And that is the part I want to see, from the template code which you
still haven't shared ;-). What I'm referring to is your .tml file where
you use this component.
Jan Vissers wrote:
> In the snippet below if I change:
> public List getBreadCrumbs()
>
> and let it return a freshly created lis
In the snippet below if I change:
public List getBreadCrumbs()
and let it return a freshly created list. The loop construct works.
However via the @Parameter (passing it it) doesn't.
-J.
On Fri, 2008-04-18 at 16:27 +0200, Jan Vissers wrote:
> Here it is:
>
> import java.util.List;
>
> im
I'm sorry but I'm a bit confused by the terminology. I'm not a T4 user
and the only thing I know about "rewind" is that it does not exist in
T5. If you want to initialize business data, onActivate is the place to
do it. If you want to handle form events, use event handlers to catch
them. If you wan
Here it is:
import java.util.List;
import org.apache.log4j.Logger;
import org.apache.tapestry.annotations.Parameter;
import com.philips.lighting.guidecontrol.view.BreadcrumbBean;
/**
* The heading component holds the following pieces of Heading
information.
*
*
*
*
Hi Chris,
thank you.
Sorry, I didn't explain well. I intended from an "html page" point of view.
Example: I have a page with a form. I'd like to track its lifecycle
both for the "rewind" and "render" phase
(I use T4 "rewind" term to indicate that the application is "exiting"
from a page, and "ren
We still haven't seen your template code, where you declare this
component and pass it the model. I can't be sure but perhaps it will
shed some light...
Jan Vissers wrote:
> The problem is somehow related to the way my page and component are
> hooked up/working.
>
> For testing purposes I now crea
Without having read this thread carefully I suggest that you try to add
volatile="true" to your loop.
2008/4/18, Jan Vissers <[EMAIL PROTECTED]>:
> The problem is somehow related to the way my page and component are
> hooked up/working.
>
> For testing purposes I now create the Breadcrumb list i
The problem is somehow related to the way my page and component are
hooked up/working.
For testing purposes I now create the Breadcrumb list in the component
itself, simply returning a created list on the fly whenever
getBreadCrumbs() is called. This works as expected!!!
Strange thing is that via
Hi,
thought I'd post my experiences with a form with multiple components in a loop.
My initial (preferred) solution was to have a single form with a
series of components in a loop. As far as I can tell this is simply
not possible with Tapestry at the moment. What can be done is:
1. Inject FormSu
That looks good to me. I don't have an example I can look at with a
loop, but I do have one with a t:grid in which I reference a bean
property of a custom class. It's possible that the two are vastly
different, but I wouldn't think that.
Jan Vissers wrote:
> On the component I have:
>
> @Param
_that sounds like a bug to me. It should stay as an Object, and since its
not rendered, shouldn't need to string-itised.
http://tapestry.apache.org/tapestry5/tapestry-core/ref/org/apache/tapestry/corelib/components/Loop.html
value type is Object
weird... so far I've only looped enums, so I wouldn
I think I encountered the same issue last week where I wanted to loop over a
List of objects that were instances of one of my own classes. The loop
component code finds it necessary to be able to convert the object into a
string and then back again when populating your value property variable fr
On the component I have:
@Parameter
private List breadCrumbs;
This is passed in via the containg (base)page.
And in the same component class I have:
private BreadcrumbBean crumb;
public BreadcrumbBean getCrumb() {
return crumb;
}
public void setCrumb(BreadcrumbB
? is your crumb property of type BreadCrumbBean, or is it type String?
should be same as breadCrumbs
On Fri, Apr 18, 2008 at 1:56 PM, Chris Lewis <[EMAIL PROTECTED]>
wrote:
> I can't speak about your t:if bit because I don't know what "LastCrumb"
> would be, but assuming that your page class has
I can't speak about your t:if bit because I don't know what "LastCrumb"
would be, but assuming that your page class has getters/setters (or the
property is annotated with @Property) for the "crumb" property, a getter
for your "breadCrumbs," and your crumb bean defines a "getName" method,
you *shoul
Luca,
I think what you want is the page life cyle method "PageDetached." See:
http://tapestry.apache.org/tapestry5/tapestry-core/guide/lifecycle.html
sincerely,
chris
Luca Fossato wrote:
> Hi,
>
> in Tapestry 5 is there a way to determine if the application is
> entering or exiting from a page (
Hi, a don't see "typeChanged" element in your code, and javascript code
("tapestry.cleanConnect("yypeChanged", "onchange", "formEvent2604279"); ")
has error, don't see yypeChanged element. Put all your code and use Target
instead of Element, and put, if you have, a response when you use a Target
i
Yep, sure, I may I add - This mailing list is great and Tapestry rocks!
${crumb.name}
${crumb.name}
>
-J.
On Fri, 2008-04-18 at 14:34 +0200, Chris Lewis wrote:
> Can you share some code? At least the relevan
Hi,
in Tapestry 5 is there a way to determine if the application is
entering or exiting from a page (like the T4 api :
event.getRequestCycle().isRewinding() ) ?
Thank you,
Luca
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For add
Can you share some code? At least the relevant part from template would
be helpful.
chris
Jan Vissers wrote:
> Hi,
>
> Just to make sure I'm not missing something.
>
> In T4 when I wrote a @For construct I could use value="..." as long as I
> provided a setter|getter pair for the class involved -
Hi,
Just to make sure I'm not missing something.
In T4 when I wrote a @For construct I could use value="..." as long as I
provided a setter|getter pair for the class involved - in this case
BreadcrumbBean. I want to iterate over a list of beans and use each
instance individually. Now T5 throws up
Rob Smeets wrote:
Left me alone, Tapestry should be kicked from Apache because it's destroying
it's image.
If it was in my power, YOU would be kicked from Apache and all their m/l.
Chris, I see you constantly linking me to others. Who is that Francis? I
hope he/she (since that name sounds fem
Move your abstract page out of your pages package.
http://tapestry.apache.org/tapestry5/tapestry-core/guide/component-classes.html:
"In addition, it is common for an application to have base classes,
often abstract base classes, that should not be directly referenced.
These should not go in the p
'best way' ?
I can tell you what I think is better...
I would suggest that you handle AbstractBasePage -> Layout the same way that
you handle Layout -> Heading.
Let me guess - you want every page to have a title... I was thinking of that
at one stage.
The is a way to get the page class doing the
Hi Petros,
the problem is caused by the expression
context="{account?.accountManager?.username}". With "?." you tell Tapestry:
"The value might be null, please check before calling the Method." As null
values aren´t allowed in context, you must not tell Tapestry that your values
might be null.
Issue solved.
After creatuing a page specification and specifiying the class to be
used, it works.
But it's really strange, because the correct class has been found for
quite a long time without the specification, just by following the
conventions...
--
Add the @Property annotation to dummy in component class to provide
getter+setter?
> -Original Message-
> From: Jan Vissers [mailto:[EMAIL PROTECTED]
> Sent: 18 April 2008 11:59
> To: nicholas Krul
> Cc: Tapestry users
> Subject: Re: T5: How do I access a page property in my component
>
>
Somehow got it working:
AbstractBasePage (AbstractBasePage.java) declares:
public int getSize() {
return 57575; //Test
}
Layout declares (Layout.java):
@InjectContainer
private AbstractBasePage basePage;
Heading component on Layout template declares (Layout.tml):
Heading
It feels like the default page class is used, which I have defined like
that:
value="de.net22.oos.web.pages.OosBasePage"/>
Well, it should not be used.
Actually, before I changed the page class to implement IExternalPage,
the correct page class has been found correctly. It's not worki
This approach doesn't work.
Top level class->
public abstract class AbstractBasePage {
private int dummy;
public int getDummy() {
return 14575; //Test
}
}
Component class (which is part of Layout)
@Parameter
private int dummy;
Component template
${d
I get the error message:
Page /booking/Details does not implement the
org.apache.tapestry.IExternalPage interface.
The root cause is:
java.lang.ClassCastException: $BasePage_0 cannot be cast to
org.apache.tapestry.IExternalPage
(BasePage is a superclass of BaseBookingPage)
Although my c
@Paramater per property required.
If you need access to all of them as a bundle, consider wrapping them into a
class.
...
or (I guess) you could use
@Parameter
private MyBasePageClass basePage;
and make sure that the MyBasePageClass has a getThis(return this;) method
bind as
(I think)
I'd
Noticed the @InjectPage annotation and tried that - as the javadoc
talked about accessing read only properties of a page. However I get
this:
[ERROR] RequestExceptionHandler Processing of request failed with
uncaught exception:
com.*.lighting.guidecontrol.view.pages.AbstractBasePage
java.lang.
Ok - figured out what @InjectContainer gives me.
Although I'm not quite happy with it, as it returns another component,
which contains the component - but not the actual page. This is one
level further up the foodchain for me ;-)
Would be nice to have a direct way to access page properties :-(
-
Thanks - but I don't understand...
What is the parameter - the containing page?
Basically I want to access a property from my 'AbstractBasePage' which
has some common properties on it from a component that is placed on a
concrete page.
@Chris: regarding your hint of @InjectContainer...? what sho
bind it as a paramater
@Paramater(required=true) //only if required
Object needed
On Fri, Apr 18, 2008 at 11:07 AM, Chris Lewis <[EMAIL PROTECTED]>
wrote:
> Jan,
>
> There's probably a simpler way, but you should be able to use
> @InjectContainer in your component to get the page and call what
Jan,
There's probably a simpler way, but you should be able to use
@InjectContainer in your component to get the page and call whatever
methods (in your case a a getter) you want. I imagine there's a more
terse way, but I'm not sure what it would be.
chris
Jan Vissers wrote:
> Hi,
>
> I want to
Hi,
I want to access a page property from within my component - that has
been placed on that page. In T4 I had something like 'page.' - how is
this done in T5?
Thx,
-J.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional
Hi DH,
it would be:
---
${currentUser.location.city}
---
(Note the "add" instead of include - you want to add something not already
existing
hey Rob,
if your intentions are this honest, I mean you care for the newbies, and so
on, why not start up your own blog, like Joel on Software, and spread your
ghospels there about the ultimate truth? you don't like Tapestry, that's it.
Ok, you've been heard. What else you want?
cheers,
Janos
a T
Hi, Tobias
Thanks for reply.
I am newbie of customizing grid component.
I guess what you mean like this?:
But exception message still exists: "Bean editor model for User does not
contain a property named 'location_city'".
Thanks!
DH
- Original Message -
From:
Thanks a lot for your hints.
The problem was the name of the servlet filter and the build method, which
has to be static.
Regards
Michael
On Thu, Apr 17, 2008 at 10:01 PM, Igor Drobiazko <[EMAIL PROTECTED]>
wrote:
> Method bind shoould be static
>
> On Thu, Apr 17, 2008 at 9:56 PM, Michael Sz
Hi DH,
you can teach Location a standard way to be outputted by overwriting the
toString() function of Location.
Now you can output the String returned by toString() simply by including
"location".
If you want to output different properties of Location and not in one
cell, I think you will
after client validation is skipped,
you have to catch the selected event from that button
and clear validation errors on form
something like this:
public void onSelectedFromCancel(){
_form.clearErrors();
}
Davor Hrg
On Fri, Apr 18, 2008 at 9:28 AM, Jan Vissers <[EMAIL PROTECTED]> wrote:
>
> However when I come back to the form - the respective fields are (still)
> marked as erroneous. Any way around that?
This is related to this issue:
https://issues.apache.org/jira/browse/TAPESTRY-2354
I think this is fixed in the trunk - or at least you can specify the
persistence scope of the V
Using this script - indeed skips client side validation.
However when I come back to the form - the respective fields are (still)
marked as erroneous. Any way around that?
-J.
On Tue, 2008-04-15 at 20:38 +0200, Davor Hrg wrote:
> you can do it with javascript... sth like this (not tested)
>
> pu
83 matches
Mail list logo