You are here

function search_api_sorts_help in Search API sorts 8

Same name and namespace in other branches
  1. 7 search_api_sorts.module \search_api_sorts_help()

Implements hook_help().

File

./search_api_sorts.module, line 16
Create sort options for search queries executed via the Search API.

Code

function search_api_sorts_help($route_name, RouteMatchInterface $route_match) {
  switch ($route_name) {
    case 'entity.search_api_index.sorts':
      return t('Select the display you would like to manage sort fields for. A display is one instance where this index can be shown, e.g. a views page using this index.');
    case 'search_api_sorts.search_api_display.sorts':
      return t('Select the indexed fields for which you want to enable sorting for this display. Before the sort blocks is actually displayed, you will have to enable and configure it at the <a href=":url">block administration page</a>.', [
        ':url' => Url::fromRoute('block.admin_display')
          ->toString(),
      ]);
  }
  return NULL;
}