2012-04-23 Miguel de Dios <miguel.dedios@artica.es>

* index.php: fixed notice message php.
	
	* extensions/update_manager/lib/libupdate_manager.php: fixed into
	the function "um_db_load_settings" the cache of DB, and set to
	translate some untranslate text.
	
	* include/config_process.php: added for a long time the setting the
	$develop_bypass as global.
	
	* extensions/update_manager/settings.php, operation/menu.php,
	operation/search_agents.php: cleaned source code style.
	
	* include/functions_config.php: fixed php noticie message of the
	var "$config['update_manager_installed']" in the first execution
	after intallation.
	
	MERGED FROM 4.0.2




git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6106 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
mdtrooper 2012-04-23 14:29:34 +00:00
parent e1cab9b8b4
commit 64eaaf4927
7 changed files with 49 additions and 20 deletions

View File

@ -1,3 +1,23 @@
2012-04-23 Miguel de Dios <miguel.dedios@artica.es>
* index.php: fixed notice message php.
* extensions/update_manager/lib/libupdate_manager.php: fixed into
the function "um_db_load_settings" the cache of DB, and set to
translate some untranslate text.
* include/config_process.php: added for a long time the setting the
$develop_bypass as global.
* extensions/update_manager/settings.php, operation/menu.php,
operation/search_agents.php: cleaned source code style.
* include/functions_config.php: fixed php noticie message of the
var "$config['update_manager_installed']" in the first execution
after intallation.
MERGED FROM 4.0.2
2012-04-23 Sergio Martin <sergio.martin@artica.es>
* include/functions_networkmap.php

View File

@ -20,8 +20,10 @@ require_once ('libupdate_manager_components.php');
require_once ('libupdate_manager_client.php');
function um_db_load_settings () {
$result = db_process_sql('SELECT * FROM '.DB_PREFIX.'tupdate_settings');
if($result === false) {
db_clean_cache();
$result = db_get_all_rows_in_table(DB_PREFIX . 'tupdate_settings');
if ($result === false) {
echo '<strong>Error reading settings</strong><br />';
return NULL;
}
@ -54,7 +56,7 @@ function um_db_update_setting ($key, $value = '') {
}
if ($result === false) {
echo '<strong>Error reading settings</strong> <br />';
echo '<strong>' . __('Error reading settings') . '</strong> <br />';
return NULL;
}
@ -72,7 +74,7 @@ function um_db_update_setting ($key, $value = '') {
}
if ($result === false) {
echo '<strong>Error updating settings</strong> <br />';
echo '<strong>' . __('Error updating settings') . '</strong> <br />';
return false;
}
}
@ -90,7 +92,7 @@ function um_db_update_setting ($key, $value = '') {
}
if ($result === false) {
echo '<strong>Error creating settings</strong> <br />';
echo '<strong>' . __('Error creating settings') . '</strong> <br />';
return false;
}
}

View File

@ -25,7 +25,7 @@ if (! check_acl ($config['id_user'], 0, 'PM')) {
include_once ("extensions/update_manager/lib/functions.php");
um_db_connect ('mysql', $config['dbhost'], $config['dbuser'],
$config['dbpass'], $config['dbname']);
$config['dbpass'], $config['dbname']);
$update_settings = (bool) get_parameter_post ('update_settings');
@ -55,9 +55,10 @@ if ($update_settings) {
update_pandora_update_conf();
}
echo "<h3 class=suc>".__('Update manager settings updated')."</h3>";
echo "<h3 class=suc>" . __('Update manager settings updated') . "</h3>";
}
$settings = null;
$settings = um_db_load_settings ();
echo '<form method="post">';

View File

@ -27,6 +27,7 @@ $pandora_version = 'v5.0-dev';
date_default_timezone_set("Europe/Berlin");
global $develop_bypass;
/* Help to debug problems. Override global PHP configuration */
if (!isset($develop_bypass)) $develop_bypass = 0;

View File

@ -770,15 +770,17 @@ function config_check (){
}
}
else {
if ($config['update_manager_installed'] == 1) {
require_once("extensions/update_manager/lib/functions.ajax.php");
$result_check_keygen = check_keygen_online();
if (!empty($result_check_keygen)) {
$config["alert_cnt"]++;
$_SESSION["alert_msg"] .= $result_check_keygen;
}
if (isset($config['update_manager_installed'])) {
if ($config['update_manager_installed'] == 1) {
require_once("extensions/update_manager/lib/functions.ajax.php");
$result_check_keygen = check_keygen_online();
if (!empty($result_check_keygen)) {
$config["alert_cnt"]++;
$_SESSION["alert_msg"] .= $result_check_keygen;
}
}
}
}
}

View File

@ -281,7 +281,9 @@ if ($process_login) {
//Get old parameters before navigation.
$old_sec = '';
$old_sec2 = '';
$old_page = $_SERVER['HTTP_REFERER'];
$old_page = '';
if (isset($_SERVER['HTTP_REFERER']))
$old_page = $_SERVER['HTTP_REFERER'];
$chunks = explode('?', $old_page);
if (count($chunks) == 2) {
$chunks = explode('&', $chunks[1]);

View File

@ -191,9 +191,10 @@ if (check_acl ($config['id_user'], 0, "AR")) {
$sub["godmode/reporting/graphs"]["text"] = __('Custom graphs');
//Set godomode path
$sub["godmode/reporting/graphs"]["subsecs"] = array("operation/reporting/graph_viewer",
"godmode/reporting/graph_builder");
$sub["godmode/reporting/graphs"]["subsecs"] = array(
"operation/reporting/graph_viewer",
"godmode/reporting/graph_builder");
$sub["operation/agentes/exportdata"]["text"] = __('Export data');
$sub["operation/agentes/exportdata"]["subsecs"] = array("operation/agentes/exportdata");