You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Peter Kanze <pe...@gmail.com> on 2009/03/27 10:45:15 UTC

T5: Are Search Form Fields Persisted Per Page?

Hello

At the top of the page I have a search form where a user can search on
product description, category etc..

The result list of products (generated below the search form) also contains
a pager component..

Like this Page:  1 | 2 | 3 | 4 | 5 | 6 ... | 11 | 12

When I click on a page link (page context = {parentCategory.id, pageNr} )
the search form is updated with previous search entries.

It looks like every page link has its own search form with its persisted
fields.. I don't want this behaviour.

My products loop is a volatile loop. Has it something to do with this?

I want my search form the keep the entries I typed in and not update it with
previous entries, when I navigate using the pager links.

Can anyone help me with this?

Thanks!

Peter

Re: T5: Are Search Form Fields Persisted Per Page?

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
To do that without any session persisted fields, not even flash ones,
I can think of two solutions: using cookies or to always change from
one page to the other doing an AJAX form submission when your user
clicks on a pagination link.

-- 
Thiago

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


Re: T5: Are Search Form Fields Persisted Per Page?

Posted by "Joost Schouten (mailing lists)" <jo...@jsportal.com>.
Its hard to make any assumptions from your story but it sounds like
you don't persist the search term and refetch all your products on
pagination. It seems unlikely that there will be a different search
form for each paginated representation of the same page.

The problem most likely lies in the way you access your DAO. A little
debug on the getter providing your Product's to your Grid's source
will probably give you the answers you need.

Cheers,
Joost



On Fri, Mar 27, 2009 at 1:45 AM, Peter Kanze <pe...@gmail.com> wrote:
> Hello
>
> At the top of the page I have a search form where a user can search on
> product description, category etc..
>
> The result list of products (generated below the search form) also contains
> a pager component..
>
> Like this Page:  1 | 2 | 3 | 4 | 5 | 6 ... | 11 | 12
>
> When I click on a page link (page context = {parentCategory.id, pageNr} )
> the search form is updated with previous search entries.
>
> It looks like every page link has its own search form with its persisted
> fields.. I don't want this behaviour.
>
> My products loop is a volatile loop. Has it something to do with this?
>
> I want my search form the keep the entries I typed in and not update it with
> previous entries, when I navigate using the pager links.
>
> Can anyone help me with this?
>
> Thanks!
>
> Peter
>

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