diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index d704d6edc4..97e312f4b4 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,15 @@ +2012-04-13 Miguel de Dios + + * include/functions_config.php, index.php, + extensions/update_manager/lib/functions.ajax.php, + extensions/update_manager/lib/functions.php, + extensions/update_manager/main.php, + extensions/update_manager/update_pandora.php, + general/logon_ok.php:: some fixeds and some changes for run fine and + pretty the update manager. + + Merged from the branch "pandora_4.0" + 2012-04-13 Junichi Satoh * godmode/alerts/configure_alert_compound.php: Added special days diff --git a/pandora_console/extensions/update_manager/lib/functions.ajax.php b/pandora_console/extensions/update_manager/lib/functions.ajax.php index 38d8ede4d6..31eb3d8707 100644 --- a/pandora_console/extensions/update_manager/lib/functions.ajax.php +++ b/pandora_console/extensions/update_manager/lib/functions.ajax.php @@ -131,7 +131,7 @@ function update_pandora_download_package() { if ($conf_update_pandora['download_mode'] == 'wget') { $command = "wget " . - $package_url . " -P " . $dir . + $package_url . " -O " . $dir . $package . " -o /tmp/" . $package . ".info.txt"; $return = array('correct' => 0); diff --git a/pandora_console/extensions/update_manager/lib/functions.php b/pandora_console/extensions/update_manager/lib/functions.php index 5342a97517..a3ae23e025 100644 --- a/pandora_console/extensions/update_manager/lib/functions.php +++ b/pandora_console/extensions/update_manager/lib/functions.php @@ -143,11 +143,13 @@ function update_pandora_get_list_downloaded_packages($mode = 'operation') { if (empty($packages)) { if ($mode == 'operation') { $packages[] = array('name' => - __('There are not downloaded packages in your Pandora Console.')); + __('There are not downloaded packages in your Pandora Console.'), + 'time' => ''); } else { $packages[] = array('empty' => true, 'name' => - __('There are not downloaded packages in your Pandora Console.')); + __('There are not downloaded packages in your Pandora Console.'), + 'time' => ''); } } @@ -233,7 +235,7 @@ function update_pandora_print_javascript_admin() { draggable: false, modal: true, height: 400, - width: 600, + width: 650, overlay: { opacity: 0.5, background: "black" @@ -258,7 +260,7 @@ function update_pandora_print_javascript_admin() { draggable: true, modal: true, height: 400, - width: 600, + width: 650, overlay: { opacity: 0.5, background: "black" @@ -336,6 +338,7 @@ function update_pandora_print_javascript_admin() { $("#info_text").html(''); + $("#button_close_download_disabled").hide(); $("#button_close_download").show(); } } @@ -394,6 +397,7 @@ function update_pandora_print_javascript_admin() { else { $("#title_installing_update_pandora").hide(); $("#title_installed_update_pandora").show(); + $("#button_close_download_disabled").hide(); $("#button_close_download").show(); } } @@ -423,16 +427,15 @@ function update_pandora_print_javascript_admin() { $("tbody", "#online_packages").append( '' + - '' + - '' . __('There is a new version:') . ' '; ?>' + + '' + + '' . __('There is a new version:') . '

'; ?>' + data['package'] + '' + - '' + + '' + data['timestamp'] + '' + - '' + + '' + buttonUpdate + - ' ' + data['text_adv'] + '' + ''); diff --git a/pandora_console/extensions/update_manager/main.php b/pandora_console/extensions/update_manager/main.php index 40c5307a53..ba13795f0c 100644 --- a/pandora_console/extensions/update_manager/main.php +++ b/pandora_console/extensions/update_manager/main.php @@ -84,16 +84,12 @@ function main_view_enterprise($settings, $user_key) { } + echo '

'; + echo __('Your Pandora FMS Enterprise version number is') . ' ' . + $settings->current_update; + echo "

"; - $table = null; - $table->width = '98%'; - $table->style = array(); - $table->style[0] = 'font-weight: bolder; font-size: 20px;'; - $table->data = array(); - $table->data[0][0] = __('Your Pandora FMS Enterprise version number is') - . ' ' . $settings->current_update; - html_print_table($table); - + echo "

"; /* Translators: Do not translade Update Manager, it's the name of the program */ diff --git a/pandora_console/extensions/update_manager/update_pandora.php b/pandora_console/extensions/update_manager/update_pandora.php index 1fb24fb71f..177bd904d0 100644 --- a/pandora_console/extensions/update_manager/update_pandora.php +++ b/pandora_console/extensions/update_manager/update_pandora.php @@ -78,17 +78,20 @@ function update_pandora_administration($settings, $user_key) { } $conf_update_pandora = update_pandora_get_conf(); - - $table = null; - $table->width = '98%'; - $table->style = array(); - $table->style[0] = 'font-weight: bolder; font-size: 20px;'; - $table->data = array(); - $table->data[0][0] = __('Your Pandora FMS open source package installed is') . - ' ' . $conf_update_pandora['last_installed']; - html_print_table($table); - - + + if (!empty($conf_update_pandora['last_installed'])){ + echo '

'; + echo __('Your Pandora FMS open source package installed is') . + ' ' . $conf_update_pandora['last_installed']; + echo "

"; + } else { + echo '

'; + echo __('Your Pandora FMS does not have any update installed yet'); + echo "

"; + } + + echo "

"; + ui_print_info_message( '

' . __('This is a automatilly update Pandora Console only. Be careful if you have changed any php file of console, please make a backup this modified files php. Because the update action ovewrite all php files in Pandora console.') . @@ -97,13 +100,10 @@ function update_pandora_administration($settings, $user_key) { __('Update Manager sends anonymous information about Pandora FMS usage (number of agents and modules running). To disable it, just delete extension or remove remote server address from Update Manager plugin setup.') . '

' ); - - $table = null; - $table->width = '98%'; - $table->data = array(); - $table->data[0][0] = '

' . __('Online') . '

'; - $table->data[1][0] = - '' . + + echo "

". __('Online') . '

'; + + echo '
' . '' . '
' . @@ -113,22 +113,21 @@ function update_pandora_administration($settings, $user_key) {
'; - html_print_table($table); ?>