Jeremy Ford [EMAIL PROTECTED]
From: [EMAIL PROTECTED] Reply-To: "Jetspeed Users List" <[EMAIL PROTECTED]> To: "Jetspeed Users List" <[EMAIL PROTECTED]> Subject: Re: Template question Date: Wed, 30 Jun 2004 11:55:50 -0400
Jeremy, the URL doesn't specified the action, only the event...
After a few tries, finally I could display the template as I wished. This is what I did:
In the doEdit event method, the line where I set the template, changes from:
setTemplate(rundata, "addArticle"); setTemplate(rundata, "addArticle", true);
BUT....
when I call the doAddLinks event from the addArticle template, the data putted in context isn't read in the next render of the addArticle template.
What could be wrong??
Regards.
"Jeremy Ford" <[EMAIL PROTECTED]> 29-06-2004 13:31 Por favor, responda a "Jetspeed Users List" <[EMAIL PROTECTED]>
Para [EMAIL PROTECTED] cc
Asunto Re: Template question
What does the url look like that executes the event? If the action is specified, try removing it.
Jeremy Ford [EMAIL PROTECTED]
>From: [EMAIL PROTECTED] >Reply-To: "Jetspeed Users List" <[EMAIL PROTECTED]> >To: "Jetspeed Users List" <[EMAIL PROTECTED]> >Subject: Re: Template question >Date: Tue, 29 Jun 2004 10:07:53 -0400 > >Any ideas??? > > > > > >[EMAIL PROTECTED] >25-06-2004 16:11 >Por favor, responda a >"Jetspeed Users List" <[EMAIL PROTECTED]> > > >Para >[EMAIL PROTECTED] >cc > >Asunto >Template question > > > > > > >Hi.. I'll try to explain my problem... hope you can undertand it. >I've a VelocityPortlet with his default template. This template shows a >list of articles already stored in the db, and has a link to add a new >one: $jslink?eventSubmit_doEdit= > >This method (doEdit) only set a template wich has the input fields: > > public void doEdit(RunData rundata, Context context) throws Exception >{ > String id = rundata.getParameters().getString(ID); > if (id!=null){ > ArticlesManager mng = new ArticlesManager(); > Article article = mng.getArticle(new >Long(id).longValue()); > context.put("article", article); > } > context.put("totalLinks", new Integer(0)); > setTemplate(rundata, "addArticle"); > } > >Until here, everything goes fine... > >My problem is that I need to send some info from this template (addArticle > >- not the default) and come back to the same template, and always, despite > >of explicity set the template in the event method, the flow of the >application goes to the default template. > >This is the event I'm calling: > > public void doAddlinks(RunData rundata, Context context) throws >Exception { > ... > int totalLinks = rundata.getParameters().getInt("totalLinks", >0); > > ... > > context.put("totalLinks", new Integer(totalLinks)); > setTemplate(rundata, "addArticle"); > } > >please, any help would be very appreciated. > >regards, >Carlos. > >
_________________________________________________________________ MSN Movies - Trailers, showtimes, DVD's, and the latest news from Hollywood! http://movies.msn.click-url.com/go/onm00200509ave/direct/01/
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
_________________________________________________________________
FREE pop-up blocking with the new MSN Toolbar � get it now! http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
