Skip Menu |

This queue is for tickets about the Template-Plugin-Pagination CPAN distribution.

Report information
The Basics
Id: 24604
Status: open
Priority: 0/
Queue: Template-Plugin-Pagination

People
Owner: Nobody in particular
Requestors: szel.miklos [...] rivendel.hu
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: inproper item handling when there are only one
Date: Fri, 26 Jan 2007 20:29:31 +0100
To: bug-Template-Plugin-Pagination [...] rt.cpan.org
From: Szél Miklós <szel.miklos [...] rivendel.hu>
An error occurs when there are only one item on a page, instead of showing the one correctly, it displays many elements without data (as there is no data to fill them). This could be a temporary solution: [% IF page.total_entries == 1 %] [% FOREACH items IN somedata %] [% INCLUDE dataform.tmpl %] [% END %] [% ELSE %] [% FOREACH items IN page.page_data %] [% INCLUDE dataform.tmpl %] [% END %] [% END %] but I don't like this way Best, Miklos
From: explorer [...] joaquinferrero.com
El Vie Ene 26 14:30:06 2007, szel.miklos@rivendel.hu escribió: Show quoted text
> An error occurs when there are only one item on a page, instead of > showing the one correctly, it displays many elements without data (as > there is no data to fill them). > > This could be a temporary solution: > > [% IF page.total_entries == 1 %] > [% FOREACH items IN somedata %] > [% INCLUDE dataform.tmpl %] > [% END %] > [% ELSE %] > [% FOREACH items IN page.page_data %] > [% INCLUDE dataform.tmpl %] > [% END %] > [% END %] > > but I don't like this way > > Best, > Miklos >
What's the value of somedata? ¿Can you email a complete example? Thanks
On Wed May 11 12:04:39 2011, explorer@joaquinferrero.com wrote: Show quoted text
> El Vie Ene 26 14:30:06 2007, szel.miklos@rivendel.hu escribió:
> > An error occurs when there are only one item on a page, instead of > > showing the one correctly, it displays many elements without data (as > > there is no data to fill them). > > > > This could be a temporary solution: > > > > [% IF page.total_entries == 1 %] > > [% FOREACH items IN somedata %] > > [% INCLUDE dataform.tmpl %] > > [% END %] > > [% ELSE %] > > [% FOREACH items IN page.page_data %] > > [% INCLUDE dataform.tmpl %] > > [% END %] > > [% END %] > > > > but I don't like this way > > > > Best, > > Miklos > >
> > > What's the value of somedata? > > ¿Can you email a complete example? > > Thanks
I think this is due to a bug in Data::Paginated module, I have submitted a patch which you can have a look here: https://rt.cpan.org/Ticket/Display.html?id=71470 I hope this helps. Best Regards, Mohammad S Anwar