diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 49463676fd..0491381178 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,8 @@ +2013-11-21 Sergio Martin + + * include/functions_events.php: Fix the combo of user to assign an + event to one of them. Incident #409 + 2013-11-21 Sergio Martin * godmode/modules/manage_network_components_form.php: Fixed jquery diff --git a/pandora_console/include/functions_events.php b/pandora_console/include/functions_events.php index b0e823e5c8..e731e5a27b 100644 --- a/pandora_console/include/functions_events.php +++ b/pandora_console/include/functions_events.php @@ -1644,8 +1644,12 @@ function events_page_responses ($event) { // Owner $data = array(); $data[0] = __('Change owner'); - - $users = groups_get_users(array_keys(users_get_groups(false, "EM", false))); + // Owner change can be done to users that belong to the event group with ER permission + $profiles_view_events = db_get_all_rows_filter('tperfil', array('event_view' => '1'), 'id_perfil'); + foreach($profiles_view_events as $k => $v) { + $profiles_view_events[$k] = reset($v); + } + $users = groups_get_users($event['id_grupo'], array('id_perfil' => $profiles_view_events), true); foreach($users as $u) { $owners[$u['id_user']] = $u['fullname'];