2011-03-23 Miguel de Dios <miguel.dedios@artica.es>
* extensions/insert_data.php, extensions/system_info.php, extensions/agents_modules.php, extensions/ssh_console.php, extensions/resource_registration.php, extensions/resource_exportation.php, extensions/plugin_registration.php: re-ordered and re-cleaned some parts or lines of source code. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4123 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
b06ee0fdc5
commit
e46cfc566d
|
@ -1,3 +1,11 @@
|
|||
2011-03-23 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* extensions/insert_data.php, extensions/system_info.php,
|
||||
extensions/agents_modules.php, extensions/ssh_console.php,
|
||||
extensions/resource_registration.php, extensions/resource_exportation.php,
|
||||
extensions/plugin_registration.php: re-ordered and re-cleaned some parts or
|
||||
lines of source code.
|
||||
|
||||
2011-03-23 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* include/functions_reporting.php: fixed the include "fgraph", did'nt show
|
||||
|
|
|
@ -45,10 +45,8 @@ function createXMLData($agent, $agentModule, $time, $data) {
|
|||
function mainInsertData() {
|
||||
global $config;
|
||||
|
||||
|
||||
print_page_header (__("Insert data"), "images/extensions.png", false, "", true, "");
|
||||
|
||||
|
||||
if (! check_acl ($config['id_user'], 0, "AW") && ! is_user_admin ($config['id_user'])) {
|
||||
pandora_audit("ACL Violation", "Trying to access Setup Management");
|
||||
require ("general/noaccess.php");
|
||||
|
@ -91,6 +89,7 @@ function mainInsertData() {
|
|||
$file = file($csv['tmp_name']);
|
||||
foreach ($file as $line) {
|
||||
$tokens = explode(';', $line);
|
||||
|
||||
createXMLData($agent, $agentModule, trim($tokens[0]), trim($tokens[1]));
|
||||
}
|
||||
}
|
||||
|
@ -100,8 +99,6 @@ function mainInsertData() {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
echo '<div class="notify">';
|
||||
echo __("Please check that the directory \"/var/spool/pandora/data_in\" is writeable by the apache user. <br /><br />The CSV file format is date;value<newline>date;value<newline>... The date in CSV is in format Y/m/d H:i:s.");
|
||||
echo '</div>';
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
|
||||
function pluginreg_extension_main () {
|
||||
global $config;
|
||||
|
||||
if (! check_acl ($config['id_user'], 0, "PM") && ! is_user_admin ($config['id_user'])) {
|
||||
pandora_audit("ACL Violation", "Trying to access Setup Management");
|
||||
require ("general/noaccess.php");
|
||||
|
@ -49,7 +50,8 @@ function pluginreg_extension_main () {
|
|||
if (zip_entry_open($zip, $zip_entry, "r")) {
|
||||
if (zip_entry_name($zip_entry) == "plugin_definition.ini") {
|
||||
$basepath = $config["attachment_store"];
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
$basepath = $config["plugin_store"];
|
||||
}
|
||||
$filename = $basepath . "/". zip_entry_name($zip_entry);
|
||||
|
|
|
@ -232,6 +232,7 @@ function mainSystemInfo() {
|
|||
if (! check_acl ($config['id_user'], 0, "PM") && ! is_user_admin ($config['id_user'])) {
|
||||
pandora_audit("ACL Violation", "Trying to access Setup Management");
|
||||
require ("general/noaccess.php");
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -309,7 +310,6 @@ function mainSystemInfo() {
|
|||
$tempDir = $tempDirSystem . '/' . $nameDir . '/';
|
||||
mkdir($tempDir);
|
||||
|
||||
|
||||
$zipArchive = $config['attachment_store'] . '/last_info.zip';
|
||||
@unlink($zipArchive);
|
||||
|
||||
|
@ -397,23 +397,6 @@ function mainSystemInfo() {
|
|||
|
||||
$zip->close();
|
||||
}
|
||||
//
|
||||
// if ($pandora_diag) {
|
||||
// $info = array();
|
||||
// getPandoraDiagnostic($info);
|
||||
// show_array(__('Pandora Diagnostic info'), 'diag_info', $info);
|
||||
// }
|
||||
//
|
||||
// if ($system_info) {
|
||||
// $info = array();
|
||||
// getSystemInfo($info);
|
||||
// show_array(__('System info'), 'system_info', $info);
|
||||
// }
|
||||
//
|
||||
// if ($log_info) {
|
||||
// echo "<h1><a name='log_info'>" . __('Log Info') . "</a></h1>";
|
||||
// getLastLog($log_num_lines);
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue