Page size bug while filtering

All ApPHP DataGrid script bugs discussion. Questions and requests here.
Please, use a $debug_mode = true; before you say "Why Nothing Works ?!" (solves 90% of all issues)

Moderator: alexandrleonenko

steffen
Newbie
Newbie
Posts: 7
Joined: Feb 18th, '13, 18:36

Page size bug while filtering

Postby steffen » Feb 21st, '13, 13:47

When I press the reset button in filter view, I always get 10 records back, instead of the page size I specified (100). I am using the latest version.

administrator
Site Admin
Site Admin
Posts: 6010
Joined: Jan 7th, '09, 23:18
Contact:

Re: Page size bug while filtering

Postby administrator » Feb 24th, '13, 07:52

Please show us this issue only + turn on debug mode.
It's to hard to understand what exactly happens from this explanation only.

steffen
Newbie
Newbie
Posts: 7
Joined: Feb 18th, '13, 18:36

Re: Page size bug while filtering

Postby steffen » Feb 25th, '13, 18:58

Please see attached picture.

Using a default page size of 100 (SetPagingSettings), but get only 10 results back after "Reset" in search (filter) view.
Attachments
datagrid.jpg
datagrid.jpg (224.02 KiB) Viewed 3085 times

administrator
Site Admin
Site Admin
Posts: 6010
Joined: Jan 7th, '09, 23:18
Contact:

Re: Page size bug while filtering

Postby administrator » Feb 26th, '13, 08:19

Unfortunately, we cannot reproduce this issue on our server.
Can you show us this issue on your own site or check it on LIVE DEMO:
http://www.apphp.com/php-datagrid/index ... e=examples

steffen
Newbie
Newbie
Posts: 7
Joined: Feb 18th, '13, 18:36

Re: Page size bug while filtering

Postby steffen » Feb 26th, '13, 09:12

I can reproduce it, at least with "code_1_2_example.php". Here is what I did:

1. change "$default_page_size" in your example to "100"
2. Press "Search" Button
3. Press "Reset"

You will get only 10 records back...

administrator
Site Admin
Site Admin
Posts: 6010
Joined: Jan 7th, '09, 23:18
Contact:

Re: Page size bug while filtering

Postby administrator » Feb 26th, '13, 09:23

The Grid is not saves the selected page size and when you click on Reset button it returns to the default page size.
Try to change default page size in your code, when you define pagination settings.

steffen
Newbie
Newbie
Posts: 7
Joined: Feb 18th, '13, 18:36

Re: Page size bug while filtering

Postby steffen » Feb 26th, '13, 09:44

The default page size is 100, see below:

## *** set paging settings
$bottom_paging = array("results"=>true, "results_align"=>"left", "pages"=>true, "pages_align"=>"center", "page_size"=>true, "page_size_align"=>"right");
$top_paging = array();
$pages_array = array("10"=>"10", "25"=>"25", "50"=>"50", "100"=>"100", "250"=>"250", "500"=>"500", "1000"=>"1000");
$default_page_size = 100;
$dgrid->SetPagingSettings($bottom_paging, $top_paging, $pages_array, $default_page_size);

administrator
Site Admin
Site Admin
Posts: 6010
Joined: Jan 7th, '09, 23:18
Contact:

Re: Page size bug while filtering

Postby administrator » Feb 27th, '13, 08:55

What version you work with? Did you try it on the last v7.7.7?
Please show us this issue online.

steffen
Newbie
Newbie
Posts: 7
Joined: Feb 18th, '13, 18:36

Re: Page size bug while filtering

Postby steffen » Feb 27th, '13, 10:09

PM sent!

daav
Junior
Junior
Posts: 16
Joined: May 8th, '09, 23:17
Location: san francisco, ca usa

Re: Page size bug while filtering

Postby daav » Oct 16th, '13, 19:40

I'm using v7.7.7 and have the same problem. How can I fix this ?

Can you suggest a modification I can make in the datagrid.class.php?


Return to “ApPHP DataGrid {bugs}”