Re: Redirect not from onActivate

2010-02-24 Thread Alexander Kiel
> > For a beginner like me, it would be really nice if Tapestry had some > > lightweight annotations for authorization of pages, component visibility > > and events against some lightweight maybe only role based authentication > > service. > > Agreed. I may put something simple together for that

Re: Redirect not from onActivate

2010-02-24 Thread Howard Lewis Ship
On Wed, Feb 24, 2010 at 3:14 PM, Alexander Kiel wrote: >> > Well, because I want to redirect from other places in code, not from >> > onActivate() method. >> >> I think this is a good course. I think you'll find your pages more >> maintainable when you have this kind of organization in place. If y

Re: Redirect not from onActivate

2010-02-24 Thread Alexander Kiel
> > Well, because I want to redirect from other places in code, not from > > onActivate() method. > > I think this is a good course. I think you'll find your pages more > maintainable when you have this kind of organization in place. If you > have to get mid-way through processing or rendering the

Re: Redirect not from onActivate

2010-02-24 Thread Howard Lewis Ship
oncern; you can place an annotation on your page classes that control the behavior. This is how I've done simple page-level access security. > > But I see now it should be possible to redesign a bit to achieve required > redirect from onActivate(). > -- > View this message in contex

Re: Redirect not from onActivate

2010-02-24 Thread Algirdas
Well, because I want to redirect from other places in code, not from onActivate() method. But I see now it should be possible to redesign a bit to achieve required redirect from onActivate(). -- View this message in context: http://n2.nabble.com/Redirect-not-from-onActivate-tp4627871p4629010

Re: Redirect not from onActivate

2010-02-24 Thread Alexander Kiel
Hi Algirdas, why do you want to use response.sendRedirect()? You can simply return a page class name. Tapestry always redirects. Regards Alex On Wed, 2010-02-24 at 13:06 -0800, Algirdas wrote: > Thank you all for suggestions. > > > It appears that I have to redesign some of page activation rou

Re: Redirect not from onActivate

2010-02-24 Thread Algirdas
ctURI()); altho I did not tried calling this from exception handler in AppModule, but rather only from any routine in page code. Algirdas -- View this message in context: http://n2.nabble.com/Redirect-not-from-onActivate-tp4627871p4628555.html Sent from the Tapestry Users mailing list archi

Re: Redirect not from onActivate

2010-02-24 Thread Vassilis Bekiaris
GZipOutputStream.checkForCutover(BufferedGZipOutputStream.java:70) > > org.apache.tapestry5.internal.gzip.BufferedGZipOutputStream.write(BufferedGZipOutputStream.java:116) > > Algirdas > -- > View this message in context: > http://n2.nabble.com/Redirect-not-from-onActivate-tp

Re: Redirect not from onActivate

2010-02-24 Thread Thiago H. de Paula Figueiredo
On Wed, 24 Feb 2010 16:11:18 -0300, Algirdas wrote: Hello, Hi! Is there any way to do a redirect from any method? Not out-of-the-box. For example I have EnsureUserLoggedIn() which should redirect to Login page, but this is called not in onActivate() method. onActivate() (or any metho

Re: Redirect not from onActivate

2010-02-24 Thread Alexander Kiel
Hi Algirdas, you can use the @OnEvent annotation with a value of "activate". For the redirect, you should simply return the class of the page. Regards Alex On Wed, 2010-02-24 at 11:11 -0800, Algirdas wrote: > Hello, > > Is there any way to do a redirect from any method? > > For example I have

Redirect not from onActivate

2010-02-24 Thread Algirdas
/Redirect-not-from-onActivate-tp4627871p4627871.html Sent from the Tapestry Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h