if (!
empty($criteria->sortings
)) { $this->
addSortings($criteria,
$search);
} return $search;
} protected function fetch(Search
$search) { $arguments =
[ 'index' =>
$this->indexFactory->
createIndexConfiguration($this->domainName
)->
getAlias(),
'type' =>
$this->domainName,
'body' =>
$search->
toArray(),
'rest_total_hits_as_int' => true,
'track_total_hits' => true,
];
return $this->client->
search($arguments);
} /**
* @return SearcherResult
*/