diff --git a/web/app/Model/AppModel.php b/web/app/Model/AppModel.php index 2add386f6..9297aa609 100644 --- a/web/app/Model/AppModel.php +++ b/web/app/Model/AppModel.php @@ -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); + } + }