Exemplo n.º 1
0
 /**
  * Entry point for the chart system
  *
  * @NoCSRFRequired
  * @NoAdminRequired
  * @return TemplateResponse
  */
 public function frontpage()
 {
     $charts = $this->configService->getCharts();
     if (count($charts) == 0) {
         $this->configService->createDefaultConfig();
         $charts = $this->configService->getCharts();
     }
     $id = $charts[0]->getId();
     $url = \OCP\Util::linkToRoute('ocusagecharts.chart.display_chart', array('id' => $id));
     return new RedirectResponse($url);
 }