From a0901c4b7f2db488cb4fb3be2dd921a0308f4659 Mon Sep 17 00:00:00 2001
From: Daniel Baumann <daniel.baumann@progress-linux.org>
Date: Sun, 28 Apr 2024 14:36:40 +0200
Subject: Adding upstream version 1.0.2.

Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
---
 library/Icingadb/Widget/ItemList/UsergroupList.php | 29 ++++++++++++++++++++++
 1 file changed, 29 insertions(+)
 create mode 100644 library/Icingadb/Widget/ItemList/UsergroupList.php

(limited to 'library/Icingadb/Widget/ItemList/UsergroupList.php')

diff --git a/library/Icingadb/Widget/ItemList/UsergroupList.php b/library/Icingadb/Widget/ItemList/UsergroupList.php
new file mode 100644
index 0000000..2e95368
--- /dev/null
+++ b/library/Icingadb/Widget/ItemList/UsergroupList.php
@@ -0,0 +1,29 @@
+<?php
+
+/* Icinga DB Web | (c) 2020 Icinga GmbH | GPLv2 */
+
+namespace Icinga\Module\Icingadb\Widget\ItemList;
+
+use Icinga\Module\Icingadb\Common\NoSubjectLink;
+use Icinga\Module\Icingadb\Common\BaseItemList;
+use ipl\Web\Url;
+
+class UsergroupList extends BaseItemList
+{
+    use NoSubjectLink;
+
+    protected $defaultAttributes = ['class' => 'usergroup-list item-table'];
+
+    protected function init()
+    {
+        parent::init();
+
+        $this->getAttributes()->get('class')->removeValue('item-list');
+        $this->setDetailUrl(Url::fromPath('icingadb/usergroup'));
+    }
+
+    protected function getItemClass(): string
+    {
+        return UsergroupListItem::class;
+    }
+}
-- 
cgit v1.2.3