예제 #1
0
파일: events.php 프로젝트: anqqa/Anqh
 /**
  * Week view
  *
  * @param  int  $year
  * @param  int  $week
  */
 public function week($year, $week)
 {
     $this->tab_id = 'browse';
     if (valid::year($year) && valid::week($week)) {
         $this->type = 'week';
         $this->date->setISODate($year, $week);
         // check for new years fix
         if ($week == 1) {
             $saturday = new DateTime();
             $saturday->setISODate($year, $week, 6);
             $this->date = $saturday;
         }
         $this->page_title = text::title(__('Week') . ' ' . $this->date->format('W/Y'));
         $this->breadcrumb[] = html::anchor(Router::$routed_uri, html::specialchars($this->page_title));
         $this->_build_calendar();
     }
 }