RoleForm: Provide share restrictions for users and groups

refs #5600
This commit is contained in:
Johannes Meyer 2015-09-16 16:24:29 +02:00
parent 99502a77e0
commit 0cff2ca545

View File

@ -28,7 +28,7 @@ class RoleForm extends ConfigForm
*
* @var array
*/
protected $providedRestrictions = array();
protected $providedRestrictions;
/**
* {@inheritdoc}
@ -71,8 +71,22 @@ class RoleForm extends ConfigForm
*/
);
$helper = new Zend_Form_Element('bogus');
$this->providedRestrictions = array(
$helper->filterName('application/share/users') => array(
'name' => 'application/share/users',
'description' => $this->translate(
'Restrict which users this role can share items and information with'
)
),
$helper->filterName('application/share/groups') => array(
'name' => 'application/share/groups',
'description' => $this->translate(
'Restrict which groups this role can share items and information with'
)
)
);
$mm = Icinga::app()->getModuleManager();
foreach ($mm->listInstalledModules() as $moduleName) {
$modulePermission = $mm::MODULE_PERMISSION_NS . $moduleName;