AppletTalk.com Forum Index AppletTalk.com
Java discussions newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

struts

 
Post new topic   Reply to topic    AppletTalk.com Forum Index -> Java (Italian)
View previous topic :: View next topic  
Author Message
Sergio
Guest





PostPosted: Thu Jun 22, 2006 2:29 pm    Post subject: struts Reply with quote



Ciao,
sto sviluppando una applicazione utilizzando struts .1.2.7, il mio
problema è il seguente.
Ho un oggetto di businnes che viene popolato da più pagine (stile
wizard), ed ho quindi più form ognuna con il priprio metodo validate e
i propri metodi di inserimento lettura delle properties, quandola prima
pagina finisce di popolare i dati passo ad una seconda pagina con un
nuovo form e una nuova action vorrei pero' che la nuova action
condividesse con la prima l'oggetto di businnes ed andare a popolare
quindi sempre lo stesso, è possibile?
Ciao
Sergio
Back to top
Tremal Naik
Guest





PostPosted: Thu Jun 22, 2006 7:19 pm    Post subject: Re: struts Reply with quote



Sergio wrote:
Quote:
Ciao,
sto sviluppando una applicazione utilizzando struts .1.2.7, il mio
problema è il seguente.

Utilizzo Struts 1.1, comunque non doivrebbe cambiare molto. Se non ho
capito male il tuo problema, allora ti consiglio di salvare l'oggetto
che devi "passare" tra le varie action in sessione.

La action recupera l'oggetto dalla sessione, lo modifica, poi lo
risalva in sessione per la action successiva:

public ActionForward execute(ActionMapping actionMapping, ActionForm
actionForm,
HttpServletRequest httpServletRequest, HttpServletResponse
httpServletResponse)
{
HttpSession session = httpServletRequest.getSession();
BeanCondiviso bc = (BeanCondiviso)
session.getAttribute("cicci");
//....
session.setAttribute("cicci", bc);
}

TREMALNAIK
Back to top
Display posts from previous:   
Post new topic   Reply to topic    AppletTalk.com Forum Index -> Java (Italian) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.