'; echo '
'.__('Refresh').'
'; echo html_print_select( [ '30' => __('30 seconds'), (string) SECONDS_1MINUTE => __('1 minute'), '180' => __('3 minute'), (string) SECONDS_5MINUTES => __('5 minutes'), ], 'refresh', $refresh, '', '', 0, true, false, false, '', false, 'margin-top: 3px;' ); echo ''.__('Search').'
'; echo html_print_input_text('search', $search, '', 30, 255, true); echo ''.__('Type').'
'; echo html_print_select( [ 0 => __('Group agents'), 1 => __('Group modules by tag'), 2 => __('Group modules by module group'), ], 'type', $type, '', '', 0, true, false, false, '', false, 'margin-top: 3px;width:70%' ); echo ''.__('Show groups').'
'; echo html_print_checkbox('group', 1, $group, true); echo ''.__('Group').'
'; echo html_print_input( [ 'type' => 'select_groups', 'returnAllGroup' => true, 'name' => 'filter[]', 'selected' => $filter, 'return' => true, 'required' => true, 'privilege' => 'AR', ] ); break; case 1: echo ''.__('Tag').'
'; if (tags_has_user_acl_tags($config['id_user']) === false) { echo html_print_select_from_sql( 'SELECT id_tag, name FROM ttag WHERE id_tag ORDER BY name', 'filter[]', $filter, '', '', '', true, true, false, false, 'width: 200px', '5' ); } else { $user_tags = tags_get_user_tags($config['id_user'], 'AR'); if (!empty($user_tags)) { $id_user_tags = array_keys($user_tags); echo html_print_select_from_sql( 'SELECT id_tag, name FROM ttag WHERE id_tag IN ('.implode(',', $id_user_tags).') ORDER BY name', 'filter[]', $filter, '', '', '', true, true, false, false, 'width: 200px', '5' ); } else { echo html_print_select_from_sql( 'SELECT id_tag, name FROM ttag WHERE id_tag ORDER BY name', 'filter[]', $filter, '', '', '', true, true, false, false, 'width: 200px', '5' ); } } break; case 2: $module_groups = modules_get_modulegroups(); // $module_groups[0] = _('Not assigned'); // hd(current($filter)); echo ''.__('Module group').'
'; echo html_print_select( $module_groups, 'filter[]', $filter, '', _('Not assigned'), 0, true, false, false, '', false, 'width: 70%', false, false, false, '', true ); break; } echo ''.__('Module name').'
'; echo ''.$data['nombre'].''; echo ''.__('Description').'
'; echo ''.$data['descripcion'].'
'; echo ''.__('Agent').'
'; echo ''.agents_get_alias($data['id_agente']).''; echo ''.__('Group').'
'; echo ''.modules_get_modulegroup_name($data['id_module_group']).'
'; echo ''.__('Module name').'
'; echo ''.$data['nombre'].''; echo ''.__('Description').'
'; echo ''.$data['descripcion'].'
'; echo ''.__('Agent').'
'; echo ''.agents_get_alias($data['id_agente']).''; echo ''.__('Group').'
'; echo ''.modules_get_modulegroup_name($data['id_module_group']).'
'; echo ''.__('Tag').'
'; foreach ($tags as $key => $tag) { $tags_name .= tags_get_name($tag['id_tag']).', '; } $tags_name = trim($tags_name, ', '); echo ''.$tags_name.'
'; echo ''.__('Agent').'
'; echo ''.$data['alias'].''; echo ''.__('IP').'
'; echo ''.$data['direccion'].'
'; echo ''.__('OS').'
'; echo ''.ui_print_os_icon($data['id_os'], true, true).'
'; echo ''.__('Description').'
'; echo ''.$data['comentarios'].'
'; echo ''.__('Group').'
'; echo ''.groups_get_name($data['id_grupo']).'
'; echo '