IcingaUserForm: add display_name

fixes #11395
This commit is contained in:
Thomas Gelf 2016-03-16 12:31:23 +01:00
parent 5b8dcc44db
commit 61f6bae374
1 changed files with 18 additions and 0 deletions

View File

@ -39,6 +39,7 @@ class IcingaUserForm extends DirectorObjectForm
$this->addGroupsElement()
->addImportsElement()
->addDisplayNameElement()
->addEnableNotificationsElement()
->addDisabledElement()
->addEventFilterElements()
@ -79,6 +80,23 @@ class IcingaUserForm extends DirectorObjectForm
return $this;
}
protected function addDisplayNameElement()
{
if ($this->isTemplate()) {
return $this;
}
$this->addElement('text', 'display_name', array(
'label' => $this->translate('Display name'),
'description' => $this->translate(
'Alternative name for this user. In case your object name is a'
. ' username, this could be the full name of the corresponding person'
)
));
return $this;
}
protected function groupObjectDefinition()
{
$elements = array(