function cck_select_other_handler_filter::admin_summary in CCK Select Other 7.2
Same name and namespace in other branches
- 7 views/cck_select_other_handler_filter.inc \cck_select_other_handler_filter::admin_summary()
Display the filter on the administrative summary.
Overrides views_handler_filter_in_operator::admin_summary
File
- views/
cck_select_other_handler_filter.inc, line 160
Class
- cck_select_other_handler_filter
- Extends Views in operator filter.
Code
function admin_summary() {
if (!empty($this->options['exposed'])) {
return t('exposed');
}
$info = $this
->operators();
$this
->get_value_options();
if (!is_array($this->value)) {
return;
}
$operator = check_plain($info[$this->operator]['short']);
$values = '';
$count = count($this->value);
$i = 1;
foreach ($this->value as $value) {
if (isset($this->value_options[$value])) {
$values .= check_plain($this->value_options[$value]);
}
else {
$values .= t('%value', array(
'%value' => $value,
));
}
if ($i < $count) {
$values .= ', ';
}
$i++;
}
return $operator . ($values !== '' ? ' (' . $values . ')' : '');
}