Beispiel #1
0
 private function renderDate(umiObjectProperty &$property, $template, $showNull = false)
 {
     $name = $property->getName();
     $title = $property->getTitle();
     $value = $property->getValue();
     if ($property->getIsMultiple() === false) {
         list($tpl, $tpl_empty) = self::loadTemplates("data/" . $template, "date", "date_empty");
         if (empty($value) && !$showNull) {
             return $tpl_empty;
         }
         $arr = array();
         $arr['field_id'] = $property->getField()->getId();
         $arr['name'] = $name;
         $arr['title'] = $title;
         $arr['timestamp'] = $value->getFormattedDate("U");
         $arr['value'] = $value->getFormattedDate();
         $arr['template'] = $template;
         return self::parseTemplate($tpl, $arr);
     } else {
     }
 }