fixed minor errors in WUX

This commit is contained in:
daniel 2017-09-04 12:09:19 +02:00
parent d74a3f74b4
commit f0862e1c5b
2 changed files with 16 additions and 7 deletions

View File

@ -741,10 +741,15 @@ foreach ($modules as $module) {
$data[6] = ui_print_status_image($status, $title, true); $data[6] = ui_print_status_image($status, $title, true);
// MAX / MIN values // MAX / MIN values
if($module['id_tipo_modulo'] != 25){
$data[7] = ui_print_module_warn_value ($module["max_warning"], $data[7] = ui_print_module_warn_value ($module["max_warning"],
$module["min_warning"], $module["str_warning"], $module["min_warning"], $module["str_warning"],
$module["max_critical"], $module["min_critical"], $module["max_critical"], $module["min_critical"],
$module["str_critical"]); $module["str_critical"]);
}
else{
$data[7] = "";
}
if ($module['disabled']) { if ($module['disabled']) {
$data[8] = "<a href='index.php?sec=gagente&tab=module&sec2=godmode/agentes/configurar_agente&id_agente=".$id_agente."&enable_module=".$module['id_agente_modulo']."'>". $data[8] = "<a href='index.php?sec=gagente&tab=module&sec2=godmode/agentes/configurar_agente&id_agente=".$id_agente."&enable_module=".$module['id_agente_modulo']."'>".
@ -757,7 +762,7 @@ foreach ($modules as $module) {
array('alt' => __('Disable module'), 'title' => __('Disable module'))) ."</a>"; array('alt' => __('Disable module'), 'title' => __('Disable module'))) ."</a>";
} }
if (check_acl ($config['id_user'], $agent['id_grupo'], "AW")) { if (check_acl ($config['id_user'], $agent['id_grupo'], "AW") && $module['id_tipo_modulo'] != 25) {
$data[8] .= '&nbsp;<a href="index.php?sec=gagente&tab=module&sec2=godmode/agentes/configurar_agente&id_agente='.$id_agente.'&duplicate_module='.$module['id_agente_modulo'].'" $data[8] .= '&nbsp;<a href="index.php?sec=gagente&tab=module&sec2=godmode/agentes/configurar_agente&id_agente='.$id_agente.'&duplicate_module='.$module['id_agente_modulo'].'"
onClick="if (!confirm(\' ' . __('Are you sure?') . '\')) return false;">'; onClick="if (!confirm(\' ' . __('Are you sure?') . '\')) return false;">';
$data[8] .= html_print_image ('images/copy.png', true, $data[8] .= html_print_image ('images/copy.png', true,

View File

@ -1012,8 +1012,12 @@ if ($list_modules) {
$module["current_interval"], $module["module_name"]); $module["current_interval"], $module["module_name"]);
} }
} }
if($module["id_tipo_modulo"] != 25){
$data[6] = ui_print_module_warn_value ($module["max_warning"], $module["min_warning"], $module["str_warning"], $module["max_critical"], $module["min_critical"], $module["str_critical"]); $data[6] = ui_print_module_warn_value ($module["max_warning"], $module["min_warning"], $module["str_warning"], $module["max_critical"], $module["min_critical"], $module["str_critical"]);
}
else{
$data[6] = "";
}
$data[7] = $salida; $data[7] = $salida;
$graph_type = return_graphtype ($module["id_tipo_modulo"]); $graph_type = return_graphtype ($module["id_tipo_modulo"]);