mirror of
				https://git.code.sf.net/p/seeddms/code
				synced 2025-10-30 20:51:22 +00:00 
			
		
		
		
	keep paginator even if all hits are shown
This commit is contained in:
		
							parent
							
								
									4b69739b51
								
							
						
					
					
						commit
						f2c8718586
					
				|  | @ -97,7 +97,7 @@ if($fullsearch) { | |||
| 		if (is_numeric($_GET["pg"]) && $_GET["pg"]>0) { | ||||
| 			$pageNumber = (integer)$_GET["pg"]; | ||||
| 		} | ||||
| 		else if (!strcasecmp($_GET["pg"], "all")) { | ||||
| 		elseif (!strcasecmp($_GET["pg"], "all")) { | ||||
| 			$pageNumber = "all"; | ||||
| 		} | ||||
| 	} | ||||
|  | @ -218,7 +218,7 @@ if($fullsearch) { | |||
| 						$dcount = isset($facets['record_type']['document']) ? $facets['record_type']['document'] : 0 ; | ||||
| 					} | ||||
| 				} | ||||
| 				if($pageNumber != 'all' && $searchresult['count'] > $limit) { | ||||
| 				if(/* $pageNumber != 'all' && */$searchresult['count'] > $limit) { | ||||
| 					$totalPages = (int) ($searchresult['count']/$limit); | ||||
| 					if($searchresult['count']%$limit) | ||||
| 						$totalPages++; | ||||
|  | @ -527,10 +527,11 @@ if($fullsearch) { | |||
| 		} | ||||
| 	} | ||||
| 	$totalPages = 1; | ||||
| 	if ((!isset($_GET['action']) || $_GET['action'] != 'export') && (!isset($_GET["pg"]) || strcasecmp($_GET["pg"], "all"))) { | ||||
| 	if ((!isset($_GET['action']) || $_GET['action'] != 'export') /*&& (!isset($_GET["pg"]) || strcasecmp($_GET["pg"], "all"))*/) { | ||||
| 		$totalPages = (int) (count($entries)/$limit); | ||||
| 		if(count($entries)%$limit) | ||||
| 			$totalPages++; | ||||
| 		if($pageNumber != 'all') | ||||
| 			$entries = array_slice($entries, ($pageNumber-1)*$limit, $limit); | ||||
| 	} else | ||||
| 		$totalPages = 1; | ||||
|  |  | |||
|  | @ -936,7 +936,7 @@ function typeahead() { /* {{{ */ | |||
| 			} | ||||
| 			 */ | ||||
| 			echo $this->infoMsg(getMLText("search_report", array("count"=>$total, "doccount" => $totaldocs, "foldercount" => $totalfolders, 'searchtime'=>$searchTime))); | ||||
| 			$this->pageList($pageNumber, $totalpages, "../out/out.Search.php", $urlparams); | ||||
| 			$this->pageList((int) $pageNumber, $totalpages, "../out/out.Search.php", $urlparams); | ||||
| //			$this->contentContainerStart();
 | ||||
| 
 | ||||
| 			$txt = $this->callHook('searchListHeader', $orderby, 'asc'); | ||||
|  | @ -1048,7 +1048,7 @@ function typeahead() { /* {{{ */ | |||
| 			} | ||||
| 			print "</tbody></table>\n"; | ||||
| //			$this->contentContainerEnd();
 | ||||
| 			$this->pageList($pageNumber, $totalpages, "../out/out.Search.php", $_GET); | ||||
| 			$this->pageList((int) $pageNumber, $totalpages, "../out/out.Search.php", $_GET); | ||||
| 		} else { | ||||
| 			$numResults = $totaldocs + $totalfolders; | ||||
| 			if ($numResults == 0) { | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Uwe Steinmann
						Uwe Steinmann