Another option for remembering where you have come from is to tell the page
explicitly.
In Member have @Persist private Link _lastPageLink;
In Home/Other have @InjectPage private Member _memberPage;
You can use an action link handler to go to the page
protected Link getGotoMemberLink() {
Object
Angelo,
Sorry, return false (or true) is not an option, you must known the page
name. Returning null allow access.
Marcus
Angelo,
On a pretty creepy workaround, you can have, on the Member page, an String
attribute named caller that you can set with the "Other" or "Main"
values(depending on who called it) and you can return it on the Member's
onActivate method...
2007/9/19, Angelo Chen <[EMAIL PROTECTED]>:
>
>
> Tha
Thanks.
Marcus-11 wrote:
>
> Hi Angelo,
>
> Maybe this hel with your first question:
>
>
--
View this message in context:
http://www.nabble.com/T5%3A-redirecting-page-under-onActivate-tf4479292.html#a12775141
Sent from the Tapestry - User mailing list archive at Nabble.com.
-
Hi Nick,
I think so, one way to persist caller is, adding a t:id, here is what I do:
< a t:type="pagelink" page="Member" context="rowBltn.id"
t:id="Home">${RowBltn.name} a>
the rendered page will have something like this:
/myapp/member/6
Now, is there a way to access this id in the onActivat
Hi Angelo,
Maybe this hel with your first question:
public class ProtectedPage
{
@ApplicationState
private Visit _visit;
public Visit getVisit() { return _visit; }
public void setVisit(Visit _visit) { this._visit = _visit; }
public Object onActivate()
{
if (!_vis
I suspected you meant this. You'll have to persist the "caller" somehow.
If you're using a base page class you could store it in an ASO there.
Cheers,
Nick.
Angelo Chen wrote:
Hi Marcus,
Example: both Home.html and Other.html has a link to Member, when the link
is clicked, Member.class' onAct
Hi Marcus,
Example: both Home.html and Other.html has a link to Member, when the link
is clicked, Member.class' onActivate will be called, if I return null, it
displays Member.html, but I'd like to display Home or Other if there is
validation error, possible?
If not possible, is there a way to p
Just return null.
On 9/19/07, Angelo Chen <[EMAIL PROTECTED]> wrote:
>
> Hi Josh,
>
> Thanks, it works, a related question, how to redirect the page to the one
> calling? sometimes we don't know which one is "calling page", so we can't
> use page class/name to redirect, any idea? Thanks.
> A.C.
>
Hi Josh,
Thanks, it works, a related question, how to redirect the page to the one
calling? sometimes we don't know which one is "calling page", so we can't
use page class/name to redirect, any idea? Thanks.
A.C.
Josh Canfield-2 wrote:
>
> You can return an object that represents the page you
You can return an object that represents the page you want to redirect to.
The allowed objects are described here:
http://tapestry.apache.org/tapestry5/tapestry-core/guide/pagenav.html
Josh
On 9/19/07, Angelo Chen <[EMAIL PROTECTED]> wrote:
>
>
> Hi,
>
> Is there a way to redirect the page under
Hi,
Is there a way to redirect the page under onActivate? example: there might
be a logical error detected and program will direct user to another page
instead of the original one, possible? Thanks.
A.C.
--
View this message in context:
http://www.nabble.com/T5%3A-redirecting-page-under-onActiv
12 matches
Mail list logo