示例#1
0
 /**
  * @return \Paragraph\Model\Paragraph\Structure\Content
  */
 public function prepareCreate()
 {
     $mapper = $this->getMapper();
     $this->bindChild($mapper->create(array('type' => 'contentPlaceholder')));
     return parent::prepareCreate();
 }
示例#2
0
文件: Content.php 项目: gridguyz/core
 /**
  * @return \Grid\Paragraph\Model\Paragraph\Structure\Content
  */
 public function prepareCreate()
 {
     if (empty($this->created)) {
         $this->created = new DateTime();
     }
     $mapper = $this->getMapper();
     $this->bindChild($mapper->create(array('type' => 'html')));
     return parent::prepareCreate();
 }