Commit 2fe891f7 authored by Côme Chilliet's avatar Côme Chilliet
Browse files

Fixes #4343 Allowing underscores in departments names

parent df3f4eac
...@@ -64,9 +64,10 @@ class department extends simplePlugin ...@@ -64,9 +64,10 @@ class department extends simplePlugin
'name' => _('Properties'), 'name' => _('Properties'),
'attrs' => array( 'attrs' => array(
new BaseSelectorAttribute(''), new BaseSelectorAttribute(''),
new HostNameAttribute( new StringAttribute(
sprintf(_('Name of %s'), $name), sprintf(_('A name for this %s'), $name), sprintf(_('Name of %s'), $name), sprintf(_('A name for this %s'), $name),
$namingAttr, TRUE $namingAttr, TRUE,
'', '', '/^[a-z0-9\._-]+$/i'
), ),
new TextAreaAttribute( new TextAreaAttribute(
_('Description'), sprintf(_('Short description of this %s'), $name), _('Description'), sprintf(_('Short description of this %s'), $name),
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment