function facetapi_get_available_sorts in Facet API 6.3
Same name and namespace in other branches
- 7.2 facetapi.admin.inc \facetapi_get_available_sorts()
- 7 facetapi.admin.inc \facetapi_get_available_sorts()
Returns the sorts available to the facet.
All sorts are checked against their requirmenets. Only sorts that pass all requirements are returned by this function.
Parameters
array $realm: The realm definition.
array $facet: The facet definition.
Return value
array An array of available sorts plugins.
1 call to facetapi_get_available_sorts()
- facetapi_facet_display_form in ./
facetapi.admin.inc - Form constructor for the facet display settings form.
File
- ./
facetapi.admin.inc, line 357 - Admin page callbacks for the Facet API module.
Code
function facetapi_get_available_sorts(array $realm, array $facet) {
$sort_info = array();
foreach (facetapi_get_sort_info() as $name => $info) {
if (!$info['requirements'] || facetapi_check_requirements($info['requirements'], $realm, $facet)) {
$sort_info[$name] = $info;
}
}
return $sort_info;
}