diff options
author | MaZderMind | 2018-05-12 02:00:51 +0200 |
---|---|---|
committer | MaZderMind | 2018-05-12 02:02:24 +0200 |
commit | 91a653392c0e66f1941036e2b17d8fa6b162cde0 (patch) | |
tree | d1e6ceabe67aa4e3934c1e395a7c95636fd0524f /model | |
parent | 888bff1972e18a7f32d55fcc23cd4900d03c7d61 (diff) |
migrate logic for calculating schedule display time into schedule class
Diffstat (limited to 'model')
-rw-r--r-- | model/Schedule.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/model/Schedule.php b/model/Schedule.php index ec4ddc7..4b5d25e 100644 --- a/model/Schedule.php +++ b/model/Schedule.php @@ -44,6 +44,15 @@ class Schedule return $this->getConference()->getRoomIfExists( @$mapping[$scheduleRoom] ); } + public function getScheduleDisplayTime($basetime = null) + { + if(is_null($basetime)) { + $basetime = time(); + } + + return $basetime + $this->getSimulationOffset(); + } + private function fetchSchedule() { $schedule = @file_get_contents($this->getScheduleCache()); |