You are here

function SarniaViewsHandlerFilter::ui_name in Sarnia 7

Provide a custom UI name for the field based on the Solr property.

Overrides views_handler::ui_name

File

handlers/handler_filter.inc, line 87

Class

SarniaViewsHandlerFilter
Really basic filter handler for filtering Solr documents in Views.

Code

function ui_name($short = FALSE) {
  if (!empty($this->options['ui_name'])) {
    $title = check_plain($this->options['ui_name']);
    return $title;
  }
  $title = $short && isset($this->definition['title short']) ? $this->definition['title short'] : $this->definition['title'];
  $title .= ': ' . $this->options['solr_property'];
  if (!$short) {
    $title = $this->definition['group'] . ': ' . $title;
  }
  return $title;
}