public function schedule() { $matches = \Own\Bus\Match\Data::loadAllScheduled(); $cronTimer = (Engine::CRON_TIMER - date('i') % Engine::CRON_TIMER) * 60 - date('s') + 10; // view $this->setTpl(); // main $tplMain = new Util\Template(Util\Template::SITE, ['www']); $tplMain->set('matches', $matches); $tplMain->set('playerId', $this->player->getId()); $tplMain->set('cronTimer', $cronTimer); // layout $this->tplLayout->set('column1', $tplMain->render('match-schedule')); // template $this->tplMaster->set('layout', $this->tplLayout->render('layout-center')); return $this->tplMaster->render('tpl-default'); }