mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-30 17:24:16 +02:00
parent
cd1ee3e306
commit
61565543ab
@ -6,9 +6,20 @@ namespace Icinga\Module\Monitoring\DataView;
|
|||||||
class Downtime extends DataView
|
class Downtime extends DataView
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Retrieve columns provided by this view
|
* {@inheritdoc}
|
||||||
*
|
*/
|
||||||
* @return array
|
public function isValidFilterTarget($column)
|
||||||
|
{
|
||||||
|
if ($column[0] === '_'
|
||||||
|
&& preg_match('/^_(?:host|service)_/', $column)
|
||||||
|
) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return parent::isValidFilterTarget($column);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
public function getColumns()
|
public function getColumns()
|
||||||
{
|
{
|
||||||
@ -37,6 +48,17 @@ class Downtime extends DataView
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritdoc}
|
||||||
|
*/
|
||||||
|
public function getFilterColumns()
|
||||||
|
{
|
||||||
|
return array('hostgroup', 'hostgroup_alias', 'hostgroup_name', 'servicegroup', 'servicegroup_alias', 'servicegroup_name');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritdoc}
|
||||||
|
*/
|
||||||
public function getSortRules()
|
public function getSortRules()
|
||||||
{
|
{
|
||||||
return array(
|
return array(
|
||||||
@ -66,9 +88,4 @@ class Downtime extends DataView
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getFilterColumns()
|
|
||||||
{
|
|
||||||
return array('author', 'host', 'service', 'service_host');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user