Added header link to UM messages
This commit is contained in:
parent
fb9010675f
commit
62aab34c8f
|
@ -72,6 +72,21 @@ config_check();
|
|||
$table->styleTable = 'margin: auto; margin-top: 0px;';
|
||||
$table->rowclass[0] = '';
|
||||
|
||||
//UM messages
|
||||
if (is_user_admin ($config['id_user'])) {
|
||||
include_once ("include/functions_update_manager.php");
|
||||
$sql = 'SELECT COUNT(*) FROM tupdate WHERE data_rollback LIKE \'%"' . $config['id_user'] . '":1%\'';
|
||||
$number_read_messages = (int) db_get_sql ($sql);
|
||||
$sql = 'SELECT COUNT(*) FROM tupdate';
|
||||
$number_total_messages = (int) db_get_sql ($sql);
|
||||
$number_unread_messages = $number_total_messages - $number_read_messages;
|
||||
if ($number_unread_messages > 0) {
|
||||
$um_messages = html_print_image("images/header_email.png", true,
|
||||
array("alt" => 'cross', "class" => 'bot', 'title' => __('UM messages').': ' . $number_unread_messages . '/' . $number_total_messages));
|
||||
$table->data[0]['um'] = '<a href="index.php?sec=gsetup&sec2=godmode/update_manager/update_manager&tab=messages">' . $um_messages . "</a>";
|
||||
}
|
||||
}
|
||||
|
||||
// Search bar
|
||||
$search_bar = '<form method="get" style="display: inline;" name="quicksearch" action="">';
|
||||
if (!isset($config['search_keywords'])) {
|
||||
|
|
Loading…
Reference in New Issue