コード例 #1
0
ファイル: class.php プロジェクト: BGCX261/zimmerli-svn-to-git
 private function renderProperty(umiObjectProperty &$property, $template, $is_random = false)
 {
     $data_type = $property->getDataType();
     switch ($data_type) {
         case "string":
             return $this->renderString($property, $template);
         case "text":
             return $this->renderString($property, $template, false, "text");
         case "wysiwyg":
             return $this->renderString($property, $template, false, "wysiwyg");
         case "int":
             return $this->renderInt($property, $template);
         case "price":
             return $this->renderPrice($property, $template);
         case "float":
             return $this->renderFloat($property, $template);
         case "boolean":
             return $this->renderBoolean($property, $template);
         case "img_file":
             return $this->renderImageFile($property, $template);
         case "relation":
             return $this->renderRelation($property, $template, false, $is_random);
         case "symlink":
             return $this->renderSymlink($property, $template, false, $is_random);
         case "swf_file":
             return $this->renderFile($property, $template, false, "swf_file");
         case "file":
             return $this->renderFile($property, $template);
         case "date":
             return $this->renderDate($property, $template);
         case "tags":
             return $this->renderTags($property, $template);
         case "optioned":
             return $this->renderOptioned($property, $template);
         default:
             return "I don't know, how to render this sort of property (\"{$data_type}\") :(";
     }
 }