filter_search_start.inc in Commerce Search API 7
FacetApiFilter, remove items that should not appear on empty search.
File
includes/facetapi/filter_search_start.incView source
<?php
/**
* @file
* FacetApiFilter, remove items that should not appear on empty search.
*/
/**
* Filter out items should not appear on empty search.
*/
class CommerceSearchApiSearchStart extends FacetapiFilter {
/**
* Returns an empty array.
*/
public function execute(array $build) {
if (!count($this->adapter
->getAllActiveItems())) {
return array();
}
return $build;
}
}
Classes
Name | Description |
---|---|
CommerceSearchApiSearchStart | Filter out items should not appear on empty search. |