SAAS-382: Reimplement Storage Quota

Changed status page to use new disk_usage value from cc_pref table.
This commit is contained in:
drigato 2014-03-21 11:11:18 -04:00 committed by Albert Santoni
parent 0398072d45
commit cdcdf7d912
1 changed files with 3 additions and 2 deletions

View File

@ -218,13 +218,14 @@ class Application_Model_Systemstatus
//connect to DB and find how much total space user has allocated. //connect to DB and find how much total space user has allocated.
$totalSpace = Application_Model_Preference::GetDiskQuota(); $totalSpace = Application_Model_Preference::GetDiskQuota();
$path = $_SERVER['AIRTIME_BASE']."etc/airtime/num_bytes.ini"; $usedSpace = Application_Model_Preference::getDiskUsage();
/* $path = $_SERVER['AIRTIME_BASE']."etc/airtime/num_bytes.ini";
$arr = parse_ini_file($path); $arr = parse_ini_file($path);
$usedSpace = 0; $usedSpace = 0;
if ($arr !== false) { if ($arr !== false) {
$usedSpace = $arr['num_bytes']; $usedSpace = $arr['num_bytes'];
} } */
$partitions[$totalSpace] = new stdClass(); $partitions[$totalSpace] = new stdClass();
$partitions[$totalSpace]->totalSpace = $totalSpace; $partitions[$totalSpace]->totalSpace = $totalSpace;