Example #1
0
 /**
  * Init all days for beeing displayed
  */
 protected function initDays()
 {
     $this->initShortModes();
     $this->initEmptyDays();
     $Statement = $this->DatasetQuery->statementToFetchActivities($this->TimestampStart, $this->TimestampEnd);
     while ($Training = $Statement->fetch()) {
         $w = Time::diffInDays($Training['time'], $this->TimestampStart);
         if (in_array($Training['sportid'], $this->SportsShort) || in_array($Training['typeid'], $this->TypesShort)) {
             $this->Days[$w]['shorts'][] = $Training;
         } else {
             $this->Days[$w]['trainings'][] = $Training;
         }
     }
 }