[prev in list] [next in list] [prev in thread] [next in thread] 

List:       tapestry-user
Subject:    RE: Help needed with DirectLink and page parameters (Was: Contrib:Table and page parameters)
From:       <Marcus.Schulte () bmw ! ch>
Date:       2007-12-20 8:55:59
Message-ID: 28B3CA79C817CA4CBA37CD115CE794DDDB3639 () mosexs01 ! europe ! bmw ! corp
[Download RAW message or body]

I suppose your page implements IExternalPage?
If you seed you page/app with external parameters which you need later
on,
in subsequent requests, store them in page/component properties marked
as
@Persist-ent.

> -----Original Message-----
> From: Kaspar Fischer [mailto:fischerk@inf.ethz.ch] 
> Sent: Wednesday, December 19, 2007 4:10 PM
> To: Tapestry users
> Subject: Help needed with DirectLink and page parameters 
> (Was: Contrib:Table and page parameters)
> 
> Dear list,
> 
> In order to isolate the problem, I tried to do something much
> simpler: showing
> a DirectLink on one of my pages.
> 
> The tapestry manual gives an example on how to use DirectLink with
> listeners:
> 
>    http://tapestry.apache.org/tapestry4/QuickStart/directlink.html
>    
> http://tapestry.apache.org/tapestry4/UsersGuide/listenermethods.html
> 
> However, these examples assume that the content of the page 
> containing the DirectLink does not depend on page parameters.
> 
> How can I use a DirectLink on a page that depends on a 
> parameter, for instance of, on a page like this
> 
>    http://my.org/app?page=Article&id=27
> 
> The link generated by a DirectLink component is something like
> 
>    http://...Article,$MyComponent.$DirectLink.sdirect
> 
> but does not mention the id. So the listener is executed but 
> afterwards, the Article page does not know which item (namely 
> id=27) it should show!
> 
> I feel very much that I am on the wrong track and would be 
> very glad to receive some help.
> 
> Many thanks,
> Kaspar
> 
> On 17.12.2007, at 20:50, Kaspar Fischer wrote:
> > Hm, I think my question was not well formulated. Apologies. 
> I'll try 
> > once more!
> >
> > Suppose you want to implement an index that shows all files 
> starting 
> > with "A", "B", etc. My page would show
> >
> >   A B C D ... X Y Z
> >
> > and you can click on a letter to show the files starting with this 
> > letter in a sortable Contrib:Table. How would I do this?
> >
> > Can somebody lead me on the right track?
> >
> > Thanks!
> > Kaspar
> >
> > On 16.12.2007, at 17:08, Kaspar Fischer wrote:
> >
> >> Hi list,
> >>
> >> How can I tell Contrib:Table to pass on page paremeters? 
> When I click 
> >> on a table column to sort it, the page that opens does not 
> have the 
> >> page parameters of the old page anymore!
> >>
> >> More precisely, my page "Page.html" uses a paremeter 
> (nodeid) to know 
> >> what content to display. So in Page.java's 
> pageBeginRender() method I 
> >> have
> >>
> >>     String nodeIdParam = cycle.getParameter("nodeid");
> >>
> >> and then I load the data from a database and display a few 
> things in 
> >> a Contrib:Table.
> >>
> >> Unfortunately, the link that the Contrib:Table generates 
> in order to 
> >> sort a column does not contain the value for parameter "nodeid":
> >>
> >>   http://localhost:8080/kc/
> >> Page,tableColumnComponent.linkColumn.sdirect?container=Contrib%
> >> 3ASimpleTableColumnPage&sp=APage%2C%
> >> 24SortableTable.table.tableView&sp=SnodeTableTitle
> >>
> >> So when I click the link, my node does not know what data to load 
> >> from the database!
> >>
> >> I think I need to tell Contrib:Table to include the nodeid in the 
> >> link, right?
> >>
> >> How can I do this?
> >>
> >> Many thanks,
> >> Kaspar
> 
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic