2008-06-26 Esteban Sanchez <estebans@artica.es>
* ajax.php: Sed id_user in config array.
* godmode/menu.php, general/header.php, operation/menu.php: Replaced
lang_label with lang_string().
* general/logon_ok.php: Reduced one indentation level.
* godmode/agentes/agent_manager.php: Replaced lang_label with
lang_string(). Use pandora functions.
* include/functions_html.php, godmode/agentes/configurar_agente.php:
Tab and blankspaces style correction.
* godmode/reporting/map_builder.php: Complete rewritten to provide an
intuitive way of build the maps. It's cool, useful and very simple.
* godmode/reporting/reporting_builder.php: Deleted an output debug.
* godmode/setup/setup.php: Rewritten to use pandora functions. Added a
colorpicker for color settings.
* include/config.php: Reset pandora password. We must solve things
with this file...
* include/functions.php: Check if input is an array on safe_input().
Use filename as id in array returned by list_files().
* include/functions_db.php: Renamed return_coordinate_* functions.
Style correction.
* include/javascript/jquery.js: Updated to 1.2.6.
* include/javascript/jquery.ui.datepicker.js: Code minimized.
* include/javascript/pandora.js: Style correction.
* include/javascript/wz_jsgraphics.js: Added a class to the elements
of a line, so it can be modified using javascript.
* /include/styles/pandora.css: Added style to some tables dropdowns.
Added new styles relative to visual map editor.
* operation/reporting/reporting_viewer.php: Style correction. Added
jQuery UI.
* operation/visual_console/index.php: Use Pandora functions.
* operation/visual_console/render_view.php: Drawing the map is now on
functions_visual_map.php. Added a countdown if a refresh time is set.
Use pandora functions. Style correction.
* reporting/fgraph.php: Style correction. Use graphic_error() if
there's no data on grafico_modulo_sparse().
* images/trash.png: Added to repository. Image used on trash area on
visual map editor.
* images/console/background/africa.jpg,
images/console/background/asia.jpg,
images/console/background/europe.jpg,
images/console/background/north_america.jpg,
images/console/background/oceania.jpg,
images/console/background/shouth_america.jpg,
images/console/background/world.jpg: Added to repository. Useful and
cool map backgrounds.
* include/functions_visual_map.php: Added to repository. Implements
visual map functions like drawing the map.
* include/javascript/jquery.colorpicker.js: Added to repository.
Implements a color picker widget.
* /include/javascript/jquery.countdown.js: Added to repository.
Implements a countdown widget.
* include/javascript/jquery.ui.core.js: Added to repository. jQuery UI
core.
* include/javascript/jquery.ui.draggable.js: Added to repository.
jQuery draggable plugin.
* include/javascript/jquery.ui.droppable.js: Added to repository.
jQuery droppable plugin.
* include/javascript/pandora_visual_console.js: Added to repository.
Function useful to visual map interface.
* include/languages/countdown_*.js: Added to repository. Countdown
localization.
* include/languages/date_es_la.js, include/languages/date_gl.js,
include/languages/time_es_la.js, include/languages/time_gl.js: Added
to repository. Missing localizations.
* include/styles/color-picker.css: Added to repository. Colorpicker
style sheet.
* include/styles/countdown.css: Added to repository. Countdown style
sheet.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@899 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-26 15:26:48 +02:00
|
|
|
<?php
|
2007-05-20 19:12:31 +02:00
|
|
|
|
2009-06-08 20:18:20 +02:00
|
|
|
// Pandora FMS - http://pandorafms.com
|
|
|
|
// ==================================================
|
|
|
|
// Copyright (c) 2005-2009 Artica Soluciones Tecnologicas
|
|
|
|
// Please see http://pandorafms.org for full contribution list
|
2008-08-22 20:07:32 +02:00
|
|
|
|
2007-05-20 19:12:31 +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.
|
2007-05-20 19:12:31 +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:18:20 +02:00
|
|
|
|
2012-12-11 Miguel de Dios <miguel.dedios@artica.es>
* extras/pandoradb_migrate_4.0.x_to_5.0.mysql.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.oracle.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.postgreSQL.sql, pandoradb.sql,
pandoradb.postgreSQL.sql, pandoradb.oracle.sql: in the table
"tlayout_data" added the column "id_metaconsole" for to show
visualmaps in the metaconsole.
* operation/visual_console/render_view.php,
include/functions_visual_map.php, operation/agentes/ver_agente.php,
godmode/reporting/visual_console_builder.wizard.php,
godmode/reporting/visual_console_builder.php,
godmode/reporting/visual_console_builder.data.php,
godmode/reporting/visual_console_builder.editor.js,
godmode/reporting/visual_console_builder.elements.php,
godmode/reporting/visual_console_builder.editor.php,
godmode/reporting/map_builder.php,
include/ajax/visual_console_builder.ajax.php,
include/ajax/agent.php, include/functions_visual_map_editor.php,
* operation/agentes/datos_agente.php,
include/functions_netflow.php: cleaned source code style.
* include/functions_ui.php: in function
"ui_require_javascript_file_enterprise" fixed when need a
enterprise javascript instead metaconsole enterprise path.
* include/javascript/pandora.js: fixed the function
"agent_changed_by_multiple_agents" that needs in the metaconsole.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7258 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-12-11 16:01:45 +01:00
|
|
|
global $config;
|
2007-05-20 19:12:31 +02:00
|
|
|
|
|
|
|
// Login check
|
2017-12-28 15:13:06 +01:00
|
|
|
require_once ($config['homedir'] . '/include/functions_visual_map.php');
|
2008-06-26 Esteban Sanchez <estebans@artica.es>
* ajax.php: Sed id_user in config array.
* godmode/menu.php, general/header.php, operation/menu.php: Replaced
lang_label with lang_string().
* general/logon_ok.php: Reduced one indentation level.
* godmode/agentes/agent_manager.php: Replaced lang_label with
lang_string(). Use pandora functions.
* include/functions_html.php, godmode/agentes/configurar_agente.php:
Tab and blankspaces style correction.
* godmode/reporting/map_builder.php: Complete rewritten to provide an
intuitive way of build the maps. It's cool, useful and very simple.
* godmode/reporting/reporting_builder.php: Deleted an output debug.
* godmode/setup/setup.php: Rewritten to use pandora functions. Added a
colorpicker for color settings.
* include/config.php: Reset pandora password. We must solve things
with this file...
* include/functions.php: Check if input is an array on safe_input().
Use filename as id in array returned by list_files().
* include/functions_db.php: Renamed return_coordinate_* functions.
Style correction.
* include/javascript/jquery.js: Updated to 1.2.6.
* include/javascript/jquery.ui.datepicker.js: Code minimized.
* include/javascript/pandora.js: Style correction.
* include/javascript/wz_jsgraphics.js: Added a class to the elements
of a line, so it can be modified using javascript.
* /include/styles/pandora.css: Added style to some tables dropdowns.
Added new styles relative to visual map editor.
* operation/reporting/reporting_viewer.php: Style correction. Added
jQuery UI.
* operation/visual_console/index.php: Use Pandora functions.
* operation/visual_console/render_view.php: Drawing the map is now on
functions_visual_map.php. Added a countdown if a refresh time is set.
Use pandora functions. Style correction.
* reporting/fgraph.php: Style correction. Use graphic_error() if
there's no data on grafico_modulo_sparse().
* images/trash.png: Added to repository. Image used on trash area on
visual map editor.
* images/console/background/africa.jpg,
images/console/background/asia.jpg,
images/console/background/europe.jpg,
images/console/background/north_america.jpg,
images/console/background/oceania.jpg,
images/console/background/shouth_america.jpg,
images/console/background/world.jpg: Added to repository. Useful and
cool map backgrounds.
* include/functions_visual_map.php: Added to repository. Implements
visual map functions like drawing the map.
* include/javascript/jquery.colorpicker.js: Added to repository.
Implements a color picker widget.
* /include/javascript/jquery.countdown.js: Added to repository.
Implements a countdown widget.
* include/javascript/jquery.ui.core.js: Added to repository. jQuery UI
core.
* include/javascript/jquery.ui.draggable.js: Added to repository.
jQuery draggable plugin.
* include/javascript/jquery.ui.droppable.js: Added to repository.
jQuery droppable plugin.
* include/javascript/pandora_visual_console.js: Added to repository.
Function useful to visual map interface.
* include/languages/countdown_*.js: Added to repository. Countdown
localization.
* include/languages/date_es_la.js, include/languages/date_gl.js,
include/languages/time_es_la.js, include/languages/time_gl.js: Added
to repository. Missing localizations.
* include/styles/color-picker.css: Added to repository. Colorpicker
style sheet.
* include/styles/countdown.css: Added to repository. Countdown style
sheet.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@899 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-26 15:26:48 +02:00
|
|
|
|
2008-10-20 19:25:37 +02:00
|
|
|
check_login ();
|
2007-05-20 19:12:31 +02:00
|
|
|
|
2012-12-11 Miguel de Dios <miguel.dedios@artica.es>
* extras/pandoradb_migrate_4.0.x_to_5.0.mysql.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.oracle.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.postgreSQL.sql, pandoradb.sql,
pandoradb.postgreSQL.sql, pandoradb.oracle.sql: in the table
"tlayout_data" added the column "id_metaconsole" for to show
visualmaps in the metaconsole.
* operation/visual_console/render_view.php,
include/functions_visual_map.php, operation/agentes/ver_agente.php,
godmode/reporting/visual_console_builder.wizard.php,
godmode/reporting/visual_console_builder.php,
godmode/reporting/visual_console_builder.data.php,
godmode/reporting/visual_console_builder.editor.js,
godmode/reporting/visual_console_builder.elements.php,
godmode/reporting/visual_console_builder.editor.php,
godmode/reporting/map_builder.php,
include/ajax/visual_console_builder.ajax.php,
include/ajax/agent.php, include/functions_visual_map_editor.php,
* operation/agentes/datos_agente.php,
include/functions_netflow.php: cleaned source code style.
* include/functions_ui.php: in function
"ui_require_javascript_file_enterprise" fixed when need a
enterprise javascript instead metaconsole enterprise path.
* include/javascript/pandora.js: fixed the function
"agent_changed_by_multiple_agents" that needs in the metaconsole.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7258 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-12-11 16:01:45 +01:00
|
|
|
if (!defined('METACONSOLE'))
|
|
|
|
$id_layout = (int) get_parameter ('id');
|
|
|
|
else
|
|
|
|
$id_layout = (int) get_parameter ('id_visualmap');
|
|
|
|
|
2013-05-20 10:42:02 +02:00
|
|
|
if ($id_layout) {
|
|
|
|
$default_action = 'edit';
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
$default_action = 'new';
|
|
|
|
}
|
2013-08-02 12:53:50 +02:00
|
|
|
|
2013-04-18 11:25:23 +02:00
|
|
|
if (!defined('METACONSOLE')) {
|
2014-11-04 18:17:38 +01:00
|
|
|
$action = get_parameterBetweenListValues('action',
|
|
|
|
array('new', 'save', 'edit', 'update', 'delete'), $default_action);
|
2013-04-18 11:25:23 +02:00
|
|
|
}
|
|
|
|
else {
|
2014-11-04 18:17:38 +01:00
|
|
|
$action = get_parameterBetweenListValues('action2',
|
|
|
|
array('new', 'save', 'edit', 'update', 'delete'), $default_action);
|
2013-04-18 11:25:23 +02:00
|
|
|
}
|
|
|
|
|
2011-11-17 17:55:32 +01:00
|
|
|
$refr = (int) get_parameter ('refr', $config['vc_refr']);
|
2017-02-28 12:25:06 +01:00
|
|
|
$graph_javascript = (bool) get_parameter ('graph_javascript', true);
|
2011-11-17 17:55:32 +01:00
|
|
|
$vc_refr = false;
|
2008-06-26 Esteban Sanchez <estebans@artica.es>
* ajax.php: Sed id_user in config array.
* godmode/menu.php, general/header.php, operation/menu.php: Replaced
lang_label with lang_string().
* general/logon_ok.php: Reduced one indentation level.
* godmode/agentes/agent_manager.php: Replaced lang_label with
lang_string(). Use pandora functions.
* include/functions_html.php, godmode/agentes/configurar_agente.php:
Tab and blankspaces style correction.
* godmode/reporting/map_builder.php: Complete rewritten to provide an
intuitive way of build the maps. It's cool, useful and very simple.
* godmode/reporting/reporting_builder.php: Deleted an output debug.
* godmode/setup/setup.php: Rewritten to use pandora functions. Added a
colorpicker for color settings.
* include/config.php: Reset pandora password. We must solve things
with this file...
* include/functions.php: Check if input is an array on safe_input().
Use filename as id in array returned by list_files().
* include/functions_db.php: Renamed return_coordinate_* functions.
Style correction.
* include/javascript/jquery.js: Updated to 1.2.6.
* include/javascript/jquery.ui.datepicker.js: Code minimized.
* include/javascript/pandora.js: Style correction.
* include/javascript/wz_jsgraphics.js: Added a class to the elements
of a line, so it can be modified using javascript.
* /include/styles/pandora.css: Added style to some tables dropdowns.
Added new styles relative to visual map editor.
* operation/reporting/reporting_viewer.php: Style correction. Added
jQuery UI.
* operation/visual_console/index.php: Use Pandora functions.
* operation/visual_console/render_view.php: Drawing the map is now on
functions_visual_map.php. Added a countdown if a refresh time is set.
Use pandora functions. Style correction.
* reporting/fgraph.php: Style correction. Use graphic_error() if
there's no data on grafico_modulo_sparse().
* images/trash.png: Added to repository. Image used on trash area on
visual map editor.
* images/console/background/africa.jpg,
images/console/background/asia.jpg,
images/console/background/europe.jpg,
images/console/background/north_america.jpg,
images/console/background/oceania.jpg,
images/console/background/shouth_america.jpg,
images/console/background/world.jpg: Added to repository. Useful and
cool map backgrounds.
* include/functions_visual_map.php: Added to repository. Implements
visual map functions like drawing the map.
* include/javascript/jquery.colorpicker.js: Added to repository.
Implements a color picker widget.
* /include/javascript/jquery.countdown.js: Added to repository.
Implements a countdown widget.
* include/javascript/jquery.ui.core.js: Added to repository. jQuery UI
core.
* include/javascript/jquery.ui.draggable.js: Added to repository.
jQuery draggable plugin.
* include/javascript/jquery.ui.droppable.js: Added to repository.
jQuery droppable plugin.
* include/javascript/pandora_visual_console.js: Added to repository.
Function useful to visual map interface.
* include/languages/countdown_*.js: Added to repository. Countdown
localization.
* include/languages/date_es_la.js, include/languages/date_gl.js,
include/languages/time_es_la.js, include/languages/time_gl.js: Added
to repository. Missing localizations.
* include/styles/color-picker.css: Added to repository. Colorpicker
style sheet.
* include/styles/countdown.css: Added to repository. Countdown style
sheet.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@899 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-26 15:26:48 +02:00
|
|
|
|
2013-04-18 11:25:23 +02:00
|
|
|
if (isset($config['vc_refr']) and $config['vc_refr'] != 0)
|
|
|
|
$view_refresh = $config['vc_refr'];
|
|
|
|
else
|
2016-01-28 11:57:32 +01:00
|
|
|
$view_refresh = '300';
|
2013-04-18 11:25:23 +02:00
|
|
|
|
2007-05-20 19:12:31 +02:00
|
|
|
// Get input parameter for layout id
|
2008-06-26 Esteban Sanchez <estebans@artica.es>
* ajax.php: Sed id_user in config array.
* godmode/menu.php, general/header.php, operation/menu.php: Replaced
lang_label with lang_string().
* general/logon_ok.php: Reduced one indentation level.
* godmode/agentes/agent_manager.php: Replaced lang_label with
lang_string(). Use pandora functions.
* include/functions_html.php, godmode/agentes/configurar_agente.php:
Tab and blankspaces style correction.
* godmode/reporting/map_builder.php: Complete rewritten to provide an
intuitive way of build the maps. It's cool, useful and very simple.
* godmode/reporting/reporting_builder.php: Deleted an output debug.
* godmode/setup/setup.php: Rewritten to use pandora functions. Added a
colorpicker for color settings.
* include/config.php: Reset pandora password. We must solve things
with this file...
* include/functions.php: Check if input is an array on safe_input().
Use filename as id in array returned by list_files().
* include/functions_db.php: Renamed return_coordinate_* functions.
Style correction.
* include/javascript/jquery.js: Updated to 1.2.6.
* include/javascript/jquery.ui.datepicker.js: Code minimized.
* include/javascript/pandora.js: Style correction.
* include/javascript/wz_jsgraphics.js: Added a class to the elements
of a line, so it can be modified using javascript.
* /include/styles/pandora.css: Added style to some tables dropdowns.
Added new styles relative to visual map editor.
* operation/reporting/reporting_viewer.php: Style correction. Added
jQuery UI.
* operation/visual_console/index.php: Use Pandora functions.
* operation/visual_console/render_view.php: Drawing the map is now on
functions_visual_map.php. Added a countdown if a refresh time is set.
Use pandora functions. Style correction.
* reporting/fgraph.php: Style correction. Use graphic_error() if
there's no data on grafico_modulo_sparse().
* images/trash.png: Added to repository. Image used on trash area on
visual map editor.
* images/console/background/africa.jpg,
images/console/background/asia.jpg,
images/console/background/europe.jpg,
images/console/background/north_america.jpg,
images/console/background/oceania.jpg,
images/console/background/shouth_america.jpg,
images/console/background/world.jpg: Added to repository. Useful and
cool map backgrounds.
* include/functions_visual_map.php: Added to repository. Implements
visual map functions like drawing the map.
* include/javascript/jquery.colorpicker.js: Added to repository.
Implements a color picker widget.
* /include/javascript/jquery.countdown.js: Added to repository.
Implements a countdown widget.
* include/javascript/jquery.ui.core.js: Added to repository. jQuery UI
core.
* include/javascript/jquery.ui.draggable.js: Added to repository.
jQuery draggable plugin.
* include/javascript/jquery.ui.droppable.js: Added to repository.
jQuery droppable plugin.
* include/javascript/pandora_visual_console.js: Added to repository.
Function useful to visual map interface.
* include/languages/countdown_*.js: Added to repository. Countdown
localization.
* include/languages/date_es_la.js, include/languages/date_gl.js,
include/languages/time_es_la.js, include/languages/time_gl.js: Added
to repository. Missing localizations.
* include/styles/color-picker.css: Added to repository. Colorpicker
style sheet.
* include/styles/countdown.css: Added to repository. Countdown style
sheet.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@899 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-26 15:26:48 +02:00
|
|
|
if (! $id_layout) {
|
2014-11-04 18:17:38 +01:00
|
|
|
db_pandora_audit("ACL Violation",
|
|
|
|
"Trying to access visual console without id layout");
|
2008-06-26 Esteban Sanchez <estebans@artica.es>
* ajax.php: Sed id_user in config array.
* godmode/menu.php, general/header.php, operation/menu.php: Replaced
lang_label with lang_string().
* general/logon_ok.php: Reduced one indentation level.
* godmode/agentes/agent_manager.php: Replaced lang_label with
lang_string(). Use pandora functions.
* include/functions_html.php, godmode/agentes/configurar_agente.php:
Tab and blankspaces style correction.
* godmode/reporting/map_builder.php: Complete rewritten to provide an
intuitive way of build the maps. It's cool, useful and very simple.
* godmode/reporting/reporting_builder.php: Deleted an output debug.
* godmode/setup/setup.php: Rewritten to use pandora functions. Added a
colorpicker for color settings.
* include/config.php: Reset pandora password. We must solve things
with this file...
* include/functions.php: Check if input is an array on safe_input().
Use filename as id in array returned by list_files().
* include/functions_db.php: Renamed return_coordinate_* functions.
Style correction.
* include/javascript/jquery.js: Updated to 1.2.6.
* include/javascript/jquery.ui.datepicker.js: Code minimized.
* include/javascript/pandora.js: Style correction.
* include/javascript/wz_jsgraphics.js: Added a class to the elements
of a line, so it can be modified using javascript.
* /include/styles/pandora.css: Added style to some tables dropdowns.
Added new styles relative to visual map editor.
* operation/reporting/reporting_viewer.php: Style correction. Added
jQuery UI.
* operation/visual_console/index.php: Use Pandora functions.
* operation/visual_console/render_view.php: Drawing the map is now on
functions_visual_map.php. Added a countdown if a refresh time is set.
Use pandora functions. Style correction.
* reporting/fgraph.php: Style correction. Use graphic_error() if
there's no data on grafico_modulo_sparse().
* images/trash.png: Added to repository. Image used on trash area on
visual map editor.
* images/console/background/africa.jpg,
images/console/background/asia.jpg,
images/console/background/europe.jpg,
images/console/background/north_america.jpg,
images/console/background/oceania.jpg,
images/console/background/shouth_america.jpg,
images/console/background/world.jpg: Added to repository. Useful and
cool map backgrounds.
* include/functions_visual_map.php: Added to repository. Implements
visual map functions like drawing the map.
* include/javascript/jquery.colorpicker.js: Added to repository.
Implements a color picker widget.
* /include/javascript/jquery.countdown.js: Added to repository.
Implements a countdown widget.
* include/javascript/jquery.ui.core.js: Added to repository. jQuery UI
core.
* include/javascript/jquery.ui.draggable.js: Added to repository.
jQuery draggable plugin.
* include/javascript/jquery.ui.droppable.js: Added to repository.
jQuery droppable plugin.
* include/javascript/pandora_visual_console.js: Added to repository.
Function useful to visual map interface.
* include/languages/countdown_*.js: Added to repository. Countdown
localization.
* include/languages/date_es_la.js, include/languages/date_gl.js,
include/languages/time_es_la.js, include/languages/time_gl.js: Added
to repository. Missing localizations.
* include/styles/color-picker.css: Added to repository. Colorpicker
style sheet.
* include/styles/countdown.css: Added to repository. Countdown style
sheet.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@899 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-26 15:26:48 +02:00
|
|
|
include ("general/noaccess.php");
|
|
|
|
exit;
|
|
|
|
}
|
|
|
|
|
* 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
|
|
|
$layout = db_get_row ('tlayout', 'id', $id_layout);
|
2008-06-26 Esteban Sanchez <estebans@artica.es>
* ajax.php: Sed id_user in config array.
* godmode/menu.php, general/header.php, operation/menu.php: Replaced
lang_label with lang_string().
* general/logon_ok.php: Reduced one indentation level.
* godmode/agentes/agent_manager.php: Replaced lang_label with
lang_string(). Use pandora functions.
* include/functions_html.php, godmode/agentes/configurar_agente.php:
Tab and blankspaces style correction.
* godmode/reporting/map_builder.php: Complete rewritten to provide an
intuitive way of build the maps. It's cool, useful and very simple.
* godmode/reporting/reporting_builder.php: Deleted an output debug.
* godmode/setup/setup.php: Rewritten to use pandora functions. Added a
colorpicker for color settings.
* include/config.php: Reset pandora password. We must solve things
with this file...
* include/functions.php: Check if input is an array on safe_input().
Use filename as id in array returned by list_files().
* include/functions_db.php: Renamed return_coordinate_* functions.
Style correction.
* include/javascript/jquery.js: Updated to 1.2.6.
* include/javascript/jquery.ui.datepicker.js: Code minimized.
* include/javascript/pandora.js: Style correction.
* include/javascript/wz_jsgraphics.js: Added a class to the elements
of a line, so it can be modified using javascript.
* /include/styles/pandora.css: Added style to some tables dropdowns.
Added new styles relative to visual map editor.
* operation/reporting/reporting_viewer.php: Style correction. Added
jQuery UI.
* operation/visual_console/index.php: Use Pandora functions.
* operation/visual_console/render_view.php: Drawing the map is now on
functions_visual_map.php. Added a countdown if a refresh time is set.
Use pandora functions. Style correction.
* reporting/fgraph.php: Style correction. Use graphic_error() if
there's no data on grafico_modulo_sparse().
* images/trash.png: Added to repository. Image used on trash area on
visual map editor.
* images/console/background/africa.jpg,
images/console/background/asia.jpg,
images/console/background/europe.jpg,
images/console/background/north_america.jpg,
images/console/background/oceania.jpg,
images/console/background/shouth_america.jpg,
images/console/background/world.jpg: Added to repository. Useful and
cool map backgrounds.
* include/functions_visual_map.php: Added to repository. Implements
visual map functions like drawing the map.
* include/javascript/jquery.colorpicker.js: Added to repository.
Implements a color picker widget.
* /include/javascript/jquery.countdown.js: Added to repository.
Implements a countdown widget.
* include/javascript/jquery.ui.core.js: Added to repository. jQuery UI
core.
* include/javascript/jquery.ui.draggable.js: Added to repository.
jQuery draggable plugin.
* include/javascript/jquery.ui.droppable.js: Added to repository.
jQuery droppable plugin.
* include/javascript/pandora_visual_console.js: Added to repository.
Function useful to visual map interface.
* include/languages/countdown_*.js: Added to repository. Countdown
localization.
* include/languages/date_es_la.js, include/languages/date_gl.js,
include/languages/time_es_la.js, include/languages/time_gl.js: Added
to repository. Missing localizations.
* include/styles/color-picker.css: Added to repository. Colorpicker
style sheet.
* include/styles/countdown.css: Added to repository. Countdown style
sheet.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@899 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-26 15:26:48 +02:00
|
|
|
|
|
|
|
if (! $layout) {
|
2014-11-04 18:17:38 +01:00
|
|
|
db_pandora_audit("ACL Violation",
|
|
|
|
"Trying to access visual console without id layout");
|
2007-05-20 19:12:31 +02:00
|
|
|
include ("general/noaccess.php");
|
|
|
|
exit;
|
|
|
|
}
|
|
|
|
|
2008-06-26 Esteban Sanchez <estebans@artica.es>
* ajax.php: Sed id_user in config array.
* godmode/menu.php, general/header.php, operation/menu.php: Replaced
lang_label with lang_string().
* general/logon_ok.php: Reduced one indentation level.
* godmode/agentes/agent_manager.php: Replaced lang_label with
lang_string(). Use pandora functions.
* include/functions_html.php, godmode/agentes/configurar_agente.php:
Tab and blankspaces style correction.
* godmode/reporting/map_builder.php: Complete rewritten to provide an
intuitive way of build the maps. It's cool, useful and very simple.
* godmode/reporting/reporting_builder.php: Deleted an output debug.
* godmode/setup/setup.php: Rewritten to use pandora functions. Added a
colorpicker for color settings.
* include/config.php: Reset pandora password. We must solve things
with this file...
* include/functions.php: Check if input is an array on safe_input().
Use filename as id in array returned by list_files().
* include/functions_db.php: Renamed return_coordinate_* functions.
Style correction.
* include/javascript/jquery.js: Updated to 1.2.6.
* include/javascript/jquery.ui.datepicker.js: Code minimized.
* include/javascript/pandora.js: Style correction.
* include/javascript/wz_jsgraphics.js: Added a class to the elements
of a line, so it can be modified using javascript.
* /include/styles/pandora.css: Added style to some tables dropdowns.
Added new styles relative to visual map editor.
* operation/reporting/reporting_viewer.php: Style correction. Added
jQuery UI.
* operation/visual_console/index.php: Use Pandora functions.
* operation/visual_console/render_view.php: Drawing the map is now on
functions_visual_map.php. Added a countdown if a refresh time is set.
Use pandora functions. Style correction.
* reporting/fgraph.php: Style correction. Use graphic_error() if
there's no data on grafico_modulo_sparse().
* images/trash.png: Added to repository. Image used on trash area on
visual map editor.
* images/console/background/africa.jpg,
images/console/background/asia.jpg,
images/console/background/europe.jpg,
images/console/background/north_america.jpg,
images/console/background/oceania.jpg,
images/console/background/shouth_america.jpg,
images/console/background/world.jpg: Added to repository. Useful and
cool map backgrounds.
* include/functions_visual_map.php: Added to repository. Implements
visual map functions like drawing the map.
* include/javascript/jquery.colorpicker.js: Added to repository.
Implements a color picker widget.
* /include/javascript/jquery.countdown.js: Added to repository.
Implements a countdown widget.
* include/javascript/jquery.ui.core.js: Added to repository. jQuery UI
core.
* include/javascript/jquery.ui.draggable.js: Added to repository.
jQuery draggable plugin.
* include/javascript/jquery.ui.droppable.js: Added to repository.
jQuery droppable plugin.
* include/javascript/pandora_visual_console.js: Added to repository.
Function useful to visual map interface.
* include/languages/countdown_*.js: Added to repository. Countdown
localization.
* include/languages/date_es_la.js, include/languages/date_gl.js,
include/languages/time_es_la.js, include/languages/time_gl.js: Added
to repository. Missing localizations.
* include/styles/color-picker.css: Added to repository. Colorpicker
style sheet.
* include/styles/countdown.css: Added to repository. Countdown style
sheet.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@899 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-26 15:26:48 +02:00
|
|
|
$id_group = $layout["id_group"];
|
|
|
|
$layout_name = $layout["name"];
|
|
|
|
$background = $layout["background"];
|
|
|
|
$bwidth = $layout["width"];
|
|
|
|
$bheight = $layout["height"];
|
|
|
|
|
2013-04-18 11:25:23 +02:00
|
|
|
$pure_url = "&pure=" . $config["pure"];
|
2008-06-13 Sancho Lerena <slerena@gmail.com>
* index.php: Added pure (Fullscreen). HTML code cleanup and user session.
* pandoradb.sql: talert_snmp: Added priority field.
* pandoradb_data.sql: Changes default values in talerta. tconfig_os, tgrupo
and some links.
* header.php: Fixed some user session management.
* logon_ok.php: New design for welcome screen, odometer is over.
* menu.php, godmode/menu.php: Some ACL improvements.
* agent_disk_conf_editor.php: Minor fix in view link.
* configurar_agente.php, agent_manager.php: Added parent combo and better
ACL checks. New remote configuration control for get timestamp info of
config file.
* modify_alert.php: Changes to use new internal Mail alert.
* config.php: Some items moved to config_process. (font, attachment and
default style).
* functions.php: Added form_agent_combo(), form_event_type_combo(),
form_priority() and return_priority() functions.
* functions_db.php: Added smal_event_table() to render a variable table
with latest events (filtered).
* pandora.css. Added pure and priority colors.
* estado_alertas.php: Fixed ACL problems.
* stado_generalagente.php: Graph of modules now represents modules that
has generated events. Old graph is not used anymore. Also display parent.
* estado_grupo.php: Border of boxes is now thicker.
* tactical.php: New screen, almost all code changed. Odometer is not used
anymore, added some new items, like module LAG meter, module sanity, and
other general metrics.
* ver_agente.php: Now renders also event for each agent view. Alert manual
validation generate a new event.
* events.php: New event system. 90% new code. A LOT of new features,
including full screen, coloured (by priority) and filters by six fields.
* snmp_alert.php: Added support for alert priority.
* operation/users/user.php: No longer a user with UM privileges could
see any other user.
* render_view.php: Added fullscreen support for visual maps.
* fgraph.php: Added support for session checking in graphs (at least!).
New graphics for events (some changed it's function like events by group),
and feature added to progress GD implementation.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@860 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-13 18:59:54 +02:00
|
|
|
|
2015-04-09 14:05:23 +02:00
|
|
|
// ACL
|
|
|
|
$vconsole_read = check_acl ($config["id_user"], $id_group, "VR");
|
|
|
|
$vconsole_write = check_acl ($config["id_user"], $id_group, "VW");
|
|
|
|
$vconsole_manage = check_acl ($config["id_user"], $id_group, "VM");
|
|
|
|
|
2016-09-08 16:06:12 +02:00
|
|
|
if (! $vconsole_read && !$vconsole_write && !$vconsole_manage) {
|
2014-11-04 18:17:38 +01:00
|
|
|
db_pandora_audit("ACL Violation",
|
|
|
|
"Trying to access visual console without group access");
|
2008-10-20 19:25:37 +02:00
|
|
|
require ("general/noaccess.php");
|
|
|
|
exit;
|
|
|
|
}
|
|
|
|
|
2008-06-26 17:37:06 +02:00
|
|
|
// Render map
|
2010-03-31 16:23:16 +02:00
|
|
|
$options = array();
|
2008-06-13 Sancho Lerena <slerena@gmail.com>
* index.php: Added pure (Fullscreen). HTML code cleanup and user session.
* pandoradb.sql: talert_snmp: Added priority field.
* pandoradb_data.sql: Changes default values in talerta. tconfig_os, tgrupo
and some links.
* header.php: Fixed some user session management.
* logon_ok.php: New design for welcome screen, odometer is over.
* menu.php, godmode/menu.php: Some ACL improvements.
* agent_disk_conf_editor.php: Minor fix in view link.
* configurar_agente.php, agent_manager.php: Added parent combo and better
ACL checks. New remote configuration control for get timestamp info of
config file.
* modify_alert.php: Changes to use new internal Mail alert.
* config.php: Some items moved to config_process. (font, attachment and
default style).
* functions.php: Added form_agent_combo(), form_event_type_combo(),
form_priority() and return_priority() functions.
* functions_db.php: Added smal_event_table() to render a variable table
with latest events (filtered).
* pandora.css. Added pure and priority colors.
* estado_alertas.php: Fixed ACL problems.
* stado_generalagente.php: Graph of modules now represents modules that
has generated events. Old graph is not used anymore. Also display parent.
* estado_grupo.php: Border of boxes is now thicker.
* tactical.php: New screen, almost all code changed. Odometer is not used
anymore, added some new items, like module LAG meter, module sanity, and
other general metrics.
* ver_agente.php: Now renders also event for each agent view. Alert manual
validation generate a new event.
* events.php: New event system. 90% new code. A LOT of new features,
including full screen, coloured (by priority) and filters by six fields.
* snmp_alert.php: Added support for alert priority.
* operation/users/user.php: No longer a user with UM privileges could
see any other user.
* render_view.php: Added fullscreen support for visual maps.
* fgraph.php: Added support for session checking in graphs (at least!).
New graphics for events (some changed it's function like events by group),
and feature added to progress GD implementation.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@860 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-13 18:59:54 +02:00
|
|
|
|
2014-11-04 18:17:38 +01:00
|
|
|
$options['consoles_list']['text'] =
|
2016-05-18 11:40:20 +02:00
|
|
|
'<a href="index.php?sec=network&sec2=godmode/reporting/map_builder&refr=' . $refr . '">' .
|
2014-11-04 18:17:38 +01:00
|
|
|
html_print_image ("images/visual_console.png", true,
|
|
|
|
array ("title" => __('Visual consoles list'))) . '</a>';
|
2013-04-18 11:25:23 +02:00
|
|
|
|
2015-04-09 14:05:23 +02:00
|
|
|
if ($vconsole_write || $vconsole_manage) {
|
2016-05-18 11:40:20 +02:00
|
|
|
$url_base = 'index.php?sec=network&sec2=godmode/reporting/visual_console_builder&action=';
|
2013-04-18 11:25:23 +02:00
|
|
|
|
2014-11-04 18:17:38 +01:00
|
|
|
$hash = md5($config["dbpass"] . $id_layout . $config["id_user"]);
|
2013-04-18 11:25:23 +02:00
|
|
|
|
2017-03-03 12:50:03 +01:00
|
|
|
$options['public_link']['text'] = '<a href="' .
|
|
|
|
ui_get_full_url('operation/visual_console/public_console.php?hash=' .
|
|
|
|
$hash.'&id_layout='.$id_layout.'&id_user='.$config["id_user"]) .
|
|
|
|
'" target="_blank">'.
|
2014-11-04 18:17:38 +01:00
|
|
|
html_print_image ("images/camera_mc.png", true,
|
|
|
|
array ("title" => __('Show link to public Visual Console'))).'</a>';
|
2013-04-10 09:57:54 +02:00
|
|
|
$options['public_link']['active'] = false;
|
2013-04-11 13:13:44 +02:00
|
|
|
|
|
|
|
$options['data']['text'] = '<a href="' . $url_base . $action . '&tab=data&id_visual_console=' . $id_layout . '">' .
|
2014-11-04 18:17:38 +01:00
|
|
|
html_print_image ("images/op_reporting.png", true,
|
|
|
|
array ("title" => __('Main data'))) .'</a>';
|
2013-04-11 13:13:44 +02:00
|
|
|
$options['list_elements']['text'] = '<a href="' . $url_base . $action . '&tab=list_elements&id_visual_console=' . $id_layout . '">' .
|
2014-11-04 18:17:38 +01:00
|
|
|
html_print_image ("images/list.png", true,
|
|
|
|
array ("title" => __('List elements'))) .'</a>';
|
|
|
|
|
2014-08-27 19:09:07 +02:00
|
|
|
if (enterprise_installed()) {
|
|
|
|
$options['wizard_services']['text'] = '<a href="' . $url_base . $action . '&tab=wizard_services&id_visual_console=' . $id_layout . '">' .
|
2014-11-04 18:17:38 +01:00
|
|
|
html_print_image ("images/wand_services.png", true,
|
|
|
|
array ("title" => __('Services wizard'))) .'</a>';
|
2014-08-27 19:09:07 +02:00
|
|
|
}
|
2014-11-04 18:17:38 +01:00
|
|
|
|
2013-04-11 13:13:44 +02:00
|
|
|
$options['wizard']['text'] = '<a href="' . $url_base . $action . '&tab=wizard&id_visual_console=' . $id_layout . '">' .
|
2014-11-04 18:17:38 +01:00
|
|
|
html_print_image ("images/wand.png", true,
|
|
|
|
array ("title" => __('Wizard'))) .'</a>';
|
2013-04-11 13:13:44 +02:00
|
|
|
$options['editor']['text'] = '<a href="' . $url_base . $action . '&tab=editor&id_visual_console=' . $id_layout . '">' .
|
2014-11-04 18:17:38 +01:00
|
|
|
html_print_image ("images/builder.png", true,
|
|
|
|
array ("title" => __('Builder'))) .'</a>';
|
2010-09-29 16:44:03 +02:00
|
|
|
}
|
|
|
|
|
2016-11-21 15:19:48 +01:00
|
|
|
$options['view']['text'] = '<a href="index.php?sec=network&sec2=operation/visual_console/render_view&id=' . $id_layout . '&refr=' . $view_refresh . '">'
|
2016-05-25 13:36:21 +02:00
|
|
|
. html_print_image("images/operation.png", true, array ("title" => __('View'))) .'</a>';
|
2013-04-11 13:13:44 +02:00
|
|
|
$options['view']['active'] = true;
|
|
|
|
|
2016-08-31 14:39:51 +02:00
|
|
|
if (!is_metaconsole()) {
|
2016-05-25 13:36:21 +02:00
|
|
|
if (!$config['pure']) {
|
2016-11-21 15:19:48 +01:00
|
|
|
$options['pure']['text'] = '<a href="index.php?sec=network&sec2=operation/visual_console/render_view&id='.$id_layout.'&refr='.$refr.'&pure=1">'
|
2016-05-25 13:36:21 +02:00
|
|
|
. html_print_image('images/full_screen.png', true, array('title' => __('Full screen mode')))
|
2012-12-11 Miguel de Dios <miguel.dedios@artica.es>
* extras/pandoradb_migrate_4.0.x_to_5.0.mysql.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.oracle.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.postgreSQL.sql, pandoradb.sql,
pandoradb.postgreSQL.sql, pandoradb.oracle.sql: in the table
"tlayout_data" added the column "id_metaconsole" for to show
visualmaps in the metaconsole.
* operation/visual_console/render_view.php,
include/functions_visual_map.php, operation/agentes/ver_agente.php,
godmode/reporting/visual_console_builder.wizard.php,
godmode/reporting/visual_console_builder.php,
godmode/reporting/visual_console_builder.data.php,
godmode/reporting/visual_console_builder.editor.js,
godmode/reporting/visual_console_builder.elements.php,
godmode/reporting/visual_console_builder.editor.php,
godmode/reporting/map_builder.php,
include/ajax/visual_console_builder.ajax.php,
include/ajax/agent.php, include/functions_visual_map_editor.php,
* operation/agentes/datos_agente.php,
include/functions_netflow.php: cleaned source code style.
* include/functions_ui.php: in function
"ui_require_javascript_file_enterprise" fixed when need a
enterprise javascript instead metaconsole enterprise path.
* include/javascript/pandora.js: fixed the function
"agent_changed_by_multiple_agents" that needs in the metaconsole.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7258 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-12-11 16:01:45 +01:00
|
|
|
. "</a>";
|
2016-05-25 13:36:21 +02:00
|
|
|
ui_print_page_header($layout_name, 'images/visual_console.png', false, '', false, $options);
|
2012-12-11 Miguel de Dios <miguel.dedios@artica.es>
* extras/pandoradb_migrate_4.0.x_to_5.0.mysql.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.oracle.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.postgreSQL.sql, pandoradb.sql,
pandoradb.postgreSQL.sql, pandoradb.oracle.sql: in the table
"tlayout_data" added the column "id_metaconsole" for to show
visualmaps in the metaconsole.
* operation/visual_console/render_view.php,
include/functions_visual_map.php, operation/agentes/ver_agente.php,
godmode/reporting/visual_console_builder.wizard.php,
godmode/reporting/visual_console_builder.php,
godmode/reporting/visual_console_builder.data.php,
godmode/reporting/visual_console_builder.editor.js,
godmode/reporting/visual_console_builder.elements.php,
godmode/reporting/visual_console_builder.editor.php,
godmode/reporting/map_builder.php,
include/ajax/visual_console_builder.ajax.php,
include/ajax/agent.php, include/functions_visual_map_editor.php,
* operation/agentes/datos_agente.php,
include/functions_netflow.php: cleaned source code style.
* include/functions_ui.php: in function
"ui_require_javascript_file_enterprise" fixed when need a
enterprise javascript instead metaconsole enterprise path.
* include/javascript/pandora.js: fixed the function
"agent_changed_by_multiple_agents" that needs in the metaconsole.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7258 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-12-11 16:01:45 +01:00
|
|
|
}
|
2015-04-09 14:05:23 +02:00
|
|
|
//Set the hidden value for the javascript
|
2012-12-11 Miguel de Dios <miguel.dedios@artica.es>
* extras/pandoradb_migrate_4.0.x_to_5.0.mysql.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.oracle.sql,
extras/pandoradb_migrate_4.0.x_to_5.0.postgreSQL.sql, pandoradb.sql,
pandoradb.postgreSQL.sql, pandoradb.oracle.sql: in the table
"tlayout_data" added the column "id_metaconsole" for to show
visualmaps in the metaconsole.
* operation/visual_console/render_view.php,
include/functions_visual_map.php, operation/agentes/ver_agente.php,
godmode/reporting/visual_console_builder.wizard.php,
godmode/reporting/visual_console_builder.php,
godmode/reporting/visual_console_builder.data.php,
godmode/reporting/visual_console_builder.editor.js,
godmode/reporting/visual_console_builder.elements.php,
godmode/reporting/visual_console_builder.editor.php,
godmode/reporting/map_builder.php,
include/ajax/visual_console_builder.ajax.php,
include/ajax/agent.php, include/functions_visual_map_editor.php,
* operation/agentes/datos_agente.php,
include/functions_netflow.php: cleaned source code style.
* include/functions_ui.php: in function
"ui_require_javascript_file_enterprise" fixed when need a
enterprise javascript instead metaconsole enterprise path.
* include/javascript/pandora.js: fixed the function
"agent_changed_by_multiple_agents" that needs in the metaconsole.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7258 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-12-11 16:01:45 +01:00
|
|
|
html_print_input_hidden('metaconsole', 0);
|
|
|
|
}
|
2015-04-09 14:05:23 +02:00
|
|
|
else {
|
|
|
|
//Set the hidden value for the javascript
|
|
|
|
html_print_input_hidden('metaconsole', 1);
|
|
|
|
}
|
2014-11-04 18:17:38 +01:00
|
|
|
|
2016-05-25 13:36:21 +02:00
|
|
|
if ($config['pure']) {
|
|
|
|
// Container of the visual map (ajax loaded)
|
2016-08-31 14:39:51 +02:00
|
|
|
echo '<div id="vc-container">' .
|
|
|
|
visual_map_print_visual_map ($id_layout, true, true,
|
2017-03-02 15:50:05 +01:00
|
|
|
null, null, '', false, true)
|
2016-08-31 14:39:51 +02:00
|
|
|
. '</div>';
|
2016-05-25 13:36:21 +02:00
|
|
|
|
|
|
|
// Floating menu - Start
|
2017-03-03 11:37:51 +01:00
|
|
|
echo '<div id="vc-controls" style="z-index: 999">';
|
2007-05-20 19:12:31 +02:00
|
|
|
|
2016-05-25 13:36:21 +02:00
|
|
|
echo '<div id="menu_tab">';
|
|
|
|
echo '<ul class="mn">';
|
2014-11-04 18:17:38 +01:00
|
|
|
|
2016-05-25 13:36:21 +02:00
|
|
|
// Quit fullscreen
|
|
|
|
echo '<li class="nomn">';
|
2016-11-21 15:19:48 +01:00
|
|
|
echo '<a href="index.php?sec=network&sec2=operation/visual_console/render_view&id='.$id_layout.'&refr='.$refr.'">';
|
2016-05-25 13:36:21 +02:00
|
|
|
echo html_print_image('images/normal_screen.png', true, array('title' => __('Back to normal mode')));
|
|
|
|
echo '</a>';
|
|
|
|
echo '</li>';
|
2014-11-04 18:17:38 +01:00
|
|
|
|
2016-05-25 13:36:21 +02:00
|
|
|
// Countdown
|
|
|
|
echo '<li class="nomn">';
|
|
|
|
echo '<div class="vc-refr">';
|
|
|
|
echo '<div class="vc-countdown"></div>';
|
|
|
|
echo '<div id="vc-refr-form">';
|
|
|
|
echo __('Refresh') . ':';
|
|
|
|
echo html_print_select(get_refresh_time_array(), 'refr', $refr, '', '', 0, true, false, false);
|
2014-01-23 16:51:25 +01:00
|
|
|
echo '</div>';
|
2016-05-25 13:36:21 +02:00
|
|
|
echo '</div>';
|
|
|
|
echo '</li>';
|
|
|
|
|
|
|
|
// Console name
|
|
|
|
echo '<li class="nomn">';
|
|
|
|
echo '<div class="vc-title">' . $layout_name . '</div>';
|
|
|
|
echo '</li>';
|
|
|
|
|
|
|
|
echo '</ul>';
|
|
|
|
echo '</div>';
|
|
|
|
|
|
|
|
echo '</div>';
|
|
|
|
// Floating menu - End
|
2014-01-23 16:51:25 +01:00
|
|
|
|
2016-05-25 13:36:21 +02:00
|
|
|
ui_require_jquery_file('countdown');
|
|
|
|
ui_require_css_file('countdown');
|
2014-01-23 16:51:25 +01:00
|
|
|
|
|
|
|
?>
|
2016-05-25 13:36:21 +02:00
|
|
|
<style type="text/css">
|
|
|
|
/* Avoid the main_pure container 1000px height */
|
|
|
|
body.pure {
|
|
|
|
min-height: 100px;
|
2017-05-16 12:36:58 +02:00
|
|
|
margin: 0px;
|
|
|
|
overflow: hidden;
|
|
|
|
height: 100%;
|
2017-04-27 13:28:49 +02:00
|
|
|
<?php
|
|
|
|
echo "background-color: ".$layout['background_color'].";";
|
|
|
|
?>
|
2014-01-23 16:51:25 +01:00
|
|
|
}
|
2016-05-25 13:36:21 +02:00
|
|
|
div#main_pure {
|
|
|
|
height: 100%;
|
|
|
|
margin: 0px;
|
2017-04-27 13:28:49 +02:00
|
|
|
<?php
|
|
|
|
echo "background-color: ".$layout['background_color'].";";
|
|
|
|
?>
|
2016-05-25 13:36:21 +02:00
|
|
|
}
|
|
|
|
</style>
|
2014-01-23 16:51:25 +01:00
|
|
|
<?php
|
|
|
|
}
|
2016-05-25 13:36:21 +02:00
|
|
|
else {
|
2017-03-02 15:50:05 +01:00
|
|
|
visual_map_print_visual_map ($id_layout, true, true, null, null, '', false, true, true);
|
2016-05-25 13:36:21 +02:00
|
|
|
}
|
2009-02-05 11:21:10 +01:00
|
|
|
|
2016-05-25 13:36:21 +02:00
|
|
|
ui_require_javascript_file('wz_jsgraphics');
|
|
|
|
ui_require_javascript_file('pandora_visual_console');
|
2016-09-08 09:50:13 +02:00
|
|
|
$ignored_params['refr'] = '';
|
2009-02-05 11:21:10 +01:00
|
|
|
?>
|
2016-05-25 13:36:21 +02:00
|
|
|
|
2008-06-26 Esteban Sanchez <estebans@artica.es>
* ajax.php: Sed id_user in config array.
* godmode/menu.php, general/header.php, operation/menu.php: Replaced
lang_label with lang_string().
* general/logon_ok.php: Reduced one indentation level.
* godmode/agentes/agent_manager.php: Replaced lang_label with
lang_string(). Use pandora functions.
* include/functions_html.php, godmode/agentes/configurar_agente.php:
Tab and blankspaces style correction.
* godmode/reporting/map_builder.php: Complete rewritten to provide an
intuitive way of build the maps. It's cool, useful and very simple.
* godmode/reporting/reporting_builder.php: Deleted an output debug.
* godmode/setup/setup.php: Rewritten to use pandora functions. Added a
colorpicker for color settings.
* include/config.php: Reset pandora password. We must solve things
with this file...
* include/functions.php: Check if input is an array on safe_input().
Use filename as id in array returned by list_files().
* include/functions_db.php: Renamed return_coordinate_* functions.
Style correction.
* include/javascript/jquery.js: Updated to 1.2.6.
* include/javascript/jquery.ui.datepicker.js: Code minimized.
* include/javascript/pandora.js: Style correction.
* include/javascript/wz_jsgraphics.js: Added a class to the elements
of a line, so it can be modified using javascript.
* /include/styles/pandora.css: Added style to some tables dropdowns.
Added new styles relative to visual map editor.
* operation/reporting/reporting_viewer.php: Style correction. Added
jQuery UI.
* operation/visual_console/index.php: Use Pandora functions.
* operation/visual_console/render_view.php: Drawing the map is now on
functions_visual_map.php. Added a countdown if a refresh time is set.
Use pandora functions. Style correction.
* reporting/fgraph.php: Style correction. Use graphic_error() if
there's no data on grafico_modulo_sparse().
* images/trash.png: Added to repository. Image used on trash area on
visual map editor.
* images/console/background/africa.jpg,
images/console/background/asia.jpg,
images/console/background/europe.jpg,
images/console/background/north_america.jpg,
images/console/background/oceania.jpg,
images/console/background/shouth_america.jpg,
images/console/background/world.jpg: Added to repository. Useful and
cool map backgrounds.
* include/functions_visual_map.php: Added to repository. Implements
visual map functions like drawing the map.
* include/javascript/jquery.colorpicker.js: Added to repository.
Implements a color picker widget.
* /include/javascript/jquery.countdown.js: Added to repository.
Implements a countdown widget.
* include/javascript/jquery.ui.core.js: Added to repository. jQuery UI
core.
* include/javascript/jquery.ui.draggable.js: Added to repository.
jQuery draggable plugin.
* include/javascript/jquery.ui.droppable.js: Added to repository.
jQuery droppable plugin.
* include/javascript/pandora_visual_console.js: Added to repository.
Function useful to visual map interface.
* include/languages/countdown_*.js: Added to repository. Countdown
localization.
* include/languages/date_es_la.js, include/languages/date_gl.js,
include/languages/time_es_la.js, include/languages/time_gl.js: Added
to repository. Missing localizations.
* include/styles/color-picker.css: Added to repository. Colorpicker
style sheet.
* include/styles/countdown.css: Added to repository. Countdown style
sheet.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@899 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-06-26 15:26:48 +02:00
|
|
|
<script language="javascript" type="text/javascript">
|
2014-11-18 18:12:47 +01:00
|
|
|
$(document).ready (function () {
|
2016-09-08 09:50:13 +02:00
|
|
|
var refr = <?php echo (int)$refr; ?>;
|
2016-05-25 13:36:21 +02:00
|
|
|
var pure = <?php echo (int) $config['pure']; ?>;
|
2016-09-08 09:50:13 +02:00
|
|
|
var href = "<?php echo ui_get_url_refresh ($ignored_params); ?>";
|
2016-05-25 13:36:21 +02:00
|
|
|
if (pure) {
|
2016-09-08 09:50:13 +02:00
|
|
|
var startCountDown = function (duration, cb) {
|
|
|
|
$('div.vc-countdown').countdown('destroy');
|
|
|
|
if (!duration) return;
|
|
|
|
var t = new Date();
|
|
|
|
t.setTime(t.getTime() + duration * 1000);
|
|
|
|
$('div.vc-countdown').countdown({
|
|
|
|
until: t,
|
|
|
|
format: 'MS',
|
|
|
|
layout: '(%M%nn%M:%S%nn%S <?php echo __('Until refresh'); ?>) ',
|
|
|
|
alwaysExpire: true,
|
|
|
|
onExpiry: function () {
|
|
|
|
$('div.vc-countdown').countdown('destroy');
|
|
|
|
//cb();
|
|
|
|
url = js_html_entity_decode( href ) + duration;
|
2017-11-27 16:42:32 +01:00
|
|
|
$(document).attr ("location", url);
|
|
|
|
/*$.post(window.location.href.replace("refr=300","refr="+new_count), function(respuestaSolicitud){
|
2017-03-03 12:50:03 +01:00
|
|
|
$('#background_<?php echo $id_layout; ?>').html(respuestaSolicitud);
|
2017-01-16 13:31:56 +01:00
|
|
|
});
|
2017-11-27 16:42:32 +01:00
|
|
|
*/
|
2017-06-05 18:36:12 +02:00
|
|
|
$("#main_pure").css('background-color','<?php echo $layout['background_color']; ?>');
|
|
|
|
|
|
|
|
}
|
2016-09-08 09:50:13 +02:00
|
|
|
});
|
|
|
|
}
|
2016-05-25 13:36:21 +02:00
|
|
|
|
2016-09-08 09:50:13 +02:00
|
|
|
startCountDown(refr, false);
|
2017-05-26 12:55:37 +02:00
|
|
|
|
2016-09-08 09:50:13 +02:00
|
|
|
var controls = document.getElementById('vc-controls');
|
|
|
|
autoHideElement(controls, 1000);
|
|
|
|
|
|
|
|
$('select#refr').change(function (event) {
|
|
|
|
refr = Number.parseInt(event.target.value, 10);
|
2017-06-05 18:36:12 +02:00
|
|
|
new_count = event.target.value;
|
2016-09-08 09:50:13 +02:00
|
|
|
startCountDown(refr, false);
|
|
|
|
});
|
2016-05-25 13:36:21 +02:00
|
|
|
}
|
|
|
|
else {
|
|
|
|
$('#refr').change(function () {
|
|
|
|
$('#hidden-vc_refr').val($('#refr option:selected').val());
|
|
|
|
});
|
2014-11-18 18:12:47 +01:00
|
|
|
}
|
2016-11-18 17:19:33 +01:00
|
|
|
|
2017-03-03 12:50:03 +01:00
|
|
|
$(".module_graph .menu_graph").css('display','none');
|
2016-11-18 17:19:33 +01:00
|
|
|
|
2017-03-03 12:50:03 +01:00
|
|
|
$(".parent_graph").each( function() {
|
|
|
|
if ($(this).css('background-color') != 'rgb(255, 255, 255)')
|
|
|
|
$(this).css('color', '#999');
|
2017-01-16 13:31:56 +01:00
|
|
|
});
|
|
|
|
|
|
|
|
$(".overlay").removeClass("overlay").addClass("overlaydisabled");
|
2017-11-10 13:19:23 +01:00
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
$(window).load (function () {
|
2017-06-13 16:49:25 +02:00
|
|
|
$('.item:not(.icon) img:not(.b64img)').each( function() {
|
2017-03-03 12:50:03 +01:00
|
|
|
if ($(this).css('float')=='left' || $(this).css('float')=='right') {
|
2017-09-14 10:27:11 +02:00
|
|
|
if( $(this).parent()[0].tagName == 'DIV'){
|
|
|
|
$(this).css('margin-top',(parseInt($(this).parent().css('height'))/2-parseInt($(this).css('height'))/2)+'px');
|
|
|
|
}
|
|
|
|
else if ( $(this).parent()[0].tagName == 'A') {
|
|
|
|
$(this).css('margin-top',(parseInt($(this).parent().parent().css('height'))/2-parseInt($(this).css('height'))/2)+'px');
|
|
|
|
}
|
2017-03-03 12:50:03 +01:00
|
|
|
$(this).css('margin-left','');
|
2017-01-16 13:31:56 +01:00
|
|
|
}
|
2017-03-03 12:50:03 +01:00
|
|
|
else {
|
2017-06-22 11:55:30 +02:00
|
|
|
if(parseInt($(this).parent().parent().css('width'))/2-parseInt($(this).css('width'))/2 < 0){
|
|
|
|
$(this).css('margin-left','');
|
|
|
|
$(this).css('margin-top','');
|
|
|
|
} else {
|
2017-09-14 10:27:11 +02:00
|
|
|
if( $(this).parent()[0].tagName == 'DIV'){
|
|
|
|
$(this).css('margin-left',(parseInt($(this).parent().css('width'))/2-parseInt($(this).css('width'))/2)+'px');
|
|
|
|
}
|
|
|
|
else if ( $(this).parent()[0].tagName == 'A') {
|
|
|
|
$(this).css('margin-left',(parseInt($(this).parent().parent().css('width'))/2-parseInt($(this).css('width'))/2)+'px');
|
|
|
|
}
|
2017-06-22 11:55:30 +02:00
|
|
|
$(this).css('margin-top','');
|
|
|
|
}
|
2017-01-16 13:31:56 +01:00
|
|
|
}
|
2016-11-21 19:16:48 +01:00
|
|
|
});
|
|
|
|
|
2017-03-03 12:50:03 +01:00
|
|
|
$('.item > div').each( function() {
|
|
|
|
if ($(this).css('float')=='left' || $(this).css('float')=='right') {
|
2017-12-01 12:14:56 +01:00
|
|
|
if($(this).attr('id').indexOf('clock') || $(this).attr('id').indexOf('overlay')){
|
|
|
|
$(this).css('margin-top',(parseInt($(this).parent().css('height'))/2-parseInt($(this).css('height'))/2)+'px');
|
|
|
|
}
|
|
|
|
else{
|
|
|
|
$(this).css('margin-top',(parseInt($(this).parent().css('height'))/2-parseInt($(this).css('height'))/2-15)+'px');
|
|
|
|
}
|
2017-03-03 12:50:03 +01:00
|
|
|
$(this).css('margin-left','');
|
2017-01-16 13:31:56 +01:00
|
|
|
}
|
2017-03-03 12:50:03 +01:00
|
|
|
else {
|
2017-01-16 13:31:56 +01:00
|
|
|
$(this).css('margin-left',(parseInt($(this).parent().css('width'))/2-parseInt($(this).css('width'))/2)+'px');
|
|
|
|
$(this).css('margin-top','');
|
|
|
|
}
|
|
|
|
});
|
2016-11-21 19:16:48 +01:00
|
|
|
|
2017-03-03 12:50:03 +01:00
|
|
|
$('.item > a > div').each( function() {
|
|
|
|
if ($(this).css('float')=='left' || $(this).css('float')=='right') {
|
|
|
|
$(this).css('margin-top',(parseInt($(this).parent().parent().css('height'))/2-parseInt($(this).css('height'))/2-5)+'px');
|
|
|
|
$(this).css('margin-left','');
|
2017-01-16 13:31:56 +01:00
|
|
|
}
|
2017-03-03 12:50:03 +01:00
|
|
|
else {
|
2017-01-16 13:31:56 +01:00
|
|
|
$(this).css('margin-left',(parseInt($(this).parent().parent().css('width'))/2-parseInt($(this).css('width'))/2)+'px');
|
|
|
|
$(this).css('margin-top','');
|
|
|
|
}
|
|
|
|
});
|
2016-11-21 19:16:48 +01:00
|
|
|
|
2017-03-22 10:10:56 +01:00
|
|
|
$(".graph:not([class~='noresizevc'])").each(function(){
|
|
|
|
height = parseInt($(this).css("height")) - 30;
|
2017-03-03 11:25:27 +01:00
|
|
|
$(this).css('height', height);
|
|
|
|
});
|
2017-11-10 13:19:23 +01:00
|
|
|
|
2014-11-18 18:12:47 +01:00
|
|
|
});
|
2017-03-07 13:19:34 +01:00
|
|
|
</script>
|