From 6bb5b93a7f685bcfde1cbca2e254212f3409bc9f Mon Sep 17 00:00:00 2001 From: Daniel Maya Date: Wed, 29 Jun 2016 10:41:34 +0200 Subject: [PATCH] show unknown and not init modules. Ticket #3844. (cherry picked from commit e4cdef363e5c647f3270ae13d2e9acd808db5b89) --- pandora_console/godmode/massive/massive_delete_modules.php | 2 +- pandora_console/godmode/massive/massive_edit_modules.php | 2 +- pandora_console/operation/agentes/ver_agente.php | 2 ++ 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/pandora_console/godmode/massive/massive_delete_modules.php b/pandora_console/godmode/massive/massive_delete_modules.php index 2411d286e0..74fbbeb357 100755 --- a/pandora_console/godmode/massive/massive_delete_modules.php +++ b/pandora_console/godmode/massive/massive_delete_modules.php @@ -486,7 +486,7 @@ $table->data['form_agents_3'][1] = html_print_select ($agents, 'id_agents[]', $agents_id, false, '', '', true, true, false, '', false, 'width:100%'); $table->data['form_agents_3'][2] = __('When select agents'); $table->data['form_agents_3'][2] .= '
'; -$table->data['form_agents_3'][2] .= html_print_select (array('common' => __('Show common modules'), 'all' => __('Show all modules')), 'modules_selection_mode', +$table->data['form_agents_3'][2] .= html_print_select (array('common' => __('Show common modules'), 'all' => __('Show all modules'),'unknown' => __('Show unknown and not init modules')), 'modules_selection_mode', 'common', false, '', '', true); $table->data['form_agents_3'][3] = html_print_select (array(), 'module[]', $modules_select, false, '', '', true, true, false, '', false, 'width:100%'); diff --git a/pandora_console/godmode/massive/massive_edit_modules.php b/pandora_console/godmode/massive/massive_edit_modules.php index 903f800f33..880e8b43b8 100755 --- a/pandora_console/godmode/massive/massive_edit_modules.php +++ b/pandora_console/godmode/massive/massive_edit_modules.php @@ -333,7 +333,7 @@ $table->data['form_agents_3'][2] = __('When select agents'); $table->data['form_agents_3'][2] .= '
'; $table->data['form_agents_3'][2] .= html_print_select ( array('common' => __('Show common modules'), - 'all' => __('Show all modules')), + 'all' => __('Show all modules'),'unknown' => __('Show unknown and not init modules')), 'modules_selection_mode', 'common', false, '', '', true); $table->data['form_agents_3'][3] = html_print_select (array(), 'module[]', diff --git a/pandora_console/operation/agentes/ver_agente.php b/pandora_console/operation/agentes/ver_agente.php index a9ffbdf50f..1a85ac9364 100644 --- a/pandora_console/operation/agentes/ver_agente.php +++ b/pandora_console/operation/agentes/ver_agente.php @@ -395,6 +395,8 @@ if (is_ajax ()) { WHERE t2.delete_pending = 0 AND t1.nombre = t2.nombre AND t2.id_agente IN (' . implode(',', $idAgents) . ')) = (' . count($idAgents) . ')'; + }elseif ($selection_mode == 'unknown'){ + $sql .= 'AND t1.id_agente_modulo IN (SELECT id_agente_modulo FROM tagente_estado where estado = 3 OR estado = 4)'; } $sql .= ' ORDER BY nombre';