diff options
Diffstat (limited to '')
-rw-r--r-- | model/Schedule.php | 9 | ||||
-rw-r--r-- | view/overview.php | 2 |
2 files changed, 10 insertions, 1 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()); diff --git a/view/overview.php b/view/overview.php index e5032c4..fb9d15d 100644 --- a/view/overview.php +++ b/view/overview.php @@ -2,7 +2,7 @@ $schedule = $conference->getSchedule(); -$now = time() + $schedule->getSimulationOffset(); +$now = $schedule->getScheduleDisplayTime(); $upcomingTalksPerRoom = []; foreach ($conference->getRooms() as $room) { $upcomingTalksPerRoom[$room->getSlug()] = [ |