FIX When on a high page and searching for a small result, list was not

visible.
This commit is contained in:
Laurent Destailleur
2018-04-24 11:37:57 +02:00
parent fcf91b6c8c
commit 461ae46cc4
65 changed files with 352 additions and 55 deletions

View File

@@ -102,6 +102,12 @@ if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
{
$result = $db->query($sql);
$nbtotalofrecords = $db->num_rows($result);
if (($page * $limit) > $nbtotalofrecords) // if total resultset is smaller then paging size (filtering), goto and load page 0
{
$page = 0;
$offset = 0;
}
}
$sql.= $db->plimit($limit + 1, $offset);