2006-03-27 05:37:27 +02:00
|
|
|
<?php
|
2006-07-19 20:29:12 +02:00
|
|
|
|
2009-06-08 20:21:21 +02:00
|
|
|
// Pandora FMS - http://pandorafms.com
|
|
|
|
// ==================================================
|
2010-07-23 12:04:12 +02:00
|
|
|
// Copyright (c) 2005-2010 Artica Soluciones Tecnologicas
|
2009-06-08 20:21:21 +02:00
|
|
|
// Please see http://pandorafms.org for full contribution list
|
2008-07-30 20:39:40 +02:00
|
|
|
|
2006-06-29 21:31:53 +02:00
|
|
|
// This program is free software; you can redistribute it and/or
|
|
|
|
// modify it under the terms of the GNU General Public License
|
2008-08-22 20:07:32 +02:00
|
|
|
// as published by the Free Software Foundation for version 2.
|
2006-06-29 21:31:53 +02:00
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
// GNU General Public License for more details.
|
2009-06-08 20:21:21 +02:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2006-07-19 20:29:12 +02:00
|
|
|
// Load global vars
|
2008-07-16 23:04:31 +02:00
|
|
|
check_login ();
|
2008-06-16 20:09:56 +02:00
|
|
|
|
2011-02-27 Miguel de Dios <miguel.dedios@artica.es>
* extensions/users_connected.php: fixed the double negation in the
check_acl.
* include/functions_events.php, include/functions_modules.php,
include/functions_reporting.php, include/functions_filemanager.php,
include/functions_config.php, include/ajax/reporting.ajax.php,
include/ajax/visual_console_builder.ajax.php,
include/ajax/alert_list.ajax.php, include/help/es/modu_group_list.php,
include/fgraph.php, include/functions.php, include/functions_db.php,
include/functions_alerts.php, include/functions_reports.php,
extensions/insert_data.php, extensions/system_info.php,
extensions/pandora_logs.php, extensions/agents_modules.php,
extensions/dbmanager.php, extensions/resource_registration.php,
extensions/update_manager/settings.php, extensions/update_manager/main.php,
extensions/plugin_registration.php, operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/incidents/incident_statistics.php, operation/extensions.php,
operation/visual_console/render_view.php,
operation/visual_console/index.php, operation/agentes/status_monitor.php,
operation/agentes/export_csv.php,
operation/agentes/estado_ultimopaquete.php,
operation/agentes/datos_agente.php, operation/agentes/alerts_status.php,
operation/agentes/estado_generalagente.php,
operation/agentes/custom_fields.php, operation/agentes/estado_agente.php,
operation/agentes/networkmap.topology.php,
operation/agentes/networkmap.groups.php, operation/agentes/sla_view.php,
operation/agentes/exportdata.php, operation/agentes/gis_view.php,
operation/agentes/estado_monitores.php, operation/agentes/ver_agente.php,
operation/agentes/graphs.php, operation/agentes/agent_fields.php,
operation/agentes/group_view.php, operation/agentes/networkmap.php,
operation/servers/view_server.php, operation/servers/view_server_detail.php,
operation/menu.php, operation/snmpconsole/snmp_view.php,
operation/users/user_edit.php, operation/events/event_statistics.php,
operation/events/export_csv.php, operation/events/sound_events.php,
operation/events/events_validate.php, operation/events/events_list.php,
operation/events/events_marquee.php, operation/events/events.php,
operation/search_reports.php, operation/reporting/reporting_xml.php,
operation/reporting/reporting_viewer.php,
operation/reporting/graph_viewer.php, operation/search_maps.php,
mobile/operation/agents/monitor_status.php,
mobile/operation/agents/view_agents.php, mobile/index.php,
general/ui/agents_list.php, godmode/groups/modu_group_list.php,
godmode/groups/configure_group.php, godmode/groups/configure_modu_group.php,
godmode/groups/group_list.php, godmode/admin_access_logs.php,
godmode/extensions.php, godmode/db/db_main.php, godmode/db/db_audit.php,
godmode/db/db_sanity.php, godmode/db/db_refine.php, godmode/db/db_info.php,
godmode/db/db_event.php, godmode/db/db_purge.php,
godmode/agentes/fields_manager.php, godmode/agentes/module_manager.php,
godmode/agentes/modificar_agente.php, godmode/agentes/configurar_agente.php,
godmode/agentes/configure_field.php, godmode/agentes/planned_downtime.php,
godmode/agentes/manage_config_remote.php, godmode/servers/recon_script.php,
godmode/servers/plugin.php, godmode/servers/manage_recontask.php,
godmode/servers/modificar_server.php,
godmode/servers/manage_recontask_form.php, godmode/menu.php,
godmode/alerts/alert_list.list.php,
godmode/alerts/configure_alert_compound.php,
godmode/alerts/alert_compounds.php, godmode/alerts/alert_list.php,
godmode/alerts/configure_alert_template.php,
godmode/alerts/alert_templates.php,
godmode/alerts/configure_alert_action.php,
godmode/alerts/configure_alert_command.php,
godmode/alerts/alert_actions.php, godmode/alerts/alert_list.builder.php,
godmode/alerts/alert_commands.php, godmode/snmpconsole/snmp_alert.php,
godmode/snmpconsole/snmp_filters.php, godmode/setup/file_manager.php,
godmode/setup/os.list.php, godmode/setup/news.php,
godmode/setup/gis_step_2.php, godmode/setup/links.php,
godmode/setup/setup.php, godmode/setup/os.php,
godmode/setup/performance.php, godmode/setup/setup_auth.php,
godmode/setup/gis.php, godmode/setup/os.builder.php,
godmode/setup/setup_visuals.php, godmode/users/user_list.php,
godmode/users/configure_user.php, godmode/users/configure_profile.php,
godmode/gis_maps/configure_gis_map.php, godmode/gis_maps/index.php,
godmode/massive/massive_add_alerts.php,
godmode/massive/massive_copy_modules.php,
godmode/massive/massive_delete_agents.php,
godmode/massive/massive_operations.php,
godmode/massive/massive_edit_agents.php,
godmode/massive/massive_delete_action_alerts.php,
godmode/massive/massive_delete_modules.php,
godmode/massive/massive_delete_alerts.php,
godmode/massive/massive_edit_modules.php,
godmode/massive/massive_add_action_alerts.php,
godmode/modules/manage_network_components_form.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/modules/module_list.php,
godmode/modules/manage_network_components_form_common.php,
godmode/modules/manage_network_components_form_network.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_network_components_form_wmi.php,
godmode/modules/manage_network_components.php,
godmode/modules/manage_nc_groups.php,
godmode/reporting/reporting_builder.list_items.php,
godmode/reporting/graph_builder.main.php,
godmode/reporting/visual_console_builder.wizard.php,
godmode/reporting/visual_console_builder.php,
godmode/reporting/reporting_builder.preview.php,
godmode/reporting/reporting_builder.main.php,
godmode/reporting/visual_console_builder.data.php,
godmode/reporting/visual_console_builder.elements.php,
godmode/reporting/graph_builder.php,
godmode/reporting/visual_console_builder.preview.php,
godmode/reporting/graph_builder.graph_editor.php,
godmode/reporting/reporting_builder.php,
godmode/reporting/visual_console_builder.editor.php,
godmode/reporting/reporting_builder.item_editor.php,
godmode/reporting/map_builder.php, godmode/reporting/graphs.php,
godmode/reporting/graph_builder.preview.php: replaced obsolete "give_acl" to
"check_acl" and erased the "give_acl".
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4025 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2011-02-28 13:02:08 +01:00
|
|
|
if (! check_acl ($config['id_user'], 0, "AW")) {
|
* include/functions_graph.php
include/functions_html.php
include/functions_messages.php
include/db/postgresql.php
include/db/mysql.php
include/db/oracle.php
include/functions_reporting.php
include/functions_filemanager.php
include/functions_gis.php
include/auth/ldap.php
include/auth/mysql.php
include/functions_networkmap.php
include/functions_network_components.php
include/ajax/skins.ajax.php
include/ajax/reporting.ajax.php
include/ajax/visual_console_builder.ajax.php
include/ajax/alert_list.ajax.php
include/ajax/module.php
include/functions_config.php
include/functions_api.php
include/help/en/help_timesource.php
include/help/es/help_timesource.php
include/help/ja/help_timesource.php
include/config_process.php
include/functions_ui.php
include/functions_custom_graphs.php
include/fgraph.php
include/functions_incidents.php
include/api.php
include/functions_reports.php
include/functions_ui_renders.php
extensions/insert_data.php
extensions/system_info.php
extensions/extension_uploader.php
extensions/pandora_logs.php
extensions/agents_modules.php
extensions/update_manager.php
extensions/ssh_console.php
extensions/dbmanager.php
extensions/vnc_view.php
extensions/resource_registration.php
extensions/resource_exportation.php
extensions/users_connected.php
extensions/module_groups.php
extensions/update_manager/load_updatemanager.php
extensions/update_manager/lib/libupdate_manager_client.php
extensions/update_manager/lib/libupdate_manager.php
extensions/update_manager/lib/libupdate_manager_components.php
extensions/update_manager/lib/libupdate_manager_updates.php
extensions/update_manager/settings.php
extensions/update_manager/main.php
extensions/plugin_registration.php
operation/incidents/incident.php
operation/incidents/incident_detail.php
operation/incidents/incident_statistics.php
operation/search_modules.php
operation/visual_console/render_view.php
operation/visual_console/index.php
operation/extensions.php
operation/agentes/status_monitor.php
operation/agentes/export_csv.php
operation/agentes/estado_ultimopaquete.php
operation/agentes/datos_agente.php
operation/agentes/alerts_status.php
operation/agentes/estado_generalagente.php
operation/agentes/custom_fields.php
operation/agentes/estado_agente.php
operation/agentes/networkmap.topology.php
operation/agentes/networkmap.groups.php
operation/agentes/sla_view.php
operation/agentes/exportdata.php
operation/agentes/gis_view.php
operation/agentes/estado_monitores.php
operation/agentes/ver_agente.php
operation/agentes/graphs.php
operation/agentes/agent_fields.php
operation/agentes/tactical.php
operation/agentes/group_view.php
operation/agentes/networkmap.php
operation/agentes/stat_win.php
operation/servers/view_server.php
operation/servers/view_server_detail.php
operation/menu.php
operation/search_agents.php
operation/search_graphs.php
operation/snmpconsole/snmp_view.php
operation/users/user_edit.php
operation/gis_maps/render_view.php
operation/gis_maps/ajax.php
operation/integria_incidents/incident.php
operation/integria_incidents/incident_detail.php
operation/integria_incidents/incident_statistics.php
operation/events/event_statistics.php
operation/events/events_rss.php
operation/events/export_csv.php
operation/events/sound_events.php
operation/events/events_validate.php
operation/events/events_list.php
operation/events/events_marquee.php
operation/events/events.php
operation/search_alerts.php
operation/messages/message.php
operation/reporting/reporting_xml.php
operation/reporting/reporting_viewer.php
operation/reporting/graph_viewer.php
operation/search_reports.php
operation/search_maps.php
operation/search_users.php
extras/pandora_diag.php
mobile/operation/agents/monitor_status.php
mobile/operation/agents/view_agents.php
mobile/operation/agents/view_alerts.php
mobile/operation/agents/group_view.php
mobile/operation/events/events.php
mobile/index.php
general/error_authconfig.php
general/links_menu.php
general/logon_ok.php
general/error_dbconfig.php
general/ui/agents_list.php
general/header.php
godmode/groups/modu_group_list.php
godmode/groups/configure_group.php
godmode/groups/configure_modu_group.php
godmode/groups/group_list.php
godmode/admin_access_logs.php
godmode/db/db_main.php
godmode/db/db_audit.php
godmode/db/db_sanity.php
godmode/db/db_refine.php
godmode/db/db_info.php
godmode/db/db_event.php
godmode/db/db_purge.php
godmode/extensions.php
godmode/agentes/agent_template.php
godmode/agentes/module_manager_editor_common.php
godmode/agentes/fields_manager.php
godmode/agentes/agent_conf_gis.php
godmode/agentes/module_manager_editor_prediction.php
godmode/agentes/module_manager.php
godmode/agentes/modificar_agente.php
godmode/agentes/configurar_agente.php
godmode/agentes/configure_field.php
godmode/agentes/module_manager_editor.php
godmode/agentes/planned_downtime.php
godmode/agentes/manage_config_remote.php
godmode/agentes/agent_manager.php
godmode/servers/recon_script.php
godmode/servers/plugin.php
godmode/servers/manage_recontask.php
godmode/servers/modificar_server.php
godmode/servers/manage_recontask_form.php
godmode/alerts/alert_list.list.php
godmode/alerts/configure_alert_compound.php
godmode/alerts/alert_compounds.php
godmode/alerts/alert_list.php
godmode/alerts/configure_alert_template.php
godmode/alerts/alert_templates.php
godmode/alerts/configure_alert_action.php
godmode/alerts/configure_alert_command.php
godmode/alerts/alert_actions.php
godmode/alerts/alert_list.builder.php
godmode/alerts/alert_commands.php
godmode/setup/file_manager.php
godmode/setup/os.list.php
godmode/setup/news.php
godmode/setup/gis_step_2.php
godmode/setup/links.php
godmode/setup/setup.php
godmode/setup/os.php
godmode/setup/performance.php
godmode/setup/setup_auth.php
godmode/setup/gis.php
godmode/setup/os.builder.php
godmode/setup/setup_visuals.php
godmode/snmpconsole/snmp_alert.php
godmode/snmpconsole/snmp_filters.php
godmode/users/user_list.php
godmode/users/configure_profile.php
godmode/gis_maps/configure_gis_map.php
godmode/gis_maps/index.php
godmode/massive/massive_add_alerts.php
godmode/massive/massive_copy_modules.php
godmode/massive/massive_delete_agents.php
godmode/massive/massive_enable_disable_alerts.php
godmode/massive/massive_operations.php
godmode/massive/massive_delete_profiles.php
godmode/massive/massive_edit_agents.php
godmode/massive/massive_delete_action_alerts.php
godmode/massive/massive_delete_modules.php
godmode/massive/massive_add_profiles.php
godmode/massive/massive_delete_alerts.php
godmode/massive/massive_edit_modules.php
godmode/massive/massive_standby_alerts.php
godmode/massive/massive_add_action_alerts.php
godmode/modules/manage_network_components_form.php
godmode/modules/manage_nc_groups_form.php
godmode/modules/manage_network_templates.php
godmode/modules/module_list.php
godmode/modules/manage_network_components_form_common.php
godmode/modules/manage_network_components_form_network.php
godmode/modules/manage_network_templates_form.php
godmode/modules/manage_network_components_form_wmi.php
godmode/modules/manage_network_components.php
godmode/modules/manage_nc_groups.php
godmode/reporting/visual_console_builder.wizard.php
godmode/reporting/graph_builder.main.php
godmode/reporting/reporting_builder.list_items.php
godmode/reporting/visual_console_builder.php
godmode/reporting/reporting_builder.preview.php
godmode/reporting/reporting_builder.main.php
godmode/reporting/visual_console_builder.data.php
godmode/reporting/visual_console_builder.elements.php
godmode/reporting/graph_builder.php
godmode/reporting/visual_console_builder.preview.php
godmode/reporting/graph_builder.graph_editor.php
godmode/reporting/reporting_builder.php
godmode/reporting/visual_console_builder.editor.php
godmode/reporting/reporting_builder.item_editor.php
godmode/reporting/map_builder.php
godmode/reporting/graphs.php
godmode/reporting/graph_builder.preview.php
include/functions_db.php: Added some includes and functions of this code have "db_" prefix.
* include/functions.php: Moved function check_login(), check_acl(),
dame_nombre_pluginid(), get_os_name() from functions_db.php to functions.php.
* include/functions_groups.php: Moved functions get_childrens(), safe_acl_group()
and get_parents(), give_disabled_group(), isAllGroups(), get_group_icon(), get_all_groups(),
get_id_groups_recursive(), get_user_groups_tree_recursive(), get_group_status(),
get_group_name(), get_group_users() from functions_db.php to this code.
* include/functions_profile.php: New library with profile functions. Moved functions
get_profile_name(), get_profiles(), create_user_profile(), delete_user_profile(),
delete_profile() from functions_db.php to this code. Added new parameter in function
get_profile() to retrieve profiles with filter conditions applied.
* include/functions_users.php: New library with users functions. Moved functions
get_users_info(), get_all_model_groups(), get_user_groups(), get_user_groups_tree(),
get_user_first_group(), user_access_to_agent() from funtions_db.php to this code.
* godmode/users/configure_user.php: Changed get_profile_filter() function to get_profile().
* include/functions_agents.php: Moved functions get_group_agents(), get_agent_modules(),
get_agent_module_id(), get_agent_id(), get_agent_name(), get_agent_modules_data_count(),
check_alert_fired(), get_agent_interval(), get_agent_os(), give_agentmodule_flag(),
agent_add_address(), agent_delete_address(), get_agent_address(), get_agent_with_ip(),
get_agent_addresses(), get_agent_status(), delete_agent(), get_agentmodule_group(),
get_agent_group() from functions_db.php to this code.
* include/functions_modules.php: Moved functions get_agentmodule(), get_agentmodule_id(),
get_agentmodule_is_init(), get_agent_modules_count(), get_module_type_name(),
get_module_type_icon(), get_agentmodule_agent(), get_agentmodule_agent_name(),
get_agentmodule_name(), get_agentmodule_type(), get_monitor_downs_in_period(),
get_monitor_last_down_timestamp_in_period(), get_monitors_in_group(),
get_monitors_in_agent(), get_monitors_down(), get_moduletype_name(),
get_moduletype_description(), get_moduletypes(), get_module_interval(), show_icon_type(),
give_modulecategory_name(),
give_agent_id_from_module_id(), get_module_status(), get_agent_module_last_value(),
get_previous_data(), get_agentmodule_modulegroup(), get_modulegroups(),
get_modulegroup_name() from functions_db.php to this code.
* include/functions_alerts.php: Moved functions get_alert_type(), get_agent_alert_fired(),
get_module_alert_fired(), get_alert_fires_in_period(), get_group_alerts(), get_alerts_fired(),
get_alert_last_fire_timestamp_in_period(), get_agentmodule_status(),
get_agentmodule_last_status() from functions_db.php to this code.
* include/functions_exportserver.php: Moved function dame_nombre_servidorexportacion()
from functions_db.php to this code.
* include/functions_events.php: Moved functions get_group_events(), get_agent_events(),
get_module_events() from functions_db.php to this code.
* include/functions_servers.php: Moved functions get_server_name(), show_server_type(),
check_server_status(), server_status() from functions_db.php to this code.
* include/functions_network_profiles.php: Moved function get_networkprofile_name()
from functions_db.php to this code.
* include/functions_visual_map.php: Moved functions get_layoutdata_x(), get_layoutdata_y()
from fucntions_db.php to this code.
* include/functions_io.php: Moved function __() from functions_db.php to this code.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4258 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2011-04-19 20:42:49 +02:00
|
|
|
db_pandora_audit("ACL Violation",
|
2008-08-11 Esteban Sanchez <estebans@artica.es>
* include/functions_db.php: Added __ as an alias of lang_string().
* include/functions_reporting_pdf.php,
include/functions_reporting.php, include/functions.php,
include/functions_visual_map.php, index.php,
operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/incidents/incident_note.php,
operation/incidents/incident_search.php,
operation/incidents/incident_statistics.php,
operation/snmpconsole/snmp_alert.php,
operation/snmpconsole/snmp_view.php, operation/users/user.php,
operation/users/user_edit.php, operation/users/user_statistics.php,
operation/events/event_statistics.php, operation/events/events.php,
operation/visual_console/render_view.php,
operation/visual_console/index.php, operation/extensions.php,
operation/agentes/estado_alertas.php,
operation/agentes/status_monitor.php,
operation/agentes/estado_grupo.php, operation/agentes/export_csv.php,
operation/agentes/datos_agente.php,
operation/agentes/estado_ultimopaquete.php,
operation/agentes/estado_generalagente.php,
operation/agentes/estado_agente.php, operation/agentes/bulbs.php,
operation/agentes/status_events.php, operation/agentes/sla_view.php,
operation/agentes/exportdata.php,
operation/agentes/estado_monitores.php,
operation/agentes/ver_agente.php, operation/agentes/estadisticas.php,
operation/agentes/tactical.php, operation/agentes/networkmap.php,
operation/messages/message.php,
operation/reporting/reporting_viewer.php,
operation/reporting/graph_viewer.php,
operation/reporting/custom_reporting.php,
operation/servers/view_server.php,
operation/servers/view_server_detail.php, operation/menu.php,
reporting/fgraph.php, reporting/stat_win.php, ajax.php,
general/logoff.php, general/pandora_help.php, general/footer.php,
general/noaccess.php, general/logon_failed.php,
general/links_menu.php, general/login_page.php, general/logon_ok.php,
general/header.php, general/main_menu.php,
godmode/groups/configure_group.php, godmode/groups/group_list.php,
godmode/setup/news.php, godmode/setup/links.php,
godmode/setup/setup.php, godmode/users/user_list.php,
godmode/users/configure_user.php, godmode/profiles/profile_list.php,
godmode/admin_access_logs.php, godmode/db/db_info_data.php,
godmode/db/db_main.php, godmode/db/db_audit.php,
godmode/db/db_sanity.php, godmode/db/db_refine.php,
godmode/db/db_info.php, godmode/db/db_event.php,
godmode/db/db_purge.php, godmode/extensions.php,
godmode/agentes/agent_template.php,
godmode/agentes/module_manager_editor_network.php,
godmode/agentes/module_manager_editor_wmi.php,
godmode/agentes/alert_manager.php,
godmode/agentes/module_manager_editor_plugin.php,
godmode/agentes/module_manager_editor_prediction.php,
godmode/agentes/alert_manager_editor.php,
godmode/agentes/manage_config.php,
godmode/agentes/module_manager_editor_data.php,
godmode/agentes/module_manager.php,
godmode/agentes/modificar_agente.php,
godmode/agentes/configurar_agente.php,
godmode/agentes/agent_disk_conf_editor.php,
godmode/agentes/planned_downtime.php,
godmode/agentes/manage_config_remote.php,
godmode/agentes/agent_manager.php,
godmode/modules/manage_network_components_form.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/modules/module_list.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_network_components_form_network.php,
godmode/modules/manage_network_components_form_wmi.php,
godmode/modules/manage_network_components.php,
godmode/modules/manage_nc_groups.php,
godmode/reporting/reporting_builder.php,
godmode/reporting/map_builder.php,
godmode/reporting/graph_builder.php, godmode/servers/plugin.php,
godmode/servers/manage_recontask.php,
godmode/servers/modificar_server.php,
godmode/servers/manage_recontask_form.php,
godmode/alerts/modify_alert.php, godmode/alerts/configure_alert.php,
godmode/menu.php: Replaced $id_user with $config['id_user']. Use __a
instead of $lang_label to future use of gettext. Style
corrections.
* godmode/agentes/planned_downtime.php: Rewritten to use Pandora
functions and adopt the UI style. Replaced lang_string with __().
* pandoradb.sql: Fields in tplanned_downtime renamed to fit
guidelines.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1005 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-08-11 12:59:07 +02:00
|
|
|
"Trying to access Agent Config Management Admin section");
|
|
|
|
require ("general/noaccess.php");
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
require_once ('include/functions_agents.php');
|
|
|
|
require_once ('include/functions_alerts.php');
|
|
|
|
require_once ('include/functions_modules.php');
|
* include/functions_graph.php
include/functions_html.php
include/functions_messages.php
include/db/postgresql.php
include/db/mysql.php
include/db/oracle.php
include/functions_reporting.php
include/functions_filemanager.php
include/functions_gis.php
include/auth/ldap.php
include/auth/mysql.php
include/functions_networkmap.php
include/functions_network_components.php
include/ajax/skins.ajax.php
include/ajax/reporting.ajax.php
include/ajax/visual_console_builder.ajax.php
include/ajax/alert_list.ajax.php
include/ajax/module.php
include/functions_config.php
include/functions_api.php
include/help/en/help_timesource.php
include/help/es/help_timesource.php
include/help/ja/help_timesource.php
include/config_process.php
include/functions_ui.php
include/functions_custom_graphs.php
include/fgraph.php
include/functions_incidents.php
include/api.php
include/functions_reports.php
include/functions_ui_renders.php
extensions/insert_data.php
extensions/system_info.php
extensions/extension_uploader.php
extensions/pandora_logs.php
extensions/agents_modules.php
extensions/update_manager.php
extensions/ssh_console.php
extensions/dbmanager.php
extensions/vnc_view.php
extensions/resource_registration.php
extensions/resource_exportation.php
extensions/users_connected.php
extensions/module_groups.php
extensions/update_manager/load_updatemanager.php
extensions/update_manager/lib/libupdate_manager_client.php
extensions/update_manager/lib/libupdate_manager.php
extensions/update_manager/lib/libupdate_manager_components.php
extensions/update_manager/lib/libupdate_manager_updates.php
extensions/update_manager/settings.php
extensions/update_manager/main.php
extensions/plugin_registration.php
operation/incidents/incident.php
operation/incidents/incident_detail.php
operation/incidents/incident_statistics.php
operation/search_modules.php
operation/visual_console/render_view.php
operation/visual_console/index.php
operation/extensions.php
operation/agentes/status_monitor.php
operation/agentes/export_csv.php
operation/agentes/estado_ultimopaquete.php
operation/agentes/datos_agente.php
operation/agentes/alerts_status.php
operation/agentes/estado_generalagente.php
operation/agentes/custom_fields.php
operation/agentes/estado_agente.php
operation/agentes/networkmap.topology.php
operation/agentes/networkmap.groups.php
operation/agentes/sla_view.php
operation/agentes/exportdata.php
operation/agentes/gis_view.php
operation/agentes/estado_monitores.php
operation/agentes/ver_agente.php
operation/agentes/graphs.php
operation/agentes/agent_fields.php
operation/agentes/tactical.php
operation/agentes/group_view.php
operation/agentes/networkmap.php
operation/agentes/stat_win.php
operation/servers/view_server.php
operation/servers/view_server_detail.php
operation/menu.php
operation/search_agents.php
operation/search_graphs.php
operation/snmpconsole/snmp_view.php
operation/users/user_edit.php
operation/gis_maps/render_view.php
operation/gis_maps/ajax.php
operation/integria_incidents/incident.php
operation/integria_incidents/incident_detail.php
operation/integria_incidents/incident_statistics.php
operation/events/event_statistics.php
operation/events/events_rss.php
operation/events/export_csv.php
operation/events/sound_events.php
operation/events/events_validate.php
operation/events/events_list.php
operation/events/events_marquee.php
operation/events/events.php
operation/search_alerts.php
operation/messages/message.php
operation/reporting/reporting_xml.php
operation/reporting/reporting_viewer.php
operation/reporting/graph_viewer.php
operation/search_reports.php
operation/search_maps.php
operation/search_users.php
extras/pandora_diag.php
mobile/operation/agents/monitor_status.php
mobile/operation/agents/view_agents.php
mobile/operation/agents/view_alerts.php
mobile/operation/agents/group_view.php
mobile/operation/events/events.php
mobile/index.php
general/error_authconfig.php
general/links_menu.php
general/logon_ok.php
general/error_dbconfig.php
general/ui/agents_list.php
general/header.php
godmode/groups/modu_group_list.php
godmode/groups/configure_group.php
godmode/groups/configure_modu_group.php
godmode/groups/group_list.php
godmode/admin_access_logs.php
godmode/db/db_main.php
godmode/db/db_audit.php
godmode/db/db_sanity.php
godmode/db/db_refine.php
godmode/db/db_info.php
godmode/db/db_event.php
godmode/db/db_purge.php
godmode/extensions.php
godmode/agentes/agent_template.php
godmode/agentes/module_manager_editor_common.php
godmode/agentes/fields_manager.php
godmode/agentes/agent_conf_gis.php
godmode/agentes/module_manager_editor_prediction.php
godmode/agentes/module_manager.php
godmode/agentes/modificar_agente.php
godmode/agentes/configurar_agente.php
godmode/agentes/configure_field.php
godmode/agentes/module_manager_editor.php
godmode/agentes/planned_downtime.php
godmode/agentes/manage_config_remote.php
godmode/agentes/agent_manager.php
godmode/servers/recon_script.php
godmode/servers/plugin.php
godmode/servers/manage_recontask.php
godmode/servers/modificar_server.php
godmode/servers/manage_recontask_form.php
godmode/alerts/alert_list.list.php
godmode/alerts/configure_alert_compound.php
godmode/alerts/alert_compounds.php
godmode/alerts/alert_list.php
godmode/alerts/configure_alert_template.php
godmode/alerts/alert_templates.php
godmode/alerts/configure_alert_action.php
godmode/alerts/configure_alert_command.php
godmode/alerts/alert_actions.php
godmode/alerts/alert_list.builder.php
godmode/alerts/alert_commands.php
godmode/setup/file_manager.php
godmode/setup/os.list.php
godmode/setup/news.php
godmode/setup/gis_step_2.php
godmode/setup/links.php
godmode/setup/setup.php
godmode/setup/os.php
godmode/setup/performance.php
godmode/setup/setup_auth.php
godmode/setup/gis.php
godmode/setup/os.builder.php
godmode/setup/setup_visuals.php
godmode/snmpconsole/snmp_alert.php
godmode/snmpconsole/snmp_filters.php
godmode/users/user_list.php
godmode/users/configure_profile.php
godmode/gis_maps/configure_gis_map.php
godmode/gis_maps/index.php
godmode/massive/massive_add_alerts.php
godmode/massive/massive_copy_modules.php
godmode/massive/massive_delete_agents.php
godmode/massive/massive_enable_disable_alerts.php
godmode/massive/massive_operations.php
godmode/massive/massive_delete_profiles.php
godmode/massive/massive_edit_agents.php
godmode/massive/massive_delete_action_alerts.php
godmode/massive/massive_delete_modules.php
godmode/massive/massive_add_profiles.php
godmode/massive/massive_delete_alerts.php
godmode/massive/massive_edit_modules.php
godmode/massive/massive_standby_alerts.php
godmode/massive/massive_add_action_alerts.php
godmode/modules/manage_network_components_form.php
godmode/modules/manage_nc_groups_form.php
godmode/modules/manage_network_templates.php
godmode/modules/module_list.php
godmode/modules/manage_network_components_form_common.php
godmode/modules/manage_network_components_form_network.php
godmode/modules/manage_network_templates_form.php
godmode/modules/manage_network_components_form_wmi.php
godmode/modules/manage_network_components.php
godmode/modules/manage_nc_groups.php
godmode/reporting/visual_console_builder.wizard.php
godmode/reporting/graph_builder.main.php
godmode/reporting/reporting_builder.list_items.php
godmode/reporting/visual_console_builder.php
godmode/reporting/reporting_builder.preview.php
godmode/reporting/reporting_builder.main.php
godmode/reporting/visual_console_builder.data.php
godmode/reporting/visual_console_builder.elements.php
godmode/reporting/graph_builder.php
godmode/reporting/visual_console_builder.preview.php
godmode/reporting/graph_builder.graph_editor.php
godmode/reporting/reporting_builder.php
godmode/reporting/visual_console_builder.editor.php
godmode/reporting/reporting_builder.item_editor.php
godmode/reporting/map_builder.php
godmode/reporting/graphs.php
godmode/reporting/graph_builder.preview.php
include/functions_db.php: Added some includes and functions of this code have "db_" prefix.
* include/functions.php: Moved function check_login(), check_acl(),
dame_nombre_pluginid(), get_os_name() from functions_db.php to functions.php.
* include/functions_groups.php: Moved functions get_childrens(), safe_acl_group()
and get_parents(), give_disabled_group(), isAllGroups(), get_group_icon(), get_all_groups(),
get_id_groups_recursive(), get_user_groups_tree_recursive(), get_group_status(),
get_group_name(), get_group_users() from functions_db.php to this code.
* include/functions_profile.php: New library with profile functions. Moved functions
get_profile_name(), get_profiles(), create_user_profile(), delete_user_profile(),
delete_profile() from functions_db.php to this code. Added new parameter in function
get_profile() to retrieve profiles with filter conditions applied.
* include/functions_users.php: New library with users functions. Moved functions
get_users_info(), get_all_model_groups(), get_user_groups(), get_user_groups_tree(),
get_user_first_group(), user_access_to_agent() from funtions_db.php to this code.
* godmode/users/configure_user.php: Changed get_profile_filter() function to get_profile().
* include/functions_agents.php: Moved functions get_group_agents(), get_agent_modules(),
get_agent_module_id(), get_agent_id(), get_agent_name(), get_agent_modules_data_count(),
check_alert_fired(), get_agent_interval(), get_agent_os(), give_agentmodule_flag(),
agent_add_address(), agent_delete_address(), get_agent_address(), get_agent_with_ip(),
get_agent_addresses(), get_agent_status(), delete_agent(), get_agentmodule_group(),
get_agent_group() from functions_db.php to this code.
* include/functions_modules.php: Moved functions get_agentmodule(), get_agentmodule_id(),
get_agentmodule_is_init(), get_agent_modules_count(), get_module_type_name(),
get_module_type_icon(), get_agentmodule_agent(), get_agentmodule_agent_name(),
get_agentmodule_name(), get_agentmodule_type(), get_monitor_downs_in_period(),
get_monitor_last_down_timestamp_in_period(), get_monitors_in_group(),
get_monitors_in_agent(), get_monitors_down(), get_moduletype_name(),
get_moduletype_description(), get_moduletypes(), get_module_interval(), show_icon_type(),
give_modulecategory_name(),
give_agent_id_from_module_id(), get_module_status(), get_agent_module_last_value(),
get_previous_data(), get_agentmodule_modulegroup(), get_modulegroups(),
get_modulegroup_name() from functions_db.php to this code.
* include/functions_alerts.php: Moved functions get_alert_type(), get_agent_alert_fired(),
get_module_alert_fired(), get_alert_fires_in_period(), get_group_alerts(), get_alerts_fired(),
get_alert_last_fire_timestamp_in_period(), get_agentmodule_status(),
get_agentmodule_last_status() from functions_db.php to this code.
* include/functions_exportserver.php: Moved function dame_nombre_servidorexportacion()
from functions_db.php to this code.
* include/functions_events.php: Moved functions get_group_events(), get_agent_events(),
get_module_events() from functions_db.php to this code.
* include/functions_servers.php: Moved functions get_server_name(), show_server_type(),
check_server_status(), server_status() from functions_db.php to this code.
* include/functions_network_profiles.php: Moved function get_networkprofile_name()
from functions_db.php to this code.
* include/functions_visual_map.php: Moved functions get_layoutdata_x(), get_layoutdata_y()
from fucntions_db.php to this code.
* include/functions_io.php: Moved function __() from functions_db.php to this code.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4258 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2011-04-19 20:42:49 +02:00
|
|
|
require_once ('include/functions_users.php');
|
2008-08-11 Esteban Sanchez <estebans@artica.es>
* include/functions_db.php: Added __ as an alias of lang_string().
* include/functions_reporting_pdf.php,
include/functions_reporting.php, include/functions.php,
include/functions_visual_map.php, index.php,
operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/incidents/incident_note.php,
operation/incidents/incident_search.php,
operation/incidents/incident_statistics.php,
operation/snmpconsole/snmp_alert.php,
operation/snmpconsole/snmp_view.php, operation/users/user.php,
operation/users/user_edit.php, operation/users/user_statistics.php,
operation/events/event_statistics.php, operation/events/events.php,
operation/visual_console/render_view.php,
operation/visual_console/index.php, operation/extensions.php,
operation/agentes/estado_alertas.php,
operation/agentes/status_monitor.php,
operation/agentes/estado_grupo.php, operation/agentes/export_csv.php,
operation/agentes/datos_agente.php,
operation/agentes/estado_ultimopaquete.php,
operation/agentes/estado_generalagente.php,
operation/agentes/estado_agente.php, operation/agentes/bulbs.php,
operation/agentes/status_events.php, operation/agentes/sla_view.php,
operation/agentes/exportdata.php,
operation/agentes/estado_monitores.php,
operation/agentes/ver_agente.php, operation/agentes/estadisticas.php,
operation/agentes/tactical.php, operation/agentes/networkmap.php,
operation/messages/message.php,
operation/reporting/reporting_viewer.php,
operation/reporting/graph_viewer.php,
operation/reporting/custom_reporting.php,
operation/servers/view_server.php,
operation/servers/view_server_detail.php, operation/menu.php,
reporting/fgraph.php, reporting/stat_win.php, ajax.php,
general/logoff.php, general/pandora_help.php, general/footer.php,
general/noaccess.php, general/logon_failed.php,
general/links_menu.php, general/login_page.php, general/logon_ok.php,
general/header.php, general/main_menu.php,
godmode/groups/configure_group.php, godmode/groups/group_list.php,
godmode/setup/news.php, godmode/setup/links.php,
godmode/setup/setup.php, godmode/users/user_list.php,
godmode/users/configure_user.php, godmode/profiles/profile_list.php,
godmode/admin_access_logs.php, godmode/db/db_info_data.php,
godmode/db/db_main.php, godmode/db/db_audit.php,
godmode/db/db_sanity.php, godmode/db/db_refine.php,
godmode/db/db_info.php, godmode/db/db_event.php,
godmode/db/db_purge.php, godmode/extensions.php,
godmode/agentes/agent_template.php,
godmode/agentes/module_manager_editor_network.php,
godmode/agentes/module_manager_editor_wmi.php,
godmode/agentes/alert_manager.php,
godmode/agentes/module_manager_editor_plugin.php,
godmode/agentes/module_manager_editor_prediction.php,
godmode/agentes/alert_manager_editor.php,
godmode/agentes/manage_config.php,
godmode/agentes/module_manager_editor_data.php,
godmode/agentes/module_manager.php,
godmode/agentes/modificar_agente.php,
godmode/agentes/configurar_agente.php,
godmode/agentes/agent_disk_conf_editor.php,
godmode/agentes/planned_downtime.php,
godmode/agentes/manage_config_remote.php,
godmode/agentes/agent_manager.php,
godmode/modules/manage_network_components_form.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/modules/module_list.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_network_components_form_network.php,
godmode/modules/manage_network_components_form_wmi.php,
godmode/modules/manage_network_components.php,
godmode/modules/manage_nc_groups.php,
godmode/reporting/reporting_builder.php,
godmode/reporting/map_builder.php,
godmode/reporting/graph_builder.php, godmode/servers/plugin.php,
godmode/servers/manage_recontask.php,
godmode/servers/modificar_server.php,
godmode/servers/manage_recontask_form.php,
godmode/alerts/modify_alert.php, godmode/alerts/configure_alert.php,
godmode/menu.php: Replaced $id_user with $config['id_user']. Use __a
instead of $lang_label to future use of gettext. Style
corrections.
* godmode/agentes/planned_downtime.php: Rewritten to use Pandora
functions and adopt the UI style. Replaced lang_string with __().
* pandoradb.sql: Fields in tplanned_downtime renamed to fit
guidelines.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1005 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-08-11 12:59:07 +02:00
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
$source_id_group = (int) get_parameter ('source_id_group');
|
|
|
|
$source_id_agent = (int) get_parameter ('source_id_agent');
|
|
|
|
$destiny_id_group = (int) get_parameter ('destiny_id_group');
|
|
|
|
$destiny_id_agents = (array) get_parameter ('destiny_id_agent', array ());
|
2011-08-25 09:06:33 +02:00
|
|
|
$source_recursion = get_parameter ('source_recursion');
|
|
|
|
$destiny_recursion = get_parameter ('destiny_recursion');
|
2008-10-14 17:07:53 +02:00
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
$do_operation = (bool) get_parameter ('do_operation');
|
2008-10-14 17:07:53 +02:00
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
if ($do_operation) {
|
2013-10-25 12:15:50 +02:00
|
|
|
$result = agents_process_manage_config($source_id_agent,
|
|
|
|
$destiny_id_agents);
|
2010-10-29 Miguel de Dios <miguel.dedios@artica.es>
* extensions/dbmanager.php, godmode/agentes/module_manager_editor.php,
godmode/massive/massive_add_alerts.php,
godmode/massive/massive_copy_modules.php,
godmode/massive/massive_delete_agents.php,
godmode/massive/massive_enable_disable_alerts.php,
godmode/massive/massive_operations.php,
godmode/massive/massive_delete_profiles.php,
godmode/massive/massive_edit_agents.php,
godmode/massive/massive_delete_action_alerts.php,
godmode/massive/massive_delete_modules.php,
godmode/massive/massive_add_profiles.php,
godmode/massive/massive_delete_alerts.php,
godmode/massive/massive_edit_modules.php,
godmode/massive/massive_standby_alerts.php,
godmode/massive/massive_add_action_alerts.php: now in the source code pick
more info in the audit for actions.
Pending tasks: #3089687
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@3480 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2010-10-29 14:35:34 +02:00
|
|
|
if ($result) {
|
2013-10-25 12:15:50 +02:00
|
|
|
db_pandora_audit("Massive management", "Copy modules", false,
|
|
|
|
false,
|
2010-10-29 Miguel de Dios <miguel.dedios@artica.es>
* extensions/dbmanager.php, godmode/agentes/module_manager_editor.php,
godmode/massive/massive_add_alerts.php,
godmode/massive/massive_copy_modules.php,
godmode/massive/massive_delete_agents.php,
godmode/massive/massive_enable_disable_alerts.php,
godmode/massive/massive_operations.php,
godmode/massive/massive_delete_profiles.php,
godmode/massive/massive_edit_agents.php,
godmode/massive/massive_delete_action_alerts.php,
godmode/massive/massive_delete_modules.php,
godmode/massive/massive_add_profiles.php,
godmode/massive/massive_delete_alerts.php,
godmode/massive/massive_edit_modules.php,
godmode/massive/massive_standby_alerts.php,
godmode/massive/massive_add_action_alerts.php: now in the source code pick
more info in the audit for actions.
Pending tasks: #3089687
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@3480 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2010-10-29 14:35:34 +02:00
|
|
|
'Source agent: ' . json_encode($source_id_agent) . ' Destinity agent: ' . json_encode($destiny_id_agents));
|
|
|
|
}
|
|
|
|
else {
|
2013-10-25 12:15:50 +02:00
|
|
|
db_pandora_audit("Massive management",
|
|
|
|
"Fail to try copy modules", false, false,
|
2010-10-29 Miguel de Dios <miguel.dedios@artica.es>
* extensions/dbmanager.php, godmode/agentes/module_manager_editor.php,
godmode/massive/massive_add_alerts.php,
godmode/massive/massive_copy_modules.php,
godmode/massive/massive_delete_agents.php,
godmode/massive/massive_enable_disable_alerts.php,
godmode/massive/massive_operations.php,
godmode/massive/massive_delete_profiles.php,
godmode/massive/massive_edit_agents.php,
godmode/massive/massive_delete_action_alerts.php,
godmode/massive/massive_delete_modules.php,
godmode/massive/massive_add_profiles.php,
godmode/massive/massive_delete_alerts.php,
godmode/massive/massive_edit_modules.php,
godmode/massive/massive_standby_alerts.php,
godmode/massive/massive_add_action_alerts.php: now in the source code pick
more info in the audit for actions.
Pending tasks: #3089687
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@3480 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2010-10-29 14:35:34 +02:00
|
|
|
'Source agent: ' . json_encode($source_id_agent) . ' Destinity agent: ' . json_encode($destiny_id_agents));
|
|
|
|
}
|
2008-10-14 17:07:53 +02:00
|
|
|
}
|
|
|
|
|
2011-05-10 Juan Manuel Ramon <juanmanuel.ramon@artica.es>
* include/functions_graph.php
include/functions_users.php
include/functions_html.php
include/functions_menu.php
include/functions_messages.php
include/functions_modules.php
include/functions_reporting.php
include/functions_groups.php
include/functions_gis.php
include/auth/ldap.php
include/auth/mysql.php
include/functions_networkmap.php
include/functions_network_components.php
include/functions_visual_map.php
include/functions_profile.php
include/ajax/visual_console_builder.ajax.php
include/ajax/alert_list.ajax.php
include/ajax/module.php
include/functions_config.php
include/functions_api.php
include/functions_ui.php
include/functions_custom_graphs.php
include/fgraph.php
include/functions_agents.php
include/functions_db.php
include/functions_alerts.php
include/functions_reports.php
index.php
extensions/insert_data.php
extensions/agents_modules.php
extensions/resource_registration.php
extensions/resource_exportation.php
extensions/module_groups.php
operation/incidents/incident_detail.php
operation/search_modules.php
operation/agentes/status_monitor.php
operation/agentes/export_csv.php
operation/agentes/estado_ultimopaquete.php
operation/agentes/datos_agente.php
operation/agentes/alerts_status.php
operation/agentes/estado_generalagente.php
operation/agentes/estado_agente.php
operation/agentes/sla_view.php
operation/agentes/exportdata.php
operation/agentes/gis_view.php
operation/agentes/estado_monitores.php
operation/agentes/ver_agente.php
operation/agentes/graphs.php
operation/agentes/group_view.php
operation/search_agents.php
operation/snmpconsole/snmp_view.php
operation/users/user_edit.php
operation/integria_incidents/incident_detail.php
operation/gis_maps/render_view.php
operation/gis_maps/ajax.php
operation/events/events_rss.php
operation/events/export_csv.php
operation/events/events_list.php
operation/events/events_marquee.php
operation/events/events.php
operation/search_alerts.php
operation/messages/message.php
operation/search_users.php
mobile/operation/agents/monitor_status.php
mobile/operation/agents/view_agents.php
mobile/operation/agents/view_alerts.php
mobile/operation/agents/group_view.php
mobile/operation/events/events.php
ajax.php
general/ui/agents_list.php
godmode/groups/configure_group.php
godmode/groups/group_list.php
godmode/db/db_refine.php
godmode/db/db_info.php
godmode/db/db_purge.php
godmode/agentes/module_manager_editor_common.php
godmode/agentes/module_manager_editor_network.php
godmode/agentes/module_manager_editor_wmi.php
godmode/agentes/module_manager_editor_plugin.php
godmode/agentes/module_manager_editor_prediction.php
godmode/agentes/agent_conf_gis.php
godmode/agentes/module_manager.php
godmode/agentes/modificar_agente.php
godmode/agentes/configurar_agente.php
godmode/agentes/module_manager_editor.php
godmode/agentes/planned_downtime.php
godmode/agentes/manage_config_remote.php
godmode/agentes/agent_manager.php
godmode/servers/manage_recontask_form.php
godmode/alerts/alert_list.list.php
godmode/alerts/configure_alert_compound.php
godmode/alerts/alert_compounds.php
godmode/alerts/alert_list.php
godmode/alerts/configure_alert_template.php
godmode/alerts/alert_templates.php
godmode/alerts/configure_alert_action.php
godmode/alerts/alert_actions.php
godmode/alerts/alert_list.builder.php
godmode/setup/setup_auth.php
godmode/users/user_list.php
godmode/users/configure_user.php
godmode/users/configure_profile.php
godmode/massive/massive_add_alerts.php
godmode/massive/massive_copy_modules.php
godmode/massive/massive_delete_agents.php
godmode/massive/massive_enable_disable_alerts.php
godmode/massive/massive_delete_profiles.php
godmode/massive/massive_edit_agents.php
godmode/massive/massive_delete_action_alerts.php
godmode/massive/massive_delete_modules.php
godmode/massive/massive_add_profiles.php
godmode/massive/massive_delete_alerts.php
godmode/massive/massive_edit_modules.php
godmode/massive/massive_standby_alerts.php
godmode/massive/massive_add_action_alerts.php
godmode/reporting/visual_console_builder.wizard.php
godmode/reporting/reporting_builder.list_items.php
godmode/reporting/visual_console_builder.php
godmode/reporting/reporting_builder.main.php
godmode/reporting/visual_console_builder.data.php
godmode/reporting/visual_console_builder.elements.php
godmode/reporting/graph_builder.graph_editor.php
godmode/reporting/reporting_builder.php
godmode/reporting/reporting_builder.item_editor.php: Functions in
functions_profile.php, functions_agents.php, functions_users.php,
functions_massive_policies.php, functions_audit.php, functions_backup.php,
functions_collection.php, functions_skins.php, functions_enterprise.php,
functions_groups.php, functions_local_components.php, functions_metaconsole.php,
functions_policies.php, functions_reporting.php, functions_reporting_csv.php,
functions_reporting_pdf2.php, functions_services.php have their own prefixes.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4333 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2011-05-10 20:51:09 +02:00
|
|
|
$groups = users_get_groups ();
|
2009-02-16 13:18:42 +01:00
|
|
|
|
|
|
|
$table->class = 'databox';
|
2011-06-28 15:31:52 +02:00
|
|
|
$table->width = '98%';
|
2009-02-16 13:18:42 +01:00
|
|
|
$table->data = array ();
|
|
|
|
$table->style = array ();
|
|
|
|
$table->style[0] = 'font-weight: bold; vertical-align:top';
|
|
|
|
$table->style[2] = 'font-weight: bold';
|
2014-03-25 13:39:26 +01:00
|
|
|
$table->style[4] = 'font-weight: bold';
|
|
|
|
$table->style[6] = 'font-weight: bold';
|
2009-02-16 13:18:42 +01:00
|
|
|
|
|
|
|
/* Source selection */
|
|
|
|
$table->id = 'source_table';
|
|
|
|
$table->data[0][0] = __('Group');
|
2011-04-27 15:43:31 +02:00
|
|
|
$table->data[0][1] = html_print_select_groups(false, "AR", true, 'source_id_group', $source_id_group,
|
2009-02-16 13:18:42 +01:00
|
|
|
false, '', '', true);
|
2011-08-25 09:06:33 +02:00
|
|
|
$table->data[0][2] = __('Group recursion');
|
|
|
|
$table->data[0][3] = html_print_checkbox ("source_recursion", 1, $source_recursion, true, false);
|
2014-03-25 13:39:26 +01:00
|
|
|
$status_list = array ();
|
|
|
|
$status_list[AGENT_STATUS_NORMAL] = __('Normal');
|
|
|
|
$status_list[AGENT_STATUS_WARNING] = __('Warning');
|
|
|
|
$status_list[AGENT_STATUS_CRITICAL] = __('Critical');
|
|
|
|
$status_list[AGENT_STATUS_UNKNOWN] = __('Unknown');
|
|
|
|
$status_list[AGENT_STATUS_NOT_NORMAL] = __('Not normal');
|
|
|
|
$status_list[AGENT_STATUS_NOT_INIT] = __('Not init');
|
|
|
|
$table->data[0][4] = __('Status');
|
|
|
|
$table->data[0][5] = html_print_select($status_list,
|
|
|
|
'status_agents_source', 'selected', '', __('All'), AGENT_STATUS_ALL, true);
|
|
|
|
$table->data[0][6] = __('Agent');
|
|
|
|
$table->data[0][6] .= ' <span id="source_agent_loading" class="invisible">';
|
|
|
|
$table->data[0][6] .= html_print_image ("images/spinner.png", true);
|
|
|
|
$table->data[0][6] .= '</span>';
|
|
|
|
$table->data[0][7] = html_print_select (agents_get_group_agents ($source_id_group, false, "none"),
|
2009-02-16 13:18:42 +01:00
|
|
|
'source_id_agent', $source_id_agent, false, __('Select'), 0, true);
|
|
|
|
|
2010-10-12 03:32:05 +02:00
|
|
|
echo '<form action="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&option=copy_modules" id="manage_config_form" method="post">';
|
2009-02-16 13:18:42 +01:00
|
|
|
|
|
|
|
echo '<fieldset id="fieldset_source">';
|
|
|
|
echo '<legend><span>'.__('Source');
|
2011-04-13 18:11:02 +02:00
|
|
|
ui_print_help_icon ('manageconfig');
|
2009-02-16 13:18:42 +01:00
|
|
|
echo '</span></legend>';
|
2011-04-27 15:43:31 +02:00
|
|
|
html_print_table ($table);
|
2009-02-16 13:18:42 +01:00
|
|
|
echo '</fieldset>';
|
2008-10-14 17:07:53 +02:00
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
/* Target selection */
|
|
|
|
$table->id = 'target_table';
|
|
|
|
$table->data = array ();
|
2008-10-14 17:07:53 +02:00
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
$modules = array ();
|
|
|
|
if ($source_id_agent)
|
2011-05-10 Juan Manuel Ramon <juanmanuel.ramon@artica.es>
* include/functions_graph.php
include/functions_users.php
include/functions_html.php
include/functions_menu.php
include/functions_messages.php
include/functions_modules.php
include/functions_reporting.php
include/functions_groups.php
include/functions_gis.php
include/auth/ldap.php
include/auth/mysql.php
include/functions_networkmap.php
include/functions_network_components.php
include/functions_visual_map.php
include/functions_profile.php
include/ajax/visual_console_builder.ajax.php
include/ajax/alert_list.ajax.php
include/ajax/module.php
include/functions_config.php
include/functions_api.php
include/functions_ui.php
include/functions_custom_graphs.php
include/fgraph.php
include/functions_agents.php
include/functions_db.php
include/functions_alerts.php
include/functions_reports.php
index.php
extensions/insert_data.php
extensions/agents_modules.php
extensions/resource_registration.php
extensions/resource_exportation.php
extensions/module_groups.php
operation/incidents/incident_detail.php
operation/search_modules.php
operation/agentes/status_monitor.php
operation/agentes/export_csv.php
operation/agentes/estado_ultimopaquete.php
operation/agentes/datos_agente.php
operation/agentes/alerts_status.php
operation/agentes/estado_generalagente.php
operation/agentes/estado_agente.php
operation/agentes/sla_view.php
operation/agentes/exportdata.php
operation/agentes/gis_view.php
operation/agentes/estado_monitores.php
operation/agentes/ver_agente.php
operation/agentes/graphs.php
operation/agentes/group_view.php
operation/search_agents.php
operation/snmpconsole/snmp_view.php
operation/users/user_edit.php
operation/integria_incidents/incident_detail.php
operation/gis_maps/render_view.php
operation/gis_maps/ajax.php
operation/events/events_rss.php
operation/events/export_csv.php
operation/events/events_list.php
operation/events/events_marquee.php
operation/events/events.php
operation/search_alerts.php
operation/messages/message.php
operation/search_users.php
mobile/operation/agents/monitor_status.php
mobile/operation/agents/view_agents.php
mobile/operation/agents/view_alerts.php
mobile/operation/agents/group_view.php
mobile/operation/events/events.php
ajax.php
general/ui/agents_list.php
godmode/groups/configure_group.php
godmode/groups/group_list.php
godmode/db/db_refine.php
godmode/db/db_info.php
godmode/db/db_purge.php
godmode/agentes/module_manager_editor_common.php
godmode/agentes/module_manager_editor_network.php
godmode/agentes/module_manager_editor_wmi.php
godmode/agentes/module_manager_editor_plugin.php
godmode/agentes/module_manager_editor_prediction.php
godmode/agentes/agent_conf_gis.php
godmode/agentes/module_manager.php
godmode/agentes/modificar_agente.php
godmode/agentes/configurar_agente.php
godmode/agentes/module_manager_editor.php
godmode/agentes/planned_downtime.php
godmode/agentes/manage_config_remote.php
godmode/agentes/agent_manager.php
godmode/servers/manage_recontask_form.php
godmode/alerts/alert_list.list.php
godmode/alerts/configure_alert_compound.php
godmode/alerts/alert_compounds.php
godmode/alerts/alert_list.php
godmode/alerts/configure_alert_template.php
godmode/alerts/alert_templates.php
godmode/alerts/configure_alert_action.php
godmode/alerts/alert_actions.php
godmode/alerts/alert_list.builder.php
godmode/setup/setup_auth.php
godmode/users/user_list.php
godmode/users/configure_user.php
godmode/users/configure_profile.php
godmode/massive/massive_add_alerts.php
godmode/massive/massive_copy_modules.php
godmode/massive/massive_delete_agents.php
godmode/massive/massive_enable_disable_alerts.php
godmode/massive/massive_delete_profiles.php
godmode/massive/massive_edit_agents.php
godmode/massive/massive_delete_action_alerts.php
godmode/massive/massive_delete_modules.php
godmode/massive/massive_add_profiles.php
godmode/massive/massive_delete_alerts.php
godmode/massive/massive_edit_modules.php
godmode/massive/massive_standby_alerts.php
godmode/massive/massive_add_action_alerts.php
godmode/reporting/visual_console_builder.wizard.php
godmode/reporting/reporting_builder.list_items.php
godmode/reporting/visual_console_builder.php
godmode/reporting/reporting_builder.main.php
godmode/reporting/visual_console_builder.data.php
godmode/reporting/visual_console_builder.elements.php
godmode/reporting/graph_builder.graph_editor.php
godmode/reporting/reporting_builder.php
godmode/reporting/reporting_builder.item_editor.php: Functions in
functions_profile.php, functions_agents.php, functions_users.php,
functions_massive_policies.php, functions_audit.php, functions_backup.php,
functions_collection.php, functions_skins.php, functions_enterprise.php,
functions_groups.php, functions_local_components.php, functions_metaconsole.php,
functions_policies.php, functions_reporting.php, functions_reporting_csv.php,
functions_reporting_pdf2.php, functions_services.php have their own prefixes.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4333 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2011-05-10 20:51:09 +02:00
|
|
|
$modules = agents_get_modules ($source_id_agent, 'nombre');
|
2009-02-16 13:18:42 +01:00
|
|
|
|
|
|
|
$table->data['operations'][0] = __('Operations');
|
2009-02-24 17:31:02 +01:00
|
|
|
$table->data['operations'][1] = '<span class="with_modules'.(empty ($modules) ? ' invisible': '').'">';
|
2011-04-27 15:43:31 +02:00
|
|
|
$table->data['operations'][1] .= html_print_checkbox ('copy_modules', 1, true, true);
|
|
|
|
$table->data['operations'][1] .= html_print_label (__('Copy modules'), 'checkbox-copy_modules', true);
|
2009-02-16 13:18:42 +01:00
|
|
|
$table->data['operations'][1] .= '</span><br />';
|
|
|
|
|
2009-02-24 17:31:02 +01:00
|
|
|
$table->data['operations'][1] .= '<span class="with_alerts'.(empty ($alerts) ? ' invisible': '').'">';
|
2011-04-27 15:43:31 +02:00
|
|
|
$table->data['operations'][1] .= html_print_checkbox ('copy_alerts', 1, true, true);
|
|
|
|
$table->data['operations'][1] .= html_print_label (__('Copy alerts'), 'checkbox-copy_alerts', true);
|
2009-02-16 13:18:42 +01:00
|
|
|
$table->data['operations'][1] .= '</span>';
|
|
|
|
|
|
|
|
$table->data[1][0] = __('Modules');
|
2009-02-24 17:31:02 +01:00
|
|
|
$table->data[1][1] = '<span class="with_modules'.(empty ($modules) ? ' invisible': '').'">';
|
2011-04-27 15:43:31 +02:00
|
|
|
$table->data[1][1] .= html_print_select ($modules,
|
2009-02-16 13:18:42 +01:00
|
|
|
'target_modules[]', 0, false, '', '', true, true);
|
|
|
|
$table->data[1][1] .= '</span>';
|
2009-02-24 17:31:02 +01:00
|
|
|
$table->data[1][1] .= '<span class="without_modules'.(! empty ($modules) ? ' invisible': '').'">';
|
2009-02-16 13:18:42 +01:00
|
|
|
$table->data[1][1] .= '<em>'.__('No modules for this agent').'</em>';
|
|
|
|
$table->data[1][1] .= '</span>';
|
|
|
|
|
|
|
|
$table->data[2][0] = __('Alerts');
|
|
|
|
|
|
|
|
$agent_alerts = array ();
|
|
|
|
if ($source_id_agent)
|
2011-04-15 12:57:43 +02:00
|
|
|
$agent_alerts = agents_get_alerts_simple ($source_id_agent);
|
2009-02-16 13:18:42 +01:00
|
|
|
$alerts = array ();
|
|
|
|
foreach ($agent_alerts as $alert) {
|
2011-04-15 12:57:43 +02:00
|
|
|
$name = alerts_get_alert_template_name ($alert['id_alert_template']);
|
2009-02-16 13:18:42 +01:00
|
|
|
$name .= ' (<em>'.$modules[$alert['id_agent_module']].'</em>)';
|
|
|
|
$alerts[$alert['id']] = $name;
|
2008-10-14 17:07:53 +02:00
|
|
|
}
|
2009-02-24 17:31:02 +01:00
|
|
|
$table->data[2][1] = '<span class="with_alerts'.(empty ($alerts) ? ' invisible': '').'">';
|
2011-04-27 15:43:31 +02:00
|
|
|
$table->data[2][1] .= html_print_select ($alerts,
|
2009-02-16 13:18:42 +01:00
|
|
|
'target_alerts[]', 0, false, '', '', true, true);
|
|
|
|
$table->data[2][1] .= '</span>';
|
2009-02-24 17:31:02 +01:00
|
|
|
$table->data[2][1] .= '<span class="without_alerts'.(! empty ($modules) ? ' invisible': '').'">';
|
2009-02-16 13:18:42 +01:00
|
|
|
$table->data[2][1] .= '<em>'.__('No alerts for this agent').'</em>';
|
|
|
|
$table->data[2][1] .= '</span>';
|
|
|
|
|
|
|
|
echo '<div id="modules_loading" class="loading invisible">';
|
2011-04-27 15:43:31 +02:00
|
|
|
html_print_image ("images/spinner.png");
|
2009-02-16 13:18:42 +01:00
|
|
|
echo __('Loading').'…';
|
|
|
|
echo '</div>';
|
|
|
|
|
|
|
|
echo '<fieldset id="fieldset_targets"'.($source_id_agent ? '' : ' class="invisible"').'>';
|
|
|
|
echo '<legend><span>'.__('Targets').'</span></legend>';
|
2011-04-27 15:43:31 +02:00
|
|
|
html_print_table ($table);
|
2009-02-16 13:18:42 +01:00
|
|
|
echo '</fieldset>';
|
|
|
|
|
2014-03-25 13:39:26 +01:00
|
|
|
|
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
/* Destiny selection */
|
|
|
|
$table->id = 'destiny_table';
|
|
|
|
$table->data = array ();
|
2011-08-25 09:06:33 +02:00
|
|
|
$table->size[0] = '20%';
|
|
|
|
$table->size[1] = '30%';
|
|
|
|
$table->size[2] = '20%';
|
|
|
|
$table->size[3] = '30%';
|
2009-02-16 13:18:42 +01:00
|
|
|
$table->data[0][0] = __('Group');
|
2014-03-25 13:39:26 +01:00
|
|
|
$table->data[0][1] = html_print_select ($groups, 'destiny_id_group',
|
|
|
|
$destiny_id_group, false, '', '', true);
|
2011-08-25 09:06:33 +02:00
|
|
|
$table->data[0][2] = __('Group recursion');
|
2014-03-25 13:39:26 +01:00
|
|
|
$table->data[0][3] = html_print_checkbox ("destiny_recursion", 1,
|
|
|
|
$destiny_recursion, true, false);
|
|
|
|
$status_list = array ();
|
|
|
|
$status_list[AGENT_STATUS_NORMAL] = __('Normal');
|
|
|
|
$status_list[AGENT_STATUS_WARNING] = __('Warning');
|
|
|
|
$status_list[AGENT_STATUS_CRITICAL] = __('Critical');
|
|
|
|
$status_list[AGENT_STATUS_UNKNOWN] = __('Unknown');
|
|
|
|
$status_list[AGENT_STATUS_NOT_NORMAL] = __('Not normal');
|
|
|
|
$status_list[AGENT_STATUS_NOT_INIT] = __('Not init');
|
|
|
|
$table->data[1][0] = __('Status');
|
|
|
|
$table->data[1][1] = html_print_select($status_list,
|
|
|
|
'status_agents_destiny', 'selected', '', __('All'), AGENT_STATUS_ALL, true);
|
|
|
|
$table->data[2][0] = __('Agent');
|
|
|
|
$table->data[2][0] .= '<span id="destiny_agent_loading" class="invisible">';
|
|
|
|
$table->data[2][0] .= html_print_image ("images/spinner.png", true);
|
|
|
|
$table->data[2][0] .= '</span>';
|
|
|
|
$table->data[2][1] = html_print_select (agents_get_group_agents ($destiny_id_group, false, "none"),
|
2009-02-16 13:18:42 +01:00
|
|
|
'destiny_id_agent[]', 0, false, '', '', true, true);
|
|
|
|
|
2014-03-25 13:39:26 +01:00
|
|
|
echo '<fieldset id="fieldset_destiny"' .
|
|
|
|
($source_id_agent ? '' : ' class="invisible"') . '>';
|
|
|
|
echo '<legend><span>' . __('To agent(s)') . '</span></legend>';
|
2011-04-27 15:43:31 +02:00
|
|
|
html_print_table ($table);
|
2009-02-16 13:18:42 +01:00
|
|
|
echo '</fieldset>';
|
|
|
|
|
2014-03-25 13:39:26 +01:00
|
|
|
echo '<div class="action-buttons" style="width: ' . $table->width . '">';
|
2011-04-27 15:43:31 +02:00
|
|
|
html_print_input_hidden ('do_operation', 1);
|
|
|
|
html_print_submit_button (__('Copy'), 'go', false, 'class="sub wand"');
|
2009-02-16 13:18:42 +01:00
|
|
|
echo '</div>';
|
|
|
|
echo '</form>';
|
|
|
|
|
2014-03-25 13:39:26 +01:00
|
|
|
|
|
|
|
|
2009-02-24 17:31:02 +01:00
|
|
|
echo '<h3 class="error invisible" id="message"> </h3>';
|
2009-02-16 13:18:42 +01:00
|
|
|
|
2011-04-13 18:11:02 +02:00
|
|
|
ui_require_jquery_file ('form');
|
|
|
|
ui_require_jquery_file ('pandora.controls');
|
2009-02-16 13:18:42 +01:00
|
|
|
?>
|
|
|
|
<script type="text/javascript">
|
2009-02-24 17:31:02 +01:00
|
|
|
/* <![CDATA[ */
|
2009-03-17 10:22:02 +01:00
|
|
|
var module_alerts;
|
2009-02-16 13:18:42 +01:00
|
|
|
$(document).ready (function () {
|
2011-08-25 09:06:33 +02:00
|
|
|
var source_recursion;
|
2013-03-15 15:35:52 +01:00
|
|
|
$("#checkbox-source_recursion").click(function () {
|
2011-08-25 09:06:33 +02:00
|
|
|
source_recursion = this.checked ? 1 : 0;
|
|
|
|
$("#source_id_group").trigger("change");
|
|
|
|
});
|
2013-03-15 15:35:52 +01:00
|
|
|
|
2009-04-22 12:46:05 +02:00
|
|
|
$("#source_id_group").pandoraSelectGroupAgent ({
|
2009-02-23 17:23:58 +01:00
|
|
|
agentSelect: "select#source_id_agent",
|
2014-03-25 13:39:26 +01:00
|
|
|
recursion: function() {
|
|
|
|
return source_recursion
|
|
|
|
},
|
|
|
|
status_agents: function () {
|
|
|
|
return $("#status_agents_source").val();
|
|
|
|
},
|
2009-02-23 17:23:58 +01:00
|
|
|
loading: "#source_agent_loading"
|
2009-02-16 17:23:30 +01:00
|
|
|
});
|
|
|
|
|
2014-03-25 13:39:26 +01:00
|
|
|
$("#status_agents_source").change(function() {
|
|
|
|
$("#source_id_group").trigger("change");
|
|
|
|
});
|
|
|
|
|
2011-08-25 09:06:33 +02:00
|
|
|
var destiny_recursion;
|
2013-03-15 15:35:52 +01:00
|
|
|
$("#checkbox-destiny_recursion").click(function () {
|
2011-08-25 09:06:33 +02:00
|
|
|
destiny_recursion = this.checked ? 1 : 0;
|
|
|
|
$("#destiny_id_group").trigger("change");
|
|
|
|
});
|
2013-03-15 15:35:52 +01:00
|
|
|
|
2009-04-22 12:46:05 +02:00
|
|
|
$("#destiny_id_group").pandoraSelectGroupAgent ({
|
2009-02-24 17:31:02 +01:00
|
|
|
agentSelect: "select#destiny_id_agent",
|
2011-08-25 09:06:33 +02:00
|
|
|
recursion: function() {return destiny_recursion},
|
2014-03-25 13:39:26 +01:00
|
|
|
status_agents: function () {
|
|
|
|
return $("#status_agents_destiny").val();
|
|
|
|
},
|
2009-02-23 17:23:58 +01:00
|
|
|
loading: "#destiny_agent_loading",
|
2009-02-16 17:23:30 +01:00
|
|
|
callbackPost: function (id, value, option) {
|
|
|
|
if ($("#source_id_agent").fieldValue ().in_array (id)) {
|
|
|
|
/* Hide source agent */
|
|
|
|
$(option).hide ();
|
|
|
|
}
|
|
|
|
}
|
2009-02-16 13:18:42 +01:00
|
|
|
});
|
2008-10-14 17:07:53 +02:00
|
|
|
|
2014-03-25 13:39:26 +01:00
|
|
|
$("#status_agents_destiny").change(function() {
|
|
|
|
$("#destiny_id_group").trigger("change");
|
|
|
|
});
|
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
$("#source_id_agent").change (function () {
|
|
|
|
var id_agent = this.value;
|
|
|
|
if (id_agent == 0) {
|
2013-03-15 15:35:52 +01:00
|
|
|
$("#submit-go").attr("disabled", "disabled");
|
|
|
|
|
|
|
|
$("span.without_modules, span.without_alerts").hide();
|
|
|
|
$("span.without_modules").hide();
|
|
|
|
$("span.with_modules").hide();
|
|
|
|
$("span.without_alerts").hide();
|
|
|
|
$("span.with_alerts").hide();
|
|
|
|
$("#fieldset_destiny, #target_table-operations").hide();
|
|
|
|
$("#fieldset_targets").hide();
|
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
return;
|
|
|
|
}
|
2013-03-15 15:35:52 +01:00
|
|
|
|
|
|
|
$("#submit-go").attr("disabled", false);
|
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
$("#modules_loading").show ();
|
2009-02-24 17:31:02 +01:00
|
|
|
$("#target_modules option, #target_alerts option").remove ();
|
|
|
|
$("#target_modules, #target_alerts").disable ();
|
|
|
|
$("#destiny_id_agent option").show ();
|
|
|
|
$("#destiny_id_agent option[value="+id_agent+"]").hide ();
|
2009-02-16 13:18:42 +01:00
|
|
|
var no_modules;
|
|
|
|
var no_alerts;
|
|
|
|
/* Get modules */
|
|
|
|
jQuery.post ("ajax.php",
|
2010-09-29 17:25:59 +02:00
|
|
|
{"page" : "operation/agentes/ver_agente",
|
2009-02-16 13:18:42 +01:00
|
|
|
"get_agent_modules_json" : 1,
|
|
|
|
"id_agent" : this.value,
|
2009-03-17 16:15:55 +01:00
|
|
|
"filter" : "disabled = 0",
|
|
|
|
"fields" : "id_agente_modulo,nombre"
|
2009-02-16 13:18:42 +01:00
|
|
|
},
|
|
|
|
function (data, status) {
|
|
|
|
if (data.length == 0) {
|
|
|
|
no_modules = true;
|
2012-07-24 Miguel de Dios <miguel.dedios@artica.es>
* godmode/setup/file_manager.php, godmode/setup/news.php,
godmode/users/configure_user.php, godmode/users/user_list.php,
godmode/massive/massive_copy_modules.php,
godmode/massive/massive_enable_disable_alerts.php,
godmode/massive/massive_delete_action_alerts.php,
godmode/massive/massive_delete_alerts.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_nc_groups.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/netflow/nf_edit.php, godmode/netflow/nf_edit_form.php,
godmode/netflow/nf_item_list.php,
godmode/netflow/nf_report_item.php, godmode/netflow/nf.php,
operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/agentes/estado_agente.php, operation/agentes/sla_view.php,
operation/agentes/tactical.php,
operation/agentes/estado_generalagente.php,
operation/snmpconsole/snmp_view.php, operation/users/user_edit.php,
operation/integria_incidents/incident_detail.php,
operation/gis_maps/index.php, operation/events/events_list.php,
operation/events/events.php, operation/messages/message_edit.php,
operation/messages/message_list.php,
operation/reporting/graph_viewer.php, operation/search_reports.php,
operation/netflow/nf_view.php: cleaned source code.
* godmode/massive/massive_operations.php,
godmode/massive/massive_edit_modules.php: fixed the massive edition
of "any" module in agents.
Fixes: #3543484
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6806 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-07-24 18:38:48 +02:00
|
|
|
}
|
|
|
|
else {
|
2009-02-16 13:18:42 +01:00
|
|
|
jQuery.each (data, function (i, val) {
|
|
|
|
option = $("<option></option>")
|
|
|
|
.attr ("value", val["id_agente_modulo"])
|
|
|
|
.append (val["nombre"]);
|
2009-02-24 17:31:02 +01:00
|
|
|
$("#target_modules").append (option);
|
2009-02-16 13:18:42 +01:00
|
|
|
});
|
|
|
|
|
|
|
|
no_modules = false;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* Get alerts */
|
|
|
|
jQuery.post ("ajax.php",
|
2010-04-07 17:32:11 +02:00
|
|
|
{"page" : "include/ajax/alert_list.ajax",
|
2009-02-16 13:18:42 +01:00
|
|
|
"get_agent_alerts_simple" : 1,
|
|
|
|
"id_agent" : id_agent
|
|
|
|
},
|
|
|
|
function (data, status) {
|
2009-03-17 10:22:02 +01:00
|
|
|
module_alerts = Array ();
|
2009-02-16 13:18:42 +01:00
|
|
|
if (! data) {
|
|
|
|
no_alerts = true;
|
2012-07-26 Miguel de Dios <miguel.dedios@artica.es>
* operation/users/user_edit.php,
operation/events/events_validate.php, operation/search_graphs.php,
godmode/events/event_filter.php, godmode/events/custom_events.php,
godmode/massive/massive_standby_alerts.php,
godmode/massive/massive_copy_modules.php, godmode/tag/tag.php,
godmode/netflow/nf_report.php, godmode/agentes/configure_field.php,
godmode/agentes/agent_manager.php,
godmode/agentes/agent_template.php,
godmode/agentes/fields_manager.php,
godmode/servers/recon_script.php, godmode/servers/plugin.php,
include/functions_modules.php: improved the source structure.
* operation/search_modules.php: fixed the search when the modules
haven't inicialiced.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6814 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-07-26 13:05:05 +02:00
|
|
|
}
|
|
|
|
else {
|
2009-02-16 13:18:42 +01:00
|
|
|
jQuery.each (data, function (i, val) {
|
|
|
|
module_name = $("<em></em>").append (val["module_name"]);
|
|
|
|
option = $("<option></option>")
|
|
|
|
.attr ("value", val["id"])
|
|
|
|
.append (val["template"]["name"])
|
|
|
|
.append (" (")
|
|
|
|
.append (module_name)
|
|
|
|
.append (")");
|
2009-02-24 17:31:02 +01:00
|
|
|
$("#target_alerts").append (option);
|
2009-03-17 10:22:02 +01:00
|
|
|
module_alerts[val["id"]] = val["id_agent_module"];
|
2009-02-16 13:18:42 +01:00
|
|
|
});
|
|
|
|
no_alerts = false;
|
|
|
|
}
|
|
|
|
$("#modules_loading").hide ();
|
|
|
|
|
|
|
|
if (no_modules && no_alerts) {
|
|
|
|
/* Nothing to export from selected agent */
|
|
|
|
$("#fieldset_destiny").hide ();
|
|
|
|
|
|
|
|
$("span.without_modules, span.without_alerts").show ();
|
|
|
|
$("span.with_modules, span.with_alerts, #target_table-operations").hide ();
|
2012-07-26 Miguel de Dios <miguel.dedios@artica.es>
* operation/users/user_edit.php,
operation/events/events_validate.php, operation/search_graphs.php,
godmode/events/event_filter.php, godmode/events/custom_events.php,
godmode/massive/massive_standby_alerts.php,
godmode/massive/massive_copy_modules.php, godmode/tag/tag.php,
godmode/netflow/nf_report.php, godmode/agentes/configure_field.php,
godmode/agentes/agent_manager.php,
godmode/agentes/agent_template.php,
godmode/agentes/fields_manager.php,
godmode/servers/recon_script.php, godmode/servers/plugin.php,
include/functions_modules.php: improved the source structure.
* operation/search_modules.php: fixed the search when the modules
haven't inicialiced.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6814 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-07-26 13:05:05 +02:00
|
|
|
}
|
|
|
|
else {
|
2009-02-16 13:18:42 +01:00
|
|
|
if (no_modules) {
|
|
|
|
$("span.without_modules").show ();
|
|
|
|
$("span.with_modules").hide ();
|
|
|
|
$("#checkbox-copy_modules").uncheck ();
|
2012-07-26 Miguel de Dios <miguel.dedios@artica.es>
* operation/users/user_edit.php,
operation/events/events_validate.php, operation/search_graphs.php,
godmode/events/event_filter.php, godmode/events/custom_events.php,
godmode/massive/massive_standby_alerts.php,
godmode/massive/massive_copy_modules.php, godmode/tag/tag.php,
godmode/netflow/nf_report.php, godmode/agentes/configure_field.php,
godmode/agentes/agent_manager.php,
godmode/agentes/agent_template.php,
godmode/agentes/fields_manager.php,
godmode/servers/recon_script.php, godmode/servers/plugin.php,
include/functions_modules.php: improved the source structure.
* operation/search_modules.php: fixed the search when the modules
haven't inicialiced.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6814 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-07-26 13:05:05 +02:00
|
|
|
}
|
|
|
|
else {
|
2009-02-16 13:18:42 +01:00
|
|
|
$("span.without_modules").hide ();
|
|
|
|
$("span.with_modules").show ();
|
|
|
|
$("#checkbox-copy_modules").check ();
|
|
|
|
}
|
|
|
|
|
|
|
|
if (no_alerts) {
|
|
|
|
$("span.without_alerts").show ();
|
|
|
|
$("span.with_alerts").hide ();
|
|
|
|
$("#checkbox-copy_alerts").uncheck ();
|
2012-07-26 Miguel de Dios <miguel.dedios@artica.es>
* operation/users/user_edit.php,
operation/events/events_validate.php, operation/search_graphs.php,
godmode/events/event_filter.php, godmode/events/custom_events.php,
godmode/massive/massive_standby_alerts.php,
godmode/massive/massive_copy_modules.php, godmode/tag/tag.php,
godmode/netflow/nf_report.php, godmode/agentes/configure_field.php,
godmode/agentes/agent_manager.php,
godmode/agentes/agent_template.php,
godmode/agentes/fields_manager.php,
godmode/servers/recon_script.php, godmode/servers/plugin.php,
include/functions_modules.php: improved the source structure.
* operation/search_modules.php: fixed the search when the modules
haven't inicialiced.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6814 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-07-26 13:05:05 +02:00
|
|
|
}
|
|
|
|
else {
|
2009-02-16 13:18:42 +01:00
|
|
|
$("span.without_alerts").hide ();
|
|
|
|
$("span.with_alerts").show ();
|
|
|
|
$("#checkbox-copy_alerts").check ();
|
|
|
|
}
|
|
|
|
$("#fieldset_destiny, #target_table-operations").show ();
|
|
|
|
}
|
|
|
|
$("#fieldset_targets").show ();
|
2009-02-24 17:31:02 +01:00
|
|
|
$("#target_modules, #target_alerts").enable ();
|
2009-02-16 13:18:42 +01:00
|
|
|
},
|
|
|
|
"json"
|
|
|
|
);
|
|
|
|
},
|
|
|
|
"json"
|
|
|
|
);
|
|
|
|
});
|
|
|
|
|
2009-03-17 10:22:02 +01:00
|
|
|
$("#target_alerts").change (function () {
|
|
|
|
jQuery.each ($(this).fieldValue (), function () {
|
|
|
|
if (module_alerts[this] != undefined)
|
|
|
|
$("#target_modules option[value="+module_alerts[this]+"]")
|
|
|
|
.attr ("selected", "selected");
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
$("#manage_config_form").submit (function () {
|
|
|
|
$("h3:not([id=message])").remove ();
|
|
|
|
if ($("#source_id_agent").attr ("value") == 0) {
|
|
|
|
$("#message").showMessage ("<?php echo __('No source agent to copy') ?>");
|
|
|
|
return false;
|
|
|
|
}
|
2008-06-16 20:09:56 +02:00
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
copy_modules = $("#checkbox-copy_modules");
|
|
|
|
copy_alerts = $("#checkbox-copy_alerts");
|
2008-10-10 17:08:31 +02:00
|
|
|
|
2009-02-16 13:18:42 +01:00
|
|
|
if (! $(copy_modules).attr ("checked") && ! $(copy_alerts).attr ("checked")) {
|
|
|
|
$("#message").showMessage ("<?php echo __('No operation selected') ?>");
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2009-03-04 16:59:00 +01:00
|
|
|
if ($(copy_modules).attr ("checked") && $("#target_modules").fieldValue ().length == 0) {
|
2009-02-16 13:18:42 +01:00
|
|
|
$("#message").showMessage ("<?php echo __('No modules have been selected') ?>");
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2009-02-24 17:31:02 +01:00
|
|
|
if ($("#destiny_id_agent").fieldValue ().length == 0) {
|
2009-02-16 13:18:42 +01:00
|
|
|
$("#message").showMessage ("<?php echo __('No destiny agent(s) to copy') ?>");
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
$("#message").hide ();
|
|
|
|
return true;
|
|
|
|
});
|
|
|
|
});
|
2009-02-24 17:31:02 +01:00
|
|
|
/* ]]> */
|
2013-02-28 12:43:10 +01:00
|
|
|
</script>
|