DataView\Statussummary: Adjust how to handle filter columns

refs #9029
This commit is contained in:
Johannes Meyer 2015-08-17 14:07:07 +02:00
parent e20f78bba9
commit b061161979
1 changed files with 2 additions and 18 deletions

View File

@ -6,9 +6,7 @@ namespace Icinga\Module\Monitoring\DataView;
class StatusSummary extends DataView
{
/**
* Retrieve columns provided by this view
*
* @return array
* {@inheritdoc}
*/
public function getColumns()
{
@ -100,7 +98,7 @@ class StatusSummary extends DataView
/**
* {@inheritdoc}
*/
public function getFilterColumns()
public function getStaticFilterColumns()
{
return array(
'host', 'host_alias', 'host_display_name', 'host_name',
@ -109,18 +107,4 @@ class StatusSummary extends DataView
'servicegroup', 'servicegroup_alias', 'servicegroup_name'
);
}
/**
* {@inheritdoc}
*/
public function isValidFilterTarget($column)
{
if ($column[0] === '_'
&& preg_match('/^_(?:host|service)_/', $column)
) {
return true;
} else {
return in_array($column, $this->getFilterColumns());
}
}
}