WellCommerce\Bundle\PageBundle\Entity\Page::setParent PHP Method

setParent() public method

public setParent ( WellCommerce\Bundle\PageBundle\Entity\PageInterface $parent = null )
$parent WellCommerce\Bundle\PageBundle\Entity\PageInterface
    public function setParent(PageInterface $parent = null)
    {
        $this->parent = $parent;
    }

Usage Example

Example #1
0
 public function create() : PageInterface
 {
     $page = new Page();
     $page->setHierarchy(0);
     $page->setCreatedAt(new \DateTime());
     $page->setClientGroups($this->createEmptyCollection());
     $page->setShops($this->createEmptyCollection());
     $page->setParent(null);
     $page->setPublish(true);
     $page->setRedirectType(1);
     $page->setSection('');
     return $page;
 }
All Usage Examples Of WellCommerce\Bundle\PageBundle\Entity\Page::setParent