mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-31 01:35:36 +02:00
Fixed the form to search modules in an agent. TICKET: #3071
This commit is contained in:
parent
655150a7ae
commit
96f77c7595
@ -190,12 +190,16 @@ if ($create_agent) {
|
|||||||
$id_agente = db_process_sql_insert ('tagente',
|
$id_agente = db_process_sql_insert ('tagente',
|
||||||
array ('nombre' => $nombre_agente,
|
array ('nombre' => $nombre_agente,
|
||||||
'direccion' => $direccion_agente,
|
'direccion' => $direccion_agente,
|
||||||
'id_grupo' => $grupo, 'intervalo' => $intervalo,
|
'id_grupo' => $grupo,
|
||||||
'comentarios' => $comentarios, 'modo' => $modo,
|
'intervalo' => $intervalo,
|
||||||
'id_os' => $id_os, 'disabled' => $disabled,
|
'comentarios' => $comentarios,
|
||||||
|
'modo' => $modo,
|
||||||
|
'id_os' => $id_os,
|
||||||
|
'disabled' => $disabled,
|
||||||
'cascade_protection' => $cascade_protection,
|
'cascade_protection' => $cascade_protection,
|
||||||
'server_name' => $server_name,
|
'server_name' => $server_name,
|
||||||
'id_parent' => $id_parent, 'custom_id' => $custom_id,
|
'id_parent' => $id_parent,
|
||||||
|
'custom_id' => $custom_id,
|
||||||
'icon_path' => $icon_path,
|
'icon_path' => $icon_path,
|
||||||
'update_gis_data' => $update_gis_data,
|
'update_gis_data' => $update_gis_data,
|
||||||
'url_address' => $url_description,
|
'url_address' => $url_description,
|
||||||
@ -736,11 +740,11 @@ if ($update_agent) { // if modified some agent paramenter
|
|||||||
'url_address' => $url_description,
|
'url_address' => $url_description,
|
||||||
'url_address' => $url_description,
|
'url_address' => $url_description,
|
||||||
'quiet' => $quiet);
|
'quiet' => $quiet);
|
||||||
|
|
||||||
if ($config['metaconsole_agent_cache'] == 1) {
|
if ($config['metaconsole_agent_cache'] == 1) {
|
||||||
$values['update_module_count'] = 1; // Force an update of the agent cache.
|
$values['update_module_count'] = 1; // Force an update of the agent cache.
|
||||||
}
|
}
|
||||||
|
|
||||||
$result = db_process_sql_update ('tagente', $values, array ('id_agente' => $id_agente));
|
$result = db_process_sql_update ('tagente', $values, array ('id_agente' => $id_agente));
|
||||||
if ($result === false) {
|
if ($result === false) {
|
||||||
ui_print_error_message(
|
ui_print_error_message(
|
||||||
@ -838,7 +842,7 @@ if ($update_module || $create_module) {
|
|||||||
// Don't read as (float) because it lost it's decimals when put into MySQL
|
// Don't read as (float) because it lost it's decimals when put into MySQL
|
||||||
// where are very big and PHP uses scientific notation, p.e:
|
// where are very big and PHP uses scientific notation, p.e:
|
||||||
// 1.23E-10 is 0.000000000123
|
// 1.23E-10 is 0.000000000123
|
||||||
|
|
||||||
$post_process = (string) get_parameter ('post_process', 0.0);
|
$post_process = (string) get_parameter ('post_process', 0.0);
|
||||||
//$prediction_module = 0;
|
//$prediction_module = 0;
|
||||||
|
|
||||||
@ -1594,7 +1598,7 @@ switch ($tab) {
|
|||||||
// Control the tab and subtab hover. When mouse leave one,
|
// Control the tab and subtab hover. When mouse leave one,
|
||||||
// check if is hover the other before hide the subtab
|
// check if is hover the other before hide the subtab
|
||||||
$('.agent_wizard_tab').hover(agent_wizard_tab_show, agent_wizard_tab_hide);
|
$('.agent_wizard_tab').hover(agent_wizard_tab_show, agent_wizard_tab_hide);
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// Set the position and width of the subtab
|
// Set the position and width of the subtab
|
||||||
|
@ -99,6 +99,8 @@ if (!isset($policy_page))
|
|||||||
|
|
||||||
$show_creation = false;
|
$show_creation = false;
|
||||||
|
|
||||||
|
echo "</form>";
|
||||||
|
|
||||||
if (($policy_page) || (isset($agent))) {
|
if (($policy_page) || (isset($agent))) {
|
||||||
if ($policy_page) {
|
if ($policy_page) {
|
||||||
$show_creation = true;
|
$show_creation = true;
|
||||||
@ -110,7 +112,7 @@ if (($policy_page) || (isset($agent))) {
|
|||||||
|
|
||||||
if ($show_creation) {
|
if ($show_creation) {
|
||||||
// Create module/type combo
|
// Create module/type combo
|
||||||
//echo '<form id="create_module_type" method="post" action="'.$url.'">';
|
echo '<form id="create_module_type" method="post" action="'.$url.'">';
|
||||||
echo '<td class="datos" style="font-weight: bold;">';
|
echo '<td class="datos" style="font-weight: bold;">';
|
||||||
echo __("Type");
|
echo __("Type");
|
||||||
html_print_select ($modules, 'moduletype', '', '', '', '', false, false, false, '', false, 'max-width:300px;' );
|
html_print_select ($modules, 'moduletype', '', '', '', '', false, false, false, '', false, 'max-width:300px;' );
|
||||||
@ -120,12 +122,12 @@ if (($policy_page) || (isset($agent))) {
|
|||||||
echo '<input align="right" name="updbutton" type="submit" class="sub next" value="'.__('Create').'">';
|
echo '<input align="right" name="updbutton" type="submit" class="sub next" value="'.__('Create').'">';
|
||||||
echo '</td>';
|
echo '</td>';
|
||||||
echo '</tr>';
|
echo '</tr>';
|
||||||
//echo "</form>";
|
echo "</form>";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
echo "</table>";
|
echo "</table>";
|
||||||
echo "</form>";
|
|
||||||
|
|
||||||
echo '<div style="text-align: right; width: 100%;padding-top:10px;padding-bottom:10px">';
|
echo '<div style="text-align: right; width: 100%;padding-top:10px;padding-bottom:10px">';
|
||||||
echo "<strong>";
|
echo "<strong>";
|
||||||
|
@ -61,7 +61,7 @@ foreach ($reports as $report) {
|
|||||||
$data[2] = '<a href="index.php?sec=reporting&sec2=operation/reporting/reporting_viewer&id='.$report['id_report'].'">' .
|
$data[2] = '<a href="index.php?sec=reporting&sec2=operation/reporting/reporting_viewer&id='.$report['id_report'].'">' .
|
||||||
html_print_image("images/reporting.png", true) . '</a>';
|
html_print_image("images/reporting.png", true) . '</a>';
|
||||||
$data[3] = '<a href="ajax.php?page=operation/reporting/reporting_xml&id='.$report['id_report'].'">' . html_print_image("images/database_lightning.png", true) . '</a>'; //I chose ajax.php because it's supposed to give XML anyway
|
$data[3] = '<a href="ajax.php?page=operation/reporting/reporting_xml&id='.$report['id_report'].'">' . html_print_image("images/database_lightning.png", true) . '</a>'; //I chose ajax.php because it's supposed to give XML anyway
|
||||||
|
|
||||||
enterprise_hook ('load_custom_reporting_2');
|
enterprise_hook ('load_custom_reporting_2');
|
||||||
array_push ($table->data, $data);
|
array_push ($table->data, $data);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user