Minor fixes

Former-commit-id: 51e446b36a4ad2b93a1a2e3ff76e89ea2a21db9b
This commit is contained in:
fbsanchez 2019-05-16 12:00:49 +02:00
parent 3bf06f0b72
commit e7dbb55392
5 changed files with 42 additions and 98 deletions

View File

@ -214,71 +214,6 @@ if (!empty($all_data)) {
// END OF NEWS BOARD.
}
$nots = messages_get_overview(
'utimestamp',
'DESC',
false,
true,
0,
[
'description' => [
'messages',
'System status',
],
]
);
if (!empty($nots)) {
// Notifications board.
echo '<div id="notifications_board">';
echo '<table cellpadding="0" width=100% cellspacing="0" class="databox filters">';
echo '<tr><th style="text-align:center;"><span >'.__('Pending notifications').'</span></th></tr>';
if ($config['prominent_time'] == 'timestamp') {
$comparation_suffix = '';
} else {
$comparation_suffix = __('ago');
}
foreach ($nots as $msg) {
$conversation = io_safe_output(
messages_get_conversation($msg)
);
if (is_array($conversation)) {
$text = array_pop($conversation)['message'];
} else {
// Skip empty message.
continue;
}
$url = ui_get_full_url(
'index.php?sec=message_list&sec2=operation/messages/message_edit&read_message=1&id_message='.$msg['id_mensaje']
);
if ($msg['url'] != '') {
$url = $msg['url'];
}
echo '<tr><th class="green_title">'.$msg['subject'].'</th></tr>';
echo '<tr><td><a href="'.$url.'">';
if ($msg['id_usuario_origen'] != '') {
echo '<b>'.get_user_fullname($msg['id_usuario_origen']).'</b> ';
}
echo '<i>'.ui_print_timestamp($msg['timestamp'], true).'</i> '.$comparation_suffix.'</a></td></tr>';
echo '<tr><td class="datos">';
echo nl2br($text);
echo '</td></tr>';
}
echo '</table>';
echo '</div>';
echo '<br><br>';
// EO Notifications board.
}
// LAST ACTIVITY.
// Show last activity from this user.
echo '<div id="activity">';

View File

@ -102,7 +102,7 @@ if (is_ajax()) {
if ($cancel_newsletter) {
db_process_sql_update(
'tusuario',
['middlename' => 0],
['middlename' => -1],
['id_user' => $config['id_user']]
);
@ -133,7 +133,8 @@ $newsletter = db_get_value(
'tusuario',
'id_user',
$config['id_user']
) === null;
);
$show_newsletter = $newsletter == '0' || $newsletter == '';
$registration = isset($config['pandora_uid']) !== true
|| $config['pandora_uid'] == '';
@ -155,11 +156,11 @@ if ($registration) {
false,
// Launch only if not being launch from 'initial'.
!$initial,
(($newsletter === true) ? 'show_newsletter_wizard()' : null)
(($show_newsletter === true) ? 'show_newsletter_wizard()' : null)
);
}
if ($newsletter) {
if ($show_newsletter) {
// Show newsletter wizard for current user.
newsletter_wiz_modal(
false,

View File

@ -102,30 +102,37 @@ if (enterprise_installed()) {
echo '</div>';
}
echo '</form>';
echo '<div id="code_license_dialog" style="display: none; text-align: left;" title="'.__('Request new license').'">';
echo '<div id="logo">';
html_print_image(ui_get_custom_header_logo(true));
echo '</div>';
echo ''.__('To get your <b>%s Enterprise License</b>:', get_product_name()).'<br />';
echo '<ul>';
echo '<li>';
echo ''.sprintf(__('Go to %s'), '<a target="_blank" href="https://licensing.artica.es/pandoraupdate7/index.php?section=generate_key_client">https://licensing.artica.es/pandoraupdate7/index.php?section=generate_key_client</a>');
echo '</li>';
echo '<li>';
echo ''.__('Enter the <b>auth key</b> and the following <b>request key</b>:');
echo '</li>';
echo '</ul>';
echo '<div id="code"></div>';
echo '<ul>';
echo '<li>';
echo ''.__('Enter your name (or a company name) and a contact email address.');
echo '</li>';
echo '<li>';
echo ''.__('Click on <b>Generate</b>.');
echo '</li>';
echo '<li>';
echo ''.__('Click <a href="javascript: close_code_license_dialog();">here</a>, enter the generated license key and click on <b>Validate</b>.');
echo '</li>';
echo '</ul>';
echo '</div>';
if (enterprise_installed()) {
echo '<link rel="stylesheet" href="'.ui_get_full_url(false, false, false, false).'include/styles/pandora.css" type="text/css">';
echo '<link rel="stylesheet" href="'.ui_get_full_url(false, false, false, false).'enterprise/include/styles/pandora_enterprise.css" type="text/css">';
}
if (enterprise_hook('print_activate_licence_dialog') == ENTERPRISE_NOT_HOOK) {
echo '</form>';
echo '<div id="code_license_dialog" style="display: none; text-align: left;" title="'.__('Request new license').'">';
echo '<div id="logo">';
html_print_image(ui_get_custom_header_logo(true));
echo '</div>';
echo ''.__('To get your <b>%s Enterprise License</b>:', get_product_name()).'<br />';
echo '<ul>';
echo '<li>';
echo ''.sprintf(__('Go to %s'), '<a target="_blank" href="https://licensing.artica.es/pandoraupdate7/index.php?section=generate_key_client">https://licensing.artica.es/pandoraupdate7/index.php?section=generate_key_client</a>');
echo '</li>';
echo '<li>';
echo ''.__('Enter the <b>auth key</b> and the following <b>request key</b>:');
echo '</li>';
echo '</ul>';
echo '<div id="code"></div>';
echo '<ul>';
echo '<li>';
echo ''.__('Enter your name (or a company name) and a contact email address.');
echo '</li>';
echo '<li>';
echo ''.__('Click on <b>Generate</b>.');
echo '</li>';
echo '<li>';
echo ''.__('Click <a href="javascript: close_code_license_dialog();">here</a>, enter the generated license key and click on <b>Validate</b>.');
echo '</li>';
echo '</ul>';
echo '</div>';
}

View File

@ -2258,7 +2258,7 @@ class ConsoleSupervisor
}
// Only ask for messages once a day.
$future = (time() + 24 * SECONDS_1HOUR);
$future = (time() + 2 * SECONDS_1HOUR);
config_update_value('last_um_check', $future);
include_once $config['homedir'].'/include/functions_update_manager.php';

View File

@ -208,7 +208,8 @@ if (!isset($config['inventory_changes_blacklist'])) {
if (!isset($config['url_update_manager'])) {
config_update_value(
'url_update_manager',
'https://licensing.artica.es/pandoraupdate7/server.php'
//'https://licensing.artica.es/pandoraupdate7/server.php'
'https://172.17.0.3/server.php'
);
}