You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by TNO <tn...@free.fr> on 2010/04/14 16:52:38 UTC
GridPager with go to a choosen page number
Hi everybody,
I'm working on display a huge list (60 000 elements) with 20 per page.
I've defined my own GridDataSource to get only the data that I display
in a classic Grid component.
It's very easy and it works fine ! Thanks to Tapestry...
But now, I want to add a textfield and a button (go to page number) to
the GridPager of my Grid.
It's seems less easy.
Did somebody already create a new GridPager ?
How can I defined my own GridPager without create a new Grid component ??
Thanks, Thomas
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
How to customize GridPager component
Posted by Daniel Henze <dh...@googlemail.com>.
Dear community,
I have some particular requirements for displaying data and did already
extend the Grid to provide some custom template. Now I have the need to
customize the grid pager as well, but am failing so far. I started off
with duplicating the code and then changed beginRender method to create
more customizable code (basically additional divs for css styling).
In my Grid class I do set the pager to my class (MatchpatchGridPager)
with standard parameters as before:
@Component(parameters = {
"source=dataSource",
"rowsPerPage=rowsPerPage",
"currentPage=currentPage",
"zone=zone" })
private MatchPatchGridPager pager;
But when executing the code I get the following exception:
de.matchpatch.components.MatchPatchGridPager cannot be cast to
org.apache.tapestry5.corelib.components.GridPager
This approach did work fine for GridRows and GridColumns where I did
overwrite the template. What am I doing wrong here?
Thanks
Daniel
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: GridPager with go to a choosen page number
Posted by Christophe Cordenier <ch...@gmail.com>.
Hi
2010/4/14 TNO <tn...@free.fr>
> Ok I dit it, but in another simpliest way
>
> I create a form with a textfield in my Grid component. I inject the value
> in the Grid with setCurrentPage
>
Nice
>
> thats'all
>
> thanks
>
>
> Le 14/04/2010 17:15, TNO a écrit :
>
> Any example, please...
>>
>> Le 14/04/2010 16:58, Christophe Cordenier a écrit :
>>
>>> Hi
>>>
>>> 2010/4/14 TNO<tn...@free.fr>
>>>
>>> Hi everybody,
>>>>
>>>> I'm working on display a huge list (60 000 elements) with 20 per page.
>>>> I've defined my own GridDataSource to get only the data that I display
>>>> in a
>>>> classic Grid component.
>>>> It's very easy and it works fine ! Thanks to Tapestry...
>>>>
>>>> But now, I want to add a textfield and a button (go to page number) to
>>>> the
>>>> GridPager of my Grid.
>>>>
>>>> It's seems less easy.
>>>> Did somebody already create a new GridPager ?
>>>> How can I defined my own GridPager without create a new Grid component
>>>> ??
>>>>
>>>> Set pager position to none and implement your own GridPager using the
>>> Grid
>>> component as the GridDataSource (can be obtained via @InjectComponent in
>>> your containing page)
>>>
>>> Regards,
>>> Christophe Cordenier.
>>>
>>>
>>> Thanks, Thomas
>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> 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
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>
--
Regards,
Christophe Cordenier.
Developer of wooki @wookicentral.com
Re: GridPager with go to a choosen page number
Posted by TNO <tn...@free.fr>.
Ok I dit it, but in another simpliest way
I create a form with a textfield in my Grid component. I inject the
value in the Grid with setCurrentPage
thats'all
thanks
Le 14/04/2010 17:15, TNO a écrit :
> Any example, please...
>
> Le 14/04/2010 16:58, Christophe Cordenier a écrit :
>> Hi
>>
>> 2010/4/14 TNO<tn...@free.fr>
>>
>>> Hi everybody,
>>>
>>> I'm working on display a huge list (60 000 elements) with 20 per page.
>>> I've defined my own GridDataSource to get only the data that I
>>> display in a
>>> classic Grid component.
>>> It's very easy and it works fine ! Thanks to Tapestry...
>>>
>>> But now, I want to add a textfield and a button (go to page number)
>>> to the
>>> GridPager of my Grid.
>>>
>>> It's seems less easy.
>>> Did somebody already create a new GridPager ?
>>> How can I defined my own GridPager without create a new Grid
>>> component ??
>>>
>> Set pager position to none and implement your own GridPager using the
>> Grid
>> component as the GridDataSource (can be obtained via @InjectComponent in
>> your containing page)
>>
>> Regards,
>> Christophe Cordenier.
>>
>>
>>> Thanks, Thomas
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> 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
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: GridPager with go to a choosen page number
Posted by TNO <tn...@free.fr>.
Any example, please...
Le 14/04/2010 16:58, Christophe Cordenier a écrit :
> Hi
>
> 2010/4/14 TNO<tn...@free.fr>
>
>
>> Hi everybody,
>>
>> I'm working on display a huge list (60 000 elements) with 20 per page.
>> I've defined my own GridDataSource to get only the data that I display in a
>> classic Grid component.
>> It's very easy and it works fine ! Thanks to Tapestry...
>>
>> But now, I want to add a textfield and a button (go to page number) to the
>> GridPager of my Grid.
>>
>> It's seems less easy.
>> Did somebody already create a new GridPager ?
>> How can I defined my own GridPager without create a new Grid component ??
>>
>>
> Set pager position to none and implement your own GridPager using the Grid
> component as the GridDataSource (can be obtained via @InjectComponent in
> your containing page)
>
> Regards,
> Christophe Cordenier.
>
>
>
>> Thanks, Thomas
>>
>>
>>
>> ---------------------------------------------------------------------
>> 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
Re: GridPager with go to a choosen page number
Posted by Christophe Cordenier <ch...@gmail.com>.
Hi
2010/4/14 TNO <tn...@free.fr>
> Hi everybody,
>
> I'm working on display a huge list (60 000 elements) with 20 per page.
> I've defined my own GridDataSource to get only the data that I display in a
> classic Grid component.
> It's very easy and it works fine ! Thanks to Tapestry...
>
> But now, I want to add a textfield and a button (go to page number) to the
> GridPager of my Grid.
>
> It's seems less easy.
> Did somebody already create a new GridPager ?
> How can I defined my own GridPager without create a new Grid component ??
>
Set pager position to none and implement your own GridPager using the Grid
component as the GridDataSource (can be obtained via @InjectComponent in
your containing page)
Regards,
Christophe Cordenier.
> Thanks, Thomas
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>
--
Regards,
Christophe Cordenier.
Developer of wooki @wookicentral.com