From 1ac4a2050c8076eb96e07e83721ebc9db864db94 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 28 Apr 2024 14:47:21 +0200 Subject: Adding upstream version 0.3.3. Signed-off-by: Daniel Baumann --- library/Toplevelview/Monitoring/Servicestatus.php | 38 +++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 library/Toplevelview/Monitoring/Servicestatus.php (limited to 'library/Toplevelview/Monitoring/Servicestatus.php') diff --git a/library/Toplevelview/Monitoring/Servicestatus.php b/library/Toplevelview/Monitoring/Servicestatus.php new file mode 100644 index 0000000..e43572f --- /dev/null +++ b/library/Toplevelview/Monitoring/Servicestatus.php @@ -0,0 +1,38 @@ + */ + +namespace Icinga\Module\Toplevelview\Monitoring; + +use Icinga\Data\ConnectionInterface; +use Icinga\Module\Monitoring\Backend\MonitoringBackend; +use Icinga\Module\Monitoring\DataView\Servicestatus as IcingaServiceStatus; + +class Servicestatus extends IcingaServiceStatus +{ + /** @noinspection PhpMissingParentConstructorInspection */ + /** + * @param ConnectionInterface $connection + * @param array|null $columns + * @noinspection PhpMissingParentConstructorInspection + */ + public function __construct(ConnectionInterface $connection, array $columns = null, $options = null) + { + /** @var MonitoringBackend $connection */ + $this->connection = $connection; + $this->query = new ServicestatusQuery($connection->getResource(), $columns, $options); + } + + /** + * {@inheritdoc} + */ + public function getColumns() + { + return array_merge( + parent::getColumns(), + array( + //'service_in_notification_period', + 'service_notification_period', + ) + ); + } +} -- cgit v1.2.3