Minor cosmetic updates

This commit is contained in:
Deon George
2011-05-27 21:08:44 +10:00
parent 7a480dba58
commit dcd6a54cb9
7 changed files with 94 additions and 84 deletions

View File

@@ -30,10 +30,16 @@ class Model_VOLUME extends ORMTSM {
),
);
// Show the number of filespaces on a volume
// $dtype is BACKUP or ARCHIVE
public function getFSOnVol($dtype) {
return $this->VOLUMEUSAGE->where('COPY_TYPE','=',$dtype)->find_all()->count();
}
// Show the number of nodes on a volume
// $dtype is BACKUP or ARCHIVE
public function getNodesOnVol($dtype) {
return $this->VOLUMEUSAGE->where('COPY_TYPE','=',$dtype)->find_all()->count();
return $this->VOLUMEUSAGE->select('NODE_NAME')->distinct(TRUE)->where('COPY_TYPE','=',$dtype)->find_all()->count();
}
}
?>