Exemplo n.º 1
0
 public function getSunrise($format = 'Y-m-d H:i:s')
 {
     $sunrise = parent::getSunrise($format);
     if (!is_null($sunrise)) {
         return $sunrise;
     }
     $entry = $this->getEntry();
     if (!$entry) {
         return null;
     }
     $sunrise = $entry->getStartDate($format);
     if (!is_null($sunrise)) {
         return $sunrise;
     }
     return $entry->getCreatedAt($format);
 }
Exemplo n.º 2
0
 public function getSunrise($format = 'Y-m-d H:i:s')
 {
     $sunrise = parent::getSunrise($format);
     if (!is_null($sunrise)) {
         return $sunrise;
     }
     $entry = entryPeer::retrieveByPKNoFilter($this->getEntryId());
     if (!$entry) {
         return null;
     }
     $sunrise = $entry->getStartDate($format);
     if (!is_null($sunrise)) {
         return $sunrise;
     }
     return $entry->getCreatedAt($format);
 }