IsMainLocation Sort Clause¶
Location\IsMainLocation Sort Clause
sorts search results by whether their Location is the main Location of the Content item.
Locations that are not main Locations are ranked as lower values (e.g. with ascending order they will be returned first).
sortDirection(optional) - Query or LocationQuery constant, either
$query = new LocationQuery(); $query->sortClauses = [new SortClause\Location\InMainLocation()];