check if 'facetsearch' is set

This commit is contained in:
Uwe Steinmann 2023-04-23 19:02:57 +02:00
parent c9b31d8de9
commit 36a51e9606

View File

@ -69,6 +69,7 @@ if (isset($_GET["removecategory"]) && is_numeric($_GET["removecategory"]) && $_G
$terms = [];
$limit = (isset($_GET["limit"]) && is_numeric($_GET["limit"])) ? (int) $_GET['limit'] : 20;
$fullsearch = ((!isset($_GET["fullsearch"]) && $settings->_defaultSearchMethod == 'fulltext') || !empty($_GET["fullsearch"])) && $settings->_enableFullSearch;
$facetsearch = !empty($_GET["facetsearch"]) && $settings->_enableFullSearch;
if($fullsearch) {
// Search in Fulltext {{{
if (isset($_GET["query"]) && is_string($_GET["query"])) {
@ -634,6 +635,7 @@ if($settings->_showSingleSearchHit && count($entries) == 1) {
$view->setParam('totaldocs', $dcount /*resArr['totalDocs']*/);
$view->setParam('totalfolders', $fcount /*resArr['totalFolders']*/);
$view->setParam('fullsearch', $fullsearch);
$view->setParam('facetsearch', $facetsearch);
$view->setParam('mode', isset($mode) ? $mode : '');
$view->setParam('orderby', isset($orderby) ? $orderby : '');
$view->setParam('defaultsearchmethod', !empty($_GET["fullsearch"]) || $settings->_defaultSearchMethod);