mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-28 08:14:38 +02:00
Fixed code
This commit is contained in:
parent
b75b55c0a5
commit
84902a5d3d
@ -196,6 +196,7 @@ function mainModuleGroups()
|
|||||||
ON ta.id_agente = tam.id_agente
|
ON ta.id_agente = tam.id_agente
|
||||||
WHERE ta.disabled = 0
|
WHERE ta.disabled = 0
|
||||||
AND tam.disabled = 0
|
AND tam.disabled = 0
|
||||||
|
AND tam.id_modulo <> 0
|
||||||
AND tam.delete_pending = 0
|
AND tam.delete_pending = 0
|
||||||
AND ta.id_grupo IN (%s)
|
AND ta.id_grupo IN (%s)
|
||||||
GROUP BY tam.id_agente_modulo
|
GROUP BY tam.id_agente_modulo
|
||||||
|
@ -1,28 +1,42 @@
|
|||||||
<?php
|
<?php
|
||||||
|
/**
|
||||||
|
* Resource registration.
|
||||||
|
*
|
||||||
|
* @category Extensions
|
||||||
|
* @package Pandora FMS
|
||||||
|
* @subpackage Community
|
||||||
|
* @version 1.0.0
|
||||||
|
* @license See below
|
||||||
|
*
|
||||||
|
* ______ ___ _______ _______ ________
|
||||||
|
* | __ \.-----.--.--.--| |.-----.----.-----. | ___| | | __|
|
||||||
|
* | __/| _ | | _ || _ | _| _ | | ___| |__ |
|
||||||
|
* |___| |___._|__|__|_____||_____|__| |___._| |___| |__|_|__|_______|
|
||||||
|
*
|
||||||
|
* ============================================================================
|
||||||
|
* Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
||||||
|
* Please see http://pandorafms.org for full contribution list
|
||||||
|
* This program is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU General Public License
|
||||||
|
* as published by the Free Software Foundation for version 2.
|
||||||
|
* 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.
|
||||||
|
* ============================================================================
|
||||||
|
*/
|
||||||
|
|
||||||
// Pandora FMS - http://pandorafms.com
|
/**
|
||||||
// ==================================================
|
* Remember the hard-coded values.
|
||||||
// Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
* -- id_modulo now uses tmodule.
|
||||||
// Please see http://pandorafms.org for full contribution list
|
* -- ---------------------------.
|
||||||
// This program is free software; you can redistribute it and/or
|
* -- 1 - Data server modules (agent related modules)
|
||||||
// modify it under the terms of the GNU General Public License
|
* -- 2 - Network server modules
|
||||||
// as published by the Free Software Foundation; version 2
|
* -- 4 - Plugin server
|
||||||
// This program is distributed in the hope that it will be useful,
|
* -- 5 - Predictive server
|
||||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
* -- 6 - WMI server
|
||||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
* -- 7 - WEB Server (enteprise)
|
||||||
// GNU General Public License for more details.
|
* In the xml is the tag "module_source"
|
||||||
// Remember the hard-coded values
|
|
||||||
/*
|
|
||||||
-- id_modulo now uses tmodule
|
|
||||||
-- ---------------------------
|
|
||||||
-- 1 - Data server modules (agent related modules)
|
|
||||||
-- 2 - Network server modules
|
|
||||||
-- 4 - Plugin server
|
|
||||||
-- 5 - Predictive server
|
|
||||||
-- 6 - WMI server
|
|
||||||
-- 7 - WEB Server (enteprise)
|
|
||||||
|
|
||||||
In the xml is the tag "module_source"
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
require_once $config['homedir'].'/include/functions_agents.php';
|
require_once $config['homedir'].'/include/functions_agents.php';
|
||||||
@ -1097,8 +1111,14 @@ function resource_registration_extension_main()
|
|||||||
|
|
||||||
$xml = simplexml_load_file($_FILES['resource_upload']['tmp_name'], null, LIBXML_NOCDATA);
|
$xml = simplexml_load_file($_FILES['resource_upload']['tmp_name'], null, LIBXML_NOCDATA);
|
||||||
|
|
||||||
|
if ($xml === false) {
|
||||||
|
ui_print_error_message(
|
||||||
|
__('Error uploading resource. Check if the selected file is a valid resource template in .ptr format')
|
||||||
|
);
|
||||||
|
} else {
|
||||||
process_upload_xml($xml);
|
process_upload_xml($xml);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
extensions_add_godmode_menu_option(__('Resource registration'), 'PM', 'gagente', '', 'v1r1');
|
extensions_add_godmode_menu_option(__('Resource registration'), 'PM', 'gagente', '', 'v1r1');
|
||||||
|
@ -1,17 +1,32 @@
|
|||||||
<?php
|
<?php
|
||||||
|
/**
|
||||||
|
* Common editor fields.
|
||||||
|
*
|
||||||
|
* @category Module manager
|
||||||
|
* @package Pandora FMS
|
||||||
|
* @subpackage Community
|
||||||
|
* @version 1.0.0
|
||||||
|
* @license See below
|
||||||
|
*
|
||||||
|
* ______ ___ _______ _______ ________
|
||||||
|
* | __ \.-----.--.--.--| |.-----.----.-----. | ___| | | __|
|
||||||
|
* | __/| _ | | _ || _ | _| _ | | ___| |__ |
|
||||||
|
* |___| |___._|__|__|_____||_____|__| |___._| |___| |__|_|__|_______|
|
||||||
|
*
|
||||||
|
* ============================================================================
|
||||||
|
* Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
||||||
|
* Please see http://pandorafms.org for full contribution list
|
||||||
|
* This program is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU General Public License
|
||||||
|
* as published by the Free Software Foundation for version 2.
|
||||||
|
* 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.
|
||||||
|
* ============================================================================
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Begin
|
||||||
// Pandora FMS - http://pandorafms.com
|
|
||||||
// ==================================================
|
|
||||||
// Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
|
||||||
// Please see http://pandorafms.org for full contribution list
|
|
||||||
// This program is free software; you can redistribute it and/or
|
|
||||||
// modify it under the terms of the GNU General Public License
|
|
||||||
// as published by the Free Software Foundation for version 2.
|
|
||||||
// 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.
|
|
||||||
require_once $config['homedir'].'/include/functions_modules.php';
|
require_once $config['homedir'].'/include/functions_modules.php';
|
||||||
require_once $config['homedir'].'/include/functions_categories.php';
|
require_once $config['homedir'].'/include/functions_categories.php';
|
||||||
require_once $config['homedir'].'/include/graphs/functions_d3.php';
|
require_once $config['homedir'].'/include/graphs/functions_d3.php';
|
||||||
@ -19,7 +34,9 @@ require_once $config['homedir'].'/include/graphs/functions_d3.php';
|
|||||||
include_javascript_d3();
|
include_javascript_d3();
|
||||||
|
|
||||||
|
|
||||||
global $config;function prepend_table_simple($row, $id=false)
|
global $config;
|
||||||
|
|
||||||
|
function prepend_table_simple($row, $id=false)
|
||||||
{
|
{
|
||||||
global $table_simple;
|
global $table_simple;
|
||||||
|
|
||||||
@ -115,7 +132,12 @@ function add_component_selection($id_network_component_type)
|
|||||||
'',
|
'',
|
||||||
'---'.__('Manual setup').'---',
|
'---'.__('Manual setup').'---',
|
||||||
0,
|
0,
|
||||||
true
|
true,
|
||||||
|
false,
|
||||||
|
true,
|
||||||
|
'',
|
||||||
|
false,
|
||||||
|
'width: 460px; '
|
||||||
);
|
);
|
||||||
$data[1] .= '</span>';
|
$data[1] .= '</span>';
|
||||||
$data[1] .= ' <span id="component_loading" class="invisible">';
|
$data[1] .= ' <span id="component_loading" class="invisible">';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user