From e4e1d981a5ee21b12e25174412f5e6f0a29ac9f6 Mon Sep 17 00:00:00 2001 From: raviks789 Date: Thu, 24 Oct 2024 13:40:12 +0200 Subject: [PATCH] Set empty state message for affected object list --- library/Icingadb/Widget/Detail/ObjectDetail.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/library/Icingadb/Widget/Detail/ObjectDetail.php b/library/Icingadb/Widget/Detail/ObjectDetail.php index 8160dcaa3..b2a6deaee 100644 --- a/library/Icingadb/Widget/Detail/ObjectDetail.php +++ b/library/Icingadb/Widget/Detail/ObjectDetail.php @@ -704,7 +704,10 @@ protected function createAffectedObjects(): ?array return [ HtmlElement::create('h2', null, Text::create(t('Affected Objects'))), - new DependencyNodeList($affectedObjects) + (new DependencyNodeList($affectedObjects)) + ->setEmptyStateMessage( + t("You are not authorized to view the affected dependent objects of this object.") + ) ]; } }