show current count of results besides total count in listings, fixes #869
Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
@@ -107,7 +107,7 @@ if ($page == 'admins' && $userinfo['change_serversettings'] == '1') {
|
||||
$count ++;
|
||||
}
|
||||
|
||||
$admincount = $paging->getEntries();
|
||||
$admincount = $result['count'] . " / " . $paging->getEntries();
|
||||
eval("echo \"" . \Froxlor\UI\Template::getTemplate("admins/admins") . "\";");
|
||||
} elseif ($action == 'su') {
|
||||
|
||||
|
||||
@@ -150,7 +150,7 @@ if ($page == 'customers' && $userinfo['customers'] != '0') {
|
||||
$count ++;
|
||||
}
|
||||
|
||||
$customercount = $paging->getEntries();
|
||||
$customercount = $result['count'] . " / " . $paging->getEntries();
|
||||
eval("echo \"" . \Froxlor\UI\Template::getTemplate("customers/customers") . "\";");
|
||||
} elseif ($action == 'su' && $id != 0) {
|
||||
try {
|
||||
|
||||
@@ -80,7 +80,7 @@ if ($page == 'domains' || $page == 'overview') {
|
||||
$count++;
|
||||
}
|
||||
|
||||
$domainscount = $paging->getEntries();
|
||||
$domainscount = $result['count'] . " / " . $paging->getEntries();
|
||||
|
||||
// Display the list
|
||||
eval("echo \"" . \Froxlor\UI\Template::getTemplate("domains/domains") . "\";");
|
||||
|
||||
@@ -133,10 +133,10 @@ if ($page == 'overview') {
|
||||
FROM `" . TABLE_PANEL_DOMAINS . "`
|
||||
WHERE `customerid`= :cid AND `isemaildomain` = '1'
|
||||
");
|
||||
$result = Database::pexecute_first($result_stmt, array(
|
||||
$result2 = Database::pexecute_first($result_stmt, array(
|
||||
"cid" => $userinfo['customerid']
|
||||
));
|
||||
$emaildomains_count = $result['emaildomains'];
|
||||
$emaildomains_count = $result2['emaildomains'];
|
||||
|
||||
eval("echo \"" . \Froxlor\UI\Template::getTemplate("email/emails") . "\";");
|
||||
} elseif ($action == 'delete' && $id != 0) {
|
||||
|
||||
@@ -85,10 +85,12 @@ if ($page == 'overview') {
|
||||
$mbdata_stmt = Database::prepare("SELECT SUM(data_length + index_length) as MB FROM information_schema.TABLES
|
||||
WHERE table_schema = :table_schema
|
||||
GROUP BY table_schema");
|
||||
Database::pexecute($mbdata_stmt, array(
|
||||
$mbdata = Database::pexecute_first($mbdata_stmt, array(
|
||||
"table_schema" => $row['databasename']
|
||||
));
|
||||
$mbdata = $mbdata_stmt->fetch(PDO::FETCH_ASSOC);
|
||||
if (!$mbdata) {
|
||||
$mbdata = array('MB' => 0);
|
||||
}
|
||||
$row['size'] = \Froxlor\PhpHelper::sizeReadable($mbdata['MB'], 'GiB', 'bi', '%01.' . (int) Settings::Get('panel.decimal_places') . 'f %s');
|
||||
eval("\$mysqls.=\"" . \Froxlor\UI\Template::getTemplate('mysql/mysqls_database') . "\";");
|
||||
$count ++;
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<header>
|
||||
<h2>
|
||||
<img src="templates/{$theme}/assets/img/icons/domains_big.png" alt="" />
|
||||
{$lng['domains']['domainsettings']} ({$domains_count})
|
||||
{$lng['domains']['domainsettings']} ({$result['count']} / {$domains_count})
|
||||
</h2>
|
||||
</header>
|
||||
|
||||
|
||||
2
templates/Sparkle/customer/email/emails.tpl
vendored
2
templates/Sparkle/customer/email/emails.tpl
vendored
@@ -3,7 +3,7 @@
|
||||
<header>
|
||||
<h2>
|
||||
<img src="templates/{$theme}/assets/img/icons/emails_big.png" alt="" />
|
||||
{$lng['menue']['email']['emails']} ({$emailscount})
|
||||
{$lng['menue']['email']['emails']} ({$result['count']} / {$emailscount})
|
||||
</h2>
|
||||
</header>
|
||||
|
||||
|
||||
2
templates/Sparkle/customer/ftp/accounts.tpl
vendored
2
templates/Sparkle/customer/ftp/accounts.tpl
vendored
@@ -3,7 +3,7 @@
|
||||
<header>
|
||||
<h2>
|
||||
<img src="templates/{$theme}/assets/img/icons/group_edit_big.png" alt="" />
|
||||
{$lng['menue']['ftp']['accounts']} ({$ftps_count})
|
||||
{$lng['menue']['ftp']['accounts']} ({$result['count']} / {$ftps_count})
|
||||
</h2>
|
||||
</header>
|
||||
|
||||
|
||||
2
templates/Sparkle/customer/mysql/mysqls.tpl
vendored
2
templates/Sparkle/customer/mysql/mysqls.tpl
vendored
@@ -3,7 +3,7 @@
|
||||
<header>
|
||||
<h2>
|
||||
<img src="templates/{$theme}/assets/img/icons/mysql_big.png" alt="" />
|
||||
{$lng['menue']['mysql']['databases']} ({$mysqls_count})
|
||||
{$lng['menue']['mysql']['databases']} ({$result['count']} / {$mysqls_count})
|
||||
</h2>
|
||||
</header>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user