Skip to content
Snippets Groups Projects
Commit 636b7910 authored by Dorian Merz's avatar Dorian Merz
Browse files

refs #18775 [fid_bbi] optimize performance

* avoid rendering of sub-template if unnecessary
parent 5432d9c7
No related merge requests found
<!-- fid_bbi - templates - search - advanced-search-info -->
<?php
// Following section adaption from themes/finc/templates/search/results.phtml
$searchType = $this->params->getSearchType();
$searchId = $this->results->getSearchId();
$searchClassId = $this->params->getSearchClassId();
$lookfor = $this->results->getUrlQuery()->isQuerySuppressed() ? '' : $this->params->getDisplayQuery();
......@@ -18,7 +18,6 @@ $options = $this->searchOptions($this->searchClassId);
$advSearch = $options->getAdvancedSearchAction();
?>
<?php if ($searchType == 'advanced'): ?>
<div class="results_advanced-search-info">
<?=$this->icon('small/magnifier')?>
......@@ -35,5 +34,5 @@ $advSearch = $options->getAdvancedSearchAction();
</a>
</p>
</div>
<?php endif; ?>
<!-- fid_bbi - templates - search - advanced-search-info - END -->
......@@ -64,8 +64,9 @@ $this->headScript()->appendFile("check_save_statuses.js");
<?=$this->flashmessages()?>
<div class="results_header">
<?=$this->render('search/advanced-search-info.phtml');?>
<?php if ($this->params->getSearchType() === 'advanced'):?>
<?=$this->render('search/advanced-search-info.phtml');?>
<?php endif; ?>
<div class="results_count">
<?=$this->translate('%%count%% results', ['%%count%%' => $this->localizedNumber($recordTotal)])?>
</div>
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment