When editing a user or group's preferences, limit app selection to just those apps the account has access to.

This commit is contained in:
Nathan Gray 2013-09-17 16:26:45 +00:00
parent 407efdbcaf
commit f60e402eb0

View File

@ -429,6 +429,10 @@ class preferences_settings
{
$content['type'] .= ':'.$id;
$sel_options['type'][$content['type']] = common::grab_owner_name($GLOBALS['egw']->preferences->account_id);
// Restrict app list to apps the user has access to
$user_apps = $GLOBALS['egw']->acl->get_user_applications($id);
$sel_options['appname'] = array_intersect_key($sel_options['appname'], $user_apps);
}
foreach($GLOBALS['egw']->accounts->search(array('type' => 'groups', 'sort' => 'account_lid')) as $account_id => $group)
{