Function to determine the path to an event in the filesystem.

This commit is contained in:
Kyle Johnson 2013-05-30 20:30:09 -04:00
parent c2e2079818
commit f4d2df3941
1 changed files with 9 additions and 0 deletions

View File

@ -51,4 +51,13 @@ class AppModel extends Model {
return( $dimension );
}
public function getEventPath( $event ){
if (Configure::read('ZM_USE_DEEP_STORAGE')) {
$eventPath = $event['MonitorId'].'/'.strftime("%y/%m/%d/%H/%M/%S", strtotime($event['StartTime']));
} else {
$eventPath = $event['MonitorId'].'/'.$event['Id'];
}
return($eventPath);
}
}