diff --git a/pandora_console/godmode/agentes/module_manager_editor_common.php b/pandora_console/godmode/agentes/module_manager_editor_common.php index 2adab81340..2b3526dde0 100644 --- a/pandora_console/godmode/agentes/module_manager_editor_common.php +++ b/pandora_console/godmode/agentes/module_manager_editor_common.php @@ -1270,14 +1270,14 @@ $(document).ready (function () { window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Operacion&printable=yes#Tipos_de_m.C3.B3dulos', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } else{ window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Operations&printable=yes#Types_of_Modules', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } @@ -1290,14 +1290,14 @@ $(document).ready (function () { window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Monitorizacion_remota&printable=yes#Monitorizaci.C3.B3n_ICMP', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } else{ window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Remote_Monitoring&printable=yes#ICMP_Monitoring', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } @@ -1312,14 +1312,14 @@ $(document).ready (function () { window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Monitorizacion_remota&printable=yes#Monitorizando_con_m.C3.B3dulos_de_red_tipo_SNMP', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } else{ window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Remote_Monitoring&printable=yes#Monitoring_by_Network_Modules_with_SNMP', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } @@ -1334,14 +1334,14 @@ $(document).ready (function () { window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Monitorizacion_remota&printable=yes#Monitorizaci.C3.B3n_TCP', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } else{ window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Remote_Monitoring&printable=yes#TCP_Monitoring', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } @@ -1356,14 +1356,14 @@ $(document).ready (function () { window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Monitorizacion_web&printable=yes#Creaci.C3.B3n_de_m.C3.B3dulos_web', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } else{ window.open( 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Web_Monitoring&printable=yes#Creating_Web_Modules', '_blank', - "width=800,height=400" + 'width=800,height=600' ); } diff --git a/pandora_console/godmode/modules/manage_network_components.php b/pandora_console/godmode/modules/manage_network_components.php index 1ed916749e..82cd02d771 100644 --- a/pandora_console/godmode/modules/manage_network_components.php +++ b/pandora_console/godmode/modules/manage_network_components.php @@ -46,11 +46,22 @@ if (defined('METACONSOLE')) { */ + $id_modulo = (int) get_parameter('id_component_type'); + $new_component = (bool) get_parameter('new_component'); + if ($id_modulo == 2 || $id_modulo == 4 || $id_modulo == 6) { + $help_header = 'local_module_tab'; + } else if (!$new_component) { + $help_header = 'network_component_tab'; + } else { + $help_header = 'network_component_tab'; + } + + ui_print_page_header( __('Module management').' » '.__('Network component management'), '', false, - 'network_component_tab', + $help_header, true, '', false, @@ -90,7 +101,6 @@ if (!empty($macros)) { $max_timeout = (int) get_parameter('max_timeout'); $max_retries = (int) get_parameter('max_retries'); -$id_modulo = (int) get_parameter('id_component_type'); $id_plugin = (int) get_parameter('id_plugin'); $dynamic_interval = (int) get_parameter('dynamic_interval'); $dynamic_max = (int) get_parameter('dynamic_max'); @@ -150,7 +160,6 @@ $disabled_types_event = json_encode($disabled_types_event); $create_component = (bool) get_parameter('create_component'); $update_component = (bool) get_parameter('update_component'); $delete_component = (bool) get_parameter('delete_component'); -$new_component = (bool) get_parameter('new_component'); $duplicate_network_component = (bool) get_parameter('duplicate_network_component'); $delete_multiple = (bool) get_parameter('delete_multiple'); $multiple_delete = (bool) get_parameter('multiple_delete', 0); diff --git a/pandora_console/godmode/modules/manage_network_components_form_common.php b/pandora_console/godmode/modules/manage_network_components_form_common.php index 7b33a0a275..0d52a01377 100644 --- a/pandora_console/godmode/modules/manage_network_components_form_common.php +++ b/pandora_console/godmode/modules/manage_network_components_form_common.php @@ -72,7 +72,7 @@ if (enterprise_installed()) { } } -$table->data[1][0] = __('Type').' '.ui_print_help_icon('module_type', true); +$table->data[1][0] = __('Type').' '.ui_print_help_icon($help_type, true, '', 'images/help_green.png', '', 'module_type_help'); $sql = sprintf( 'SELECT id_tipo, descripcion FROM ttipo_modulo @@ -396,6 +396,124 @@ $next_row++; var type_names = jQuery.parseJSON(Base64.decode($('#hidden-type_names').val())); var type_name_selected = type_names[type_selected]; + console.log(type_name_selected); + var element = document.getElementById("module_type_help"); + var language = "" ; + element.onclick = function (event) { + if(type_name_selected == 'async_data' || + type_name_selected == 'async_proc' || + type_name_selected == 'async_string' || + type_name_selected == 'generic_proc'|| + type_name_selected == 'generic_data' || + type_name_selected == 'generic_data_inc' || + type_name_selected == 'generic_data_inc_abs'|| + type_name_selected == 'generic_data_string' || + type_name_selected == 'keep_alive' + ){ + if (language == 'es'){ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Operacion&printable=yes#Tipos_de_m.C3.B3dulos', + '_blank', + 'width=800,height=600' + ); + } + else{ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Operations&printable=yes#Types_of_Modules', + '_blank', + 'width=800,height=600' + ); + } + + + } + if(type_name_selected == 'remote_icmp' || + type_name_selected == 'remote_icmp_proc' + ){ + if(language == 'es'){ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Monitorizacion_remota&printable=yes#Monitorizaci.C3.B3n_ICMP', + '_blank', + 'width=800,height=600' + ); + } + else{ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Remote_Monitoring&printable=yes#ICMP_Monitoring', + '_blank', + 'width=800,height=600' + ); + } + + + } + if(type_name_selected == 'remote_snmp_string' || + type_name_selected == 'remote_snmp_proc' || + type_name_selected == 'remote_snmp_inc' || + type_name_selected == 'remote_snmp' + ){ + if(language == 'es'){ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Monitorizacion_remota&printable=yes#Monitorizando_con_m.C3.B3dulos_de_red_tipo_SNMP', + '_blank', + 'width=800,height=600' + ); + } + else{ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Remote_Monitoring&printable=yes#Monitoring_by_Network_Modules_with_SNMP', + '_blank', + 'width=800,height=600' + ); + } + + + } + if(type_name_selected == 'remote_tcp_string' || + type_name_selected == 'remote_tcp_proc' || + type_name_selected == 'remote_tcp_inc' || + type_name_selected == 'remote_tcp' + ){ + if(language == 'es'){ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Monitorizacion_remota&printable=yes#Monitorizaci.C3.B3n_TCP', + '_blank', + 'width=800,height=600' + ); + } + else{ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Remote_Monitoring&printable=yes#TCP_Monitoring', + '_blank', + 'width=800,height=600' + ); + } + + + } + if(type_name_selected == 'web_data' || + type_name_selected == 'web_proc' || + type_name_selected == 'web_content_data' || + type_name_selected == 'web_content_string' + ){ + if(language == 'es'){ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_es:Monitorizacion_web&printable=yes#Creaci.C3.B3n_de_m.C3.B3dulos_web', + '_blank', + 'width=800,height=600' + ); + } + else{ + window.open( + 'https://wiki.pandorafms.com/index.php?title=Pandora:Documentation_en:Web_Monitoring&printable=yes#Creating_Web_Modules', + '_blank', + 'width=800,height=600' + ); + } + + + } + } if (type_name_selected.match(/_string$/) == null) { // Numeric types diff --git a/pandora_console/godmode/modules/manage_network_components_form_wmi.php b/pandora_console/godmode/modules/manage_network_components_form_wmi.php index f88441f5d5..09681b34c8 100755 --- a/pandora_console/godmode/modules/manage_network_components_form_wmi.php +++ b/pandora_console/godmode/modules/manage_network_components_form_wmi.php @@ -28,7 +28,7 @@ if (! check_acl($config['id_user'], 0, 'PM')) { require_once $config['homedir'].'/include/functions_modules.php'; $data = []; -$data[0] = __('WMI query'); +$data[0] = __('WMI query').' '.ui_print_help_icon('wmi_query_tab', true); $data[1] = html_print_input_text('snmp_oid', $snmp_oid, '', 25, 255, true); $data[2] = __('Key string').' '.ui_print_help_icon('wmikey', true, ui_get_full_url(false, false, false, false)); $data[3] = html_print_input_text('snmp_community', $snmp_community, '', 25, 255, true); diff --git a/pandora_console/include/functions.php b/pandora_console/include/functions.php index aa40b91262..56b98e317d 100644 --- a/pandora_console/include/functions.php +++ b/pandora_console/include/functions.php @@ -3945,8 +3945,7 @@ function mask2cidr($mask) function get_help_info($section_name) { global $config; - hd($section_name); - + // hd($section_name); $user_language = get_user_language($id_user); $es = false; @@ -3957,14 +3956,6 @@ function get_help_info($section_name) } switch ($section_name) { - case 'action_threshold': - if ($es) { - $result .= ''; - } else { - $result .= ''; - } - break; - case 'tactical_view': if ($es) { $result .= 'Presentacion_datos/visualizacion&printable=yes#Vista_t.C3.A1ctica'; @@ -4061,14 +4052,6 @@ function get_help_info($section_name) } break; - case 'ad_advanced_permision': - - break; - - case 'agent_access': - - break; - case 'agent_status': if ($es) { $result .= 'Presentacion_datos/visualizacion&printable=yes#Detalles_del_agente'; @@ -4085,41 +4068,6 @@ function get_help_info($section_name) } break; - case 'agent_module_tab': - if ($es) { - $result = 3866; - $result['section'][] = 'Par.C3.A1metros_comunes'; - $result['section'][] = 'Monitorizaci.C3.B3n_de_estados'; - } else { - $result = 3867; - $result['section'][] = 'Common_Parameters'; - $result['section'][] = 'Status_Monitoring'; - } - break; - - case 'agent_wux_console': - // XXX - if ($es) { - $result = ''; - $result['section'][] = ''; - } else { - $result = ''; - $result['section'][] = ''; - } - break; - - case 'aggregate_by': - - break; - - case 'alert_action': - - break; - - case 'alert_command': - - break; - case 'alert_config': if ($es) { $result .= 'Alertas&printable=yes#Creaci.C3.B3n_de_una_Acci.C3.B3n'; @@ -4128,14 +4076,6 @@ function get_help_info($section_name) } break; - case 'alert_fields_description': - - break; - - case 'alert_fields_values': - - break; - case 'alert_macros': if ($es) { $result .= 'Alertas&printable=yes#Macros_sustituibles_en_los_campos_Field1.2C_Field2.2C_Field3..._Field10'; @@ -4144,14 +4084,6 @@ function get_help_info($section_name) } break; - case 'alert-matches': - // XXX - break; - - case 'alert_recovery': - - break; - case 'alerts_config': if ($es) { $result .= 'Alertas&printable=yes#Configuraci.C3.B3n_de_alertas_en_Pandora_FMS'; @@ -4192,10 +4124,6 @@ function get_help_info($section_name) } break; - case 'conf_alert_template': - - break; - case 'configure_gis_map': if ($es) { $result .= 'Pandora_GIS&printable=yes#Introducci.C3.B3n'; @@ -4212,34 +4140,6 @@ function get_help_info($section_name) } break; - case 'context_module_unknow': - - break; - - case 'context_pandora_server_email': - // XXX Aparece al principio de la pagina - break; - - case 'create_agent': - - break; - - case 'custom_logo_collapsed': - - break; - - case 'custom_logo': - - break; - - case 'date_format': - - break; - - case 'duplicateconfig': - - break; - case 'event_alert': if ($es) { $result .= 'Eventos&printable=yes#Introducci.C3.B3n_2'; @@ -4248,14 +4148,6 @@ function get_help_info($section_name) } break; - case 'events_history': - - break; - - case 'events_replication': - - break; - case 'eventview': if ($es) { $result .= 'Eventos&printable=yes#Introducci.C3.B3n'; @@ -4280,14 +4172,6 @@ function get_help_info($section_name) } break; - case 'field_match_snmp': - - break; - - case 'gis_map_builder': - - break; - case 'gis_tab': if ($es) { $result .= 'Pandora_GIS&printable=yes#Configuraci.C3.B3n_del_Agent_GIS'; @@ -4320,14 +4204,6 @@ function get_help_info($section_name) } break; - case 'graphs': - - break; - - case 'graph_view': - - break; - case 'history_database': if ($es) { $result .= 'Configuracion_Consola&printable=yes#Base_de_datos_hist.C3.B3rica'; @@ -4336,10 +4212,6 @@ function get_help_info($section_name) } break; - case 'integria_url': - - break; - case 'inventory_tab': if ($es) { $result .= 'Inventario&printable=yes#M.C3.B3dulos_de_inventario'; @@ -4348,17 +4220,6 @@ function get_help_info($section_name) } break; - case 'info_agent': - if ($es) { - $result = 3866; - $result['section'][] = 'Visualizaci.C3.B3n_del_agente'; - } else { - $result = 3867; - $result['section'][] = 'Agent_configuration_in_the_console_2'; - } - break; - - case 'ipam_create_tab': case 'ipam_list_tab': if ($es) { $result .= 'IPAM&printable=yes#Introducci.C3.B3n'; @@ -4449,26 +4310,6 @@ function get_help_info($section_name) } break; - case 'ip_api_list': - - break; - - case 'linked_map_weight': - - break; - - case 'local_component': - - break; - - case 'log_viewer': - - break; - - case 'macros': - - break; - case 'macros_visual_maps': if ($es) { $result .= 'Presentacion_datos/Mapas_visuales&printable=yes#Macros_en_las_consolas_visuales'; @@ -4485,10 +4326,6 @@ function get_help_info($section_name) } break; - case 'main_help': - - break; - case 'main_tab': if ($es) { $result .= 'Intro_Monitorizacion&printable=yes#Configuraci.C3.B3n_del_agente_en_consola'; @@ -4513,14 +4350,6 @@ function get_help_info($section_name) } break; - case 'manage_alerts': - - break; - - case 'manageconfig': - - break; - case 'map_builder_intro': if ($es) { $result .= 'Presentacion_datos/Mapas_visuales&printable=yes#Introducci.C3.B3n'; @@ -4553,14 +4382,6 @@ function get_help_info($section_name) } break; - case 'meta_access': - - break; - - case 'metaconsole_agent_cache': - - break; - case 'module_linking': if ($es) { $result .= 'Politicas&printable=yes#Tipos_de_m.C3.B3dulos'; @@ -4569,14 +4390,6 @@ function get_help_info($section_name) } break; - case 'module_tokens': - - break; - - case 'network_component': - - break; - case 'network_map_enterprise_edit': if ($es) { $result .= 'Presentacion_datos/Mapas_de_red&printable=yes#Mapa_de_red_no_vac.C3.ADo'; @@ -4617,14 +4430,6 @@ function get_help_info($section_name) } break; - case 'no_hierarchy': - - break; - - case 'operation_visual_console': - - break; - case 'pcap_filter': if ($es) { $result .= 'Netflow&printable=yes#Creaci.C3.B3n_del_filtro'; @@ -4633,10 +4438,6 @@ function get_help_info($section_name) } break; - case 'performance': - - break; - case 'planned_downtime': if ($es) { $result .= 'Gestion_y_Administracion&printable=yes#Creaci.C3.B3n_parada_planificada'; @@ -4669,10 +4470,6 @@ function get_help_info($section_name) } break; - case 'plugin_parameters': - - break; - case 'plugin_policy': if ($es) { $result .= 'Politicas&printable=yes#Plugins_de_agente'; @@ -4681,10 +4478,6 @@ function get_help_info($section_name) } break; - case 'policy_agent': - - break; - case 'policy_queue': if ($es) { $result .= 'Politicas&printable=yes#Gesti.C3.B3n_de_la_cola_de_pol.C3.ADticas'; @@ -4693,10 +4486,6 @@ function get_help_info($section_name) } break; - case 'prediction_date': - - break; - case 'prediction_source_module': if ($es) { $result .= 'Monitorizacion_otra&printable=yes#Tipos_de_monitorizaci.C3.B3n_predictiva'; @@ -4713,26 +4502,6 @@ function get_help_info($section_name) } break; - case 'profile': - - break; - - case 'projection_graph': - - break; - - case 'propagate_acl': - - break; - - case 'reconscript_definition': - - break; - - case 'recontask': - - break; - case 'template_reporting_tab': if ($es) { $result .= 'Presentacion_datos/Informes&printable=yes#Introducci.C3.B3n'; @@ -4797,14 +4566,6 @@ function get_help_info($section_name) } break; - case 'reporting_preview_tab': - // XXX - break; - - case 'reporting_time_lapse': - // XXX - break; - case 'reporting_wizard_sla_tab': if ($es) { $result .= 'Presentacion_datos/Informes&printable=yes#Wizard_SLA'; @@ -4821,10 +4582,6 @@ function get_help_info($section_name) } break; - case 'reports_label_field': - // XXX - break; - case 'response_macros': if ($es) { $result .= 'Eventos&printable=yes#Event_Responses_macros'; @@ -4841,10 +4598,6 @@ function get_help_info($section_name) } break; - case 'serverlag': - - break; - case 'servers': if ($es) { $result .= 'Interfaz&printable=yes#Gesti.C3.B3n_de_servidores'; @@ -4853,102 +4606,6 @@ function get_help_info($section_name) } break; - case 'service_elements_management': - - break; - - case 'service_management_edit': - - break; - - case 'services_management': - - break; - - case 'setup_gis_index': - - break; - - case 'snmp_alert_configuration': - - break; - - case 'snmp_alert_custom': - - break; - - case 'snmp_alert_field1': - - break; - - case 'snmp_alert_filters': - - break; - - case 'snmp_alert': - - break; - - case 'snmp_alert_position': - - break; - - case 'snmpcommunity': - - break; - - case 'snmp_explorer': - - break; - - case 'snmp_explorer_tab': - if ($es) { - $result = 3840; - $result['section'][] = 'Wizard_SNMP'; - } else { - $result = 3841; - $result['section'][] = 'SNMP_Wizard'; - } - break; - - case 'snmp_interfaces_explorer_tab': - if ($es) { - $result = 3840; - $result['section'][] = 'SNMP_Interfaces_wizard'; - } else { - $result = 3841; - $result['section'][] = 'SNMP_Interface_Wizard'; - } - break; - - case 'snmp_interfaces_explorer_tab': - if ($es) { - $result = 3840; - $result['section'][] = 'SNMP_Interfaces_wizard'; - } else { - $result = 3841; - $result['section'][] = 'SNMP_Interface_Wizard'; - } - break; - - case 'wmi_explorer_tab': - if ($es) { - $result = 3840; - $result['section'][] = 'Wizard_WMI'; - } else { - $result = 3841; - $result['section'][] = 'WMI_Wizard'; - } - break; - - case 'snmpoid': - - break; - - case 'snmp_trap_types': - - break; - case 'snmpwalk': if ($es) { $result .= 'Monitorizacion_remota&printable=yes#Navegador_SNMP_de_Pandora_FMS'; @@ -4965,18 +4622,6 @@ function get_help_info($section_name) } break; - case 'tcp_send': - - break; - - case 'timesource': - - break; - - case 'time_st-comparation': - - break; - case 'transactional_map_phases': if ($es) { $result .= 'Monitorizacion_transaccional&printable=yes#Creaci.C3.B3n_del_.C3.A1rbol_de_fases'; @@ -5009,10 +4654,6 @@ function get_help_info($section_name) } break; - case 'view_services_detail': - - break; - case 'view_services': if ($es) { $result .= 'Servicios&printable=yes#Introducci.C3.B3n'; @@ -5519,7 +5160,7 @@ function get_help_info($section_name) case 'local_module': if ($es) { - $result .= 'Documentation_es:Operacion&printable=yes#Tipos_de_m.C3.B3dulos'; + $result .= 'Operacion&printable=yes#Tipos_de_m.C3.B3dulos'; } else { $result .= 'Operations&printable=yes#Types_of_Modules'; } @@ -5597,27 +5238,23 @@ function get_help_info($section_name) } break; - case 'web_checks': - + case 'wmi_query_tab': + if ($es) { + $result .= 'Monitorizacion_remota&printable=yes#Monitorizaci.C3.B3n_de_Windows_remotos_con_WMI'; + } else { + $result .= 'Remote_Monitoring&printable=yes#Windows_Remote_Monitoring_with_WMI'; + } break; - case 'wmifield': - - break; - - case 'wmikey': - - break; - - case 'wmiquery': - - break; - - default: - + case 'module_type_tab': + if ($es) { + $result .= 'Operacion&printable=yes#Tipos_de_m.C3.B3dulos'; + } else { + $result .= ''; + } break; } - hd($result); + // hd($result); return $result; }