Skip to content
Snippets Groups Projects
Commit c8ac70ba authored by Helmo's avatar Helmo
Browse files

space to tabs

parent f3c43b14
No related branches found
No related tags found
No related merge requests found
Pipeline #3592 passed
......@@ -39,17 +39,17 @@ class system {
if(!preg_match('/^[a-z]+$/', $service)) $app->error('Invalid service '.$service);
// Check the servers table to see which kinds of servers we actually have enabled.
// simple query cache
if($this->server_count===null) {
$this->server_count = $app->db->queryOneRecord("SELECT SUM(mail_server) as mail, SUM(web_server) AS web, SUM(dns_server) AS dns, SUM(file_server) AS file,
SUM(db_server) AS db, SUM(vserver_server) AS vserver, SUM(proxy_server) AS proxy, SUM(firewall_server) AS firewall, SUM(xmpp_server) AS xmpp
FROM `server` WHERE mirror_server_id = 0");
}
// Check if we have the service enabled.
if ($this->server_count[$service] == 0) {
return FALSE;
}
// Check the servers table to see which kinds of servers we actually have enabled.
// simple query cache
if($this->server_count === null) {
$this->server_count = $app->db->queryOneRecord("SELECT SUM(mail_server) as mail, SUM(web_server) AS web, SUM(dns_server) AS dns, SUM(file_server) AS file,
SUM(db_server) AS db, SUM(vserver_server) AS vserver, SUM(proxy_server) AS proxy, SUM(firewall_server) AS firewall, SUM(xmpp_server) AS xmpp
FROM `server` WHERE mirror_server_id = 0");
}
// Check if we have the service enabled.
if ($this->server_count[$service] == 0) {
return FALSE;
}
if(isset($_SESSION['s']['user']) && $_SESSION['s']['user']['typ'] == 'admin') return true; //* We do not check admin-users
......
......@@ -153,28 +153,28 @@ if($app->auth->get_client_limit($userid, 'fetchmail') != 0)
if ($app->system->has_service($userid, 'xmpp')) {
$items = array();
if($app->auth->get_client_limit($userid, 'xmpp_domain') != 0)
{
$items[] = array( 'title' => 'XMPP Domain',
'target' => 'content',
'link' => 'mail/xmpp_domain_list.php',
'html_id' => 'xmpp_domain_list');
}
if($app->auth->get_client_limit($userid, 'xmpp_user') != 0)
{
$items[] = array( 'title' => 'XMPP Account',
'target' => 'content',
'link' => 'mail/xmpp_user_list.php',
'html_id' => 'xmpp_user_list');
}
if(count($items))
{
$module['nav'][] = array( 'title' => 'Jabber / XMPP',
'open' => 1,
'items' => $items);
}
if($app->auth->get_client_limit($userid, 'xmpp_domain') != 0)
{
$items[] = array( 'title' => 'XMPP Domain',
'target' => 'content',
'link' => 'mail/xmpp_domain_list.php',
'html_id' => 'xmpp_domain_list');
}
if($app->auth->get_client_limit($userid, 'xmpp_user') != 0)
{
$items[] = array( 'title' => 'XMPP Account',
'target' => 'content',
'link' => 'mail/xmpp_user_list.php',
'html_id' => 'xmpp_user_list');
}
if(count($items))
{
$module['nav'][] = array( 'title' => 'Jabber / XMPP',
'open' => 1,
'items' => $items);
}
}
//**** Statistics menu
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment