I've added this method to my ActionBase class to get the action name.
/**
* Gets the action name. This is just the bare name without
".action" extension.
*
* This is equivalent to "#context['struts.actionMapping'].name"
from in a JSP.
*
* @return the action name
*
lucas owen wrote:
An easy one: how can I figure out the struts 2 previous action, the one I
come from?
You could be asking for either of two different things: The action
related to the current request? The action related to the URL being
displayed in the browser's address bar whe
lucas owen schrieb:
thanks for the answer, but I'm completely sure you can obtain it from
ActionContext or ActionInvocation or something similar...
Not to my knowledge (i may be wrong, though). My understanding of the
ActionContext and the ActionInvocation is that both are valid only per
req
action is not recall when you use your backspace key to go to
the previous page. So, this information is not relevant.
When I need the previous action, I extends an action that write in
session it's url and it's parameters and to retrieve it I call an action
that read the session an
of your request url.
>
>
> lucas owen wrote:
>
>> Hi Struts users:
>>
>> An easy one: how can I figure out the struts 2 previous action, the one I
>> come from?
>>
>> I ha
You'll have to track it all by yourself with an action ID or something
related, as a parameter of your request url.
lucas owen wrote:
Hi Struts users:
An easy one: how can I figure out the struts 2 previous action, the one I
come from?
I have tried everything but nothing works...
Than
Hi Struts users:
An easy one: how can I figure out the struts 2 previous action, the one I
come from?
I have tried everything but nothing works...
Thanks in advance!!!
logic on my business-logic module, it is bad design. That's not right. How
can I overcome this difficulty?
--
View this message in context:
http://www.nabble.com/%40Conversion-on-method-of-the-previous-Action-field-tp18584142p18584142.html
Sent from the Struts - User mailing l
>
>
> You might want to include a Marker interface so that you don't collect all
> the data from every request. If you have a BackAware interface (or
> BackTarget, or something else meaningful).
That's a good idea, but our app. saves the state depending on where you come
from,
not depending on w
Eduardo,
You might want to take a look at the breadcrumb plugin. It's basic
functionality is to create a breadcrumb trail like many popular sites on
the 'net.
http://cwiki.apache.org/S2PLUGINS/breadcrumbs-plugin.html
It may not be exactly what you're looking for, but it will provide a
good exam
On Feb 18, 2008 7:41 AM, Eduardo Yáñez Parareda <[EMAIL PROTECTED]>
wrote:
> The solution I'm going for is to implement a Filter or Interceptor which
> manages a stack of requests. I'll push the action and the request
> attributes
> in the stack, so when I have to go back, I can pop from the stack
The solution I'm going for is to implement a Filter or Interceptor which
manages a stack of requests. I'll push the action and the request attributes
in the stack, so when I have to go back, I can pop from the stack the action
and attributes needed to make the same search as before.
When user click
There's nothing specifically built in to handle that, and the exact
approach would depend on how your application is structured. However,
the general idea would be to record the user's location in the app at
the point you want to return them to.
If the 'go back' action is meant to take them ba
I forgot to say that what I'm asking for is a Struts2 way to do that, a
pattern, or a tool that S2 provides which could
help me to do it.
On 18/02/2008, Eduardo Yáñez Parareda <[EMAIL PROTECTED]> wrote:
>
> Hello,
>
> How could I come back to an action I executed before?
> i.e.:
>
> User is in scr
Hello,
How could I come back to an action I executed before?
i.e.:
User is in screen 1, then click the button search and some results are shown
to her. She dbclick in a result item
and it's shown the item's detail in screen 2. Then she wants to go back to
screen 1 how must I implement the
'g
Mailing List
Subject: Re: S2 action mapping: How to return to previous action?
Joachim Ansorg wrote:
> Hi all,
> I have two actions (action1 and action2) which both call a third
action.
>
> How can I do the mapping of the third action so that the calling
> action is called again (
Joachim Ansorg wrote:
Hi all,
I have two actions (action1 and action2) which both call a third action.
How can I do the mapping of the third action so that the calling action
is called again (i.e. action1 or action2)?
Before action1 or action2 finishes, store its name in one of the scopes
(r
Hi all,
I have two actions (action1 and action2) which both call a third action.
How can I do the mapping of the third action so that the calling action
is called again (i.e. action1 or action2)?
Thanks,
Joachim
-
To unsubscr
op"?
Thanks for your help!
jjgould wrote:
>
> Ted, et. al.,
>
> I am also interested in accessing the previous action from the target
> action of a "chain" result. But, the reason I want to get to that action
> is not because of any bean properties, but because I n
, et. al.,
I am also interested in accessing the previous action from the target action
of a "chain" result. But, the reason I want to get to that action is not
because of any bean properties, but because I need the action errors, action
messages, and field errors that may have been place
also interested in accessing the previous
> action from the target action
> of a "chain" result. But, the reason I want to get
> to that action is not
> because of any bean properties, but because I need
> the action errors, action
> messages, and field errors that may ha
Ted, et. al.,
I am also interested in accessing the previous action from the target action
of a "chain" result. But, the reason I want to get to that action is not
because of any bean properties, but because I need the action errors, action
messages, and field errors that may have b
in
> ChainInterceptor rely on OGNL and look like "magik".
>
> If there is not any ability to get a previous action and its properties
> manually after ChainResult, I agree to rely on ChainInterceptor.
>
> I posted a detailed message
> http://www.nabble.com/-S2--N
magik".
If there is not any ability to get a previous action and its properties
manually after ChainResult, I agree to rely on ChainInterceptor.
I posted a detailed message
http://www.nabble.com/-S2--NULL-Session-object-after-execAndWait-interceptor.-Why--tf4600442.html
about session
The Action itself is not copied over, the PROPERTIES are copied. If
the properties in common are copied forward, then there should be no
need to address the prior Action class directly. Any methods that need
to be called by more than one Action should be moved to a base support
class that the Actio
t;> action.
>>>>
>>>> I get behaviour : one.param->two.param.
>>>> But the property "param" must be in javaBeans specification(have
>>>> setter
>>>> and
>>>> getter method for each property).
>>>>
&g
operty "param" must be in javaBeans specification(have setter
and
getter method for each property).
Can i MANUALLY get object for "one" action or exact "one.property" from
:"execute()" method of action "two"?
--
View this message in context:
operty).
>>
>> Can i MANUALLY get object for "one" action or exact "one.property" from
>> :"execute()" method of action "two"?
>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Manually-o
ach property).
>
> Can i MANUALLY get object for "one" action or exact "one.property" from
> :"execute()" method of action "two"?
>
>
> --
> View this message in context:
> http://www.nabble
I try this in action "two".execute():
ValueStack stack=ActionContext.getContext().getValueStack();
CompoundRoot root = stack.getRoot();
List list = new ArrayList(root);
This list does not contain my previous action "one". It contains only
TextProviderObject.
C
You can, if you grab the ValueStck and traverse up it till you get to your
previous action.
Igor Vlasov wrote:
>
>
>
> I have action "one" and it calls action "two" throw:
> two
>
>
> I can use ChainingInterceptor to copy properties o
ation(have setter and
getter method for each property).
Can i MANUALLY get object for "one" action or exact "one.property" from
:"execute()" method of action "two"?
--
View this message in context:
http://www.nabble.com/-S2--Manually-obtain-previous-action
invoke the
last performed action.
-Dennis
"Grzegorz Stasica" <[EMAIL PROTECTED]>
Sent by: news <[EMAIL PROTECTED]>
11/08/2005 04:44 PM
Please respond to
"Struts Users Mailing List"
To
user@struts.apache.org
cc
Subject
repeat previous action from the other one
hi,
My problem could be strange but let me describe it. I've a application where
data for every page is customized to some filter. For example there is page
showing records from database. The data are limited to currently selected
user (user object stored in session). Hence there are many pages wh
sers Mailing List" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Subject: RE: Determine the previous action
Date: Fri, 17 Dec 2004 16:42:50 -0500
Gnan,
The two basic options are:
1) Hope all browsers visiting your site send the http "REFERE
Jim,
I think that was what I wrote in suggestion #2. :)
Regards,
David
-Original Message-
From: Jim Douglas [mailto:[EMAIL PROTECTED]
Sent: Friday, December 17, 2004 6:00 PM
To: [EMAIL PROTECTED]
Subject: RE: Determine the previous action
Couldn't you set an attribute and chang
<[EMAIL PROTECTED]>
Subject: RE: Determine the previous action
Date: Fri, 17 Dec 2004 16:42:50 -0500
Gnan,
The two basic options are:
1) Hope all browsers visiting your site send the http "REFERER" field. Not
all do.
2) Make navigation use forms and submit a hidden parameter holding
-
From: Shabada, Gnaneshwer [mailto:[EMAIL PROTECTED]
Sent: Friday, December 17, 2004 11:38 AM
To: '[EMAIL PROTECTED]'
Subject: Determine the previous action
Hello,
How can I determine the previous action I executed in Struts. I would like
to know which Action/Screen I came from and approp
> -Original Message-
> From: Shabada, Gnaneshwer [mailto:[EMAIL PROTECTED]
> Sent: Friday, December 17, 2004 9:38 AM
> To: '[EMAIL PROTECTED]'
> Subject: Determine the previous action
>
>
>
> Hello,
> How can I determine the previous action I
Hello,
How can I determine the previous action I executed in Struts. I would like
to know which Action/Screen I came from and appropriately do something in my
application. Is there anyway I could do that?
TIA
Gnan
This
40 matches
Mail list logo