In your case, I think the best practice is to handle the event in the page but 
not the component. Or you can handle event in the component to perform common 
logic, then trigger another event and carry relevant data, so for the page, it 
can handle the second event to do somehing to change its activation context.

DH
http://www.gaonline.com.cn

----- Original Message ----- 
From: "kamiseq" 
To: <users@tapestry.apache.org>
Sent: Tuesday, December 08, 2009 7:38 AM
Subject: t5 handling events by components, event handling sequence


hi,
I ve wrote simple component that renders link and handles event triggered by
the link then it sets some value and should render that value.

the problem is that I get the value but then the value is lost as tapestry
redirects to a page that holds the component
Tabs is the page that renders TabNavigation component
[DEBUG] pages.Tabs @PageAttached
[DEBUG] components.TabNavigation got panel3
[INFO] AppModule.TimingFilter Request time: 18 ms
[DEBUG] pages.Tabs @PageDetached
127.0.0.1 -  -  [07/gru/2009:23:20:18 +0000] "GET
/generator/tabs.tabnavigation.tabselect/panel3 HTTP/1.1" 302 0 "
http://localhost:8080/generator/tabs.......
[DEBUG] pages.Tabs @PageAttached
[DEBUG] components.TabContainer @beginRender sets enivromental
[DEBUG] components.TabContainer @BeforeRenderTemplate idtabcontainer
[DEBUG] components.TabNavigation used null
[DEBUG] components.TabPane tabp...@setuprender fancy=sfssf
[DEBUG] components.TabPane tabp...@setuprender fancy=sfssf
[DEBUG] components.TabPane tabp...@setuprender fancy=sfssf
[DEBUG] components.TabContainer @AfterRenderTemplate
[INFO] AppModule.TimingFilter Request time: 19 ms
[DEBUG] pages.Tabs @PageDetached
127.0.0.1 -  -  [07/gru/2009:23:20:18 +0000] "GET /generator/tabs HTTP/1.1"
200 611 "http://localhost:8080/generator/tabs"; "Mozilla/5.0 ...

why is so and how can design my component to fix that. Of course I can
annotate the value field as @Persist-ent but I really would like to avoid
session as much as possible. Maybe I could set actionLink to point to Tabs
page instead of TabNavigation component and then assign value to
TabNavigation that will render correctly or some better way to sort that
out.

thanks for any advise
cheers

pozdrawiam
Paweł Kamiński

kami...@gmail.com
pkaminski....@gmail.com
______________________

Reply via email to