From f66ab8dae2f3d0418759f81a3a64dc9517a62449 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 14 Apr 2024 15:17:31 +0200 Subject: Adding upstream version 1.10.2. Signed-off-by: Daniel Baumann --- application/forms/IcingaUserGroupForm.php | 47 +++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 application/forms/IcingaUserGroupForm.php (limited to 'application/forms/IcingaUserGroupForm.php') diff --git a/application/forms/IcingaUserGroupForm.php b/application/forms/IcingaUserGroupForm.php new file mode 100644 index 0000000..d9706b4 --- /dev/null +++ b/application/forms/IcingaUserGroupForm.php @@ -0,0 +1,47 @@ +addHidden('object_type', 'object'); + + $this->addElement('text', 'object_name', array( + 'label' => $this->translate('Usergroup'), + 'required' => true, + 'description' => $this->translate('Icinga object name for this user group') + )); + + $this->addGroupDisplayNameElement() + ->addZoneElements() + ->groupMainProperties() + ->setButtons(); + } + + /** + * @return $this + * @throws \Zend_Form_Exception + */ + protected function addZoneElements() + { + $this->addZoneElement(true); + $this->addDisplayGroup(['zone_id'], 'clustering', [ + 'decorators' => [ + 'FormElements', + ['HtmlTag', ['tag' => 'dl']], + 'Fieldset', + ], + 'order' => self::GROUP_ORDER_CLUSTERING, + 'legend' => $this->translate('Zone settings') + ]); + + return $this; + } +} -- cgit v1.2.3