You've already forked mailcow-dockerized
mirror of
https://github.com/mailcow/mailcow-dockerized.git
synced 2025-07-15 01:34:16 +02:00
finalizing disk usage rework
- changed dockerapi to not return human readable values for df - all caluclations now in KiB - moved code from domain_admin to mailbox functions - using actual occupied bytes as used quota - all outputs now in *iB using formatBytes()
This commit is contained in:
@ -444,18 +444,5 @@ function domain_admin($_action, $_data = null) {
|
||||
|
||||
return $domainadmindata;
|
||||
break;
|
||||
case 'total_quota':
|
||||
if ($_SESSION['mailcow_cc_role'] != "admin") {
|
||||
$_SESSION['return'][] = array(
|
||||
'type' => 'danger',
|
||||
'log' => array(__FUNCTION__, $_action, $_data_log),
|
||||
'msg' => 'access_denied'
|
||||
);
|
||||
return false;
|
||||
}
|
||||
$stmt = $pdo->query("SELECT SUM(`quota`) AS `quota` FROM `domain` WHERE `active`=1");
|
||||
$row = $stmt->fetch(PDO::FETCH_ASSOC);
|
||||
return $row['quota'];
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user