public function __construct(NewsletterEntity $newsletter) { $this->newsletter = $newsletter; $this->dir = new DirEntity(); $this->dir->setParent($this->newsletter->route->getDir()); $this->dir->setInvisible(TRUE); $this->dir->setName(Strings::webalize(get_class($this)) . Strings::random()); }
public function __construct() { $this->items = new ArrayCollection(); $this->revisions = new ArrayCollection(); $this->items[] = new ItemEntity($this); $this->dir = new DirEntity(); $this->dir->setInvisible(TRUE); $this->dir->setName(Strings::webalize(get_class($this)) . Strings::random()); }
public function __construct() { $this->dir = new DirEntity(); $this->dir->setInvisible(TRUE); $this->dir->setName(Strings::webalize(get_class($this)) . Strings::random()); }
/** * @return DirEntity */ public function getDir() { if (!$this->dir) { $this->dir = new DirEntity(); $this->dir->setParent($this->page->getDir()); $this->dir->setInvisible(TRUE); $this->dir->setName(Strings::webalize(get_class($this)) . Strings::random()); } return $this->dir; }