/** * Constructor * * @param array $data Entity properties OPTIONAL */ public function __construct(array $data = array()) { $this->categoryProducts = new \Doctrine\Common\Collections\ArrayCollection(); $this->images = new \Doctrine\Common\Collections\ArrayCollection(); $this->order_items = new \Doctrine\Common\Collections\ArrayCollection(); $this->memberships = new \Doctrine\Common\Collections\ArrayCollection(); $this->attributeValueC = new \Doctrine\Common\Collections\ArrayCollection(); $this->attributeValueS = new \Doctrine\Common\Collections\ArrayCollection(); $this->attributeValueT = new \Doctrine\Common\Collections\ArrayCollection(); $this->attributes = new \Doctrine\Common\Collections\ArrayCollection(); $this->quickData = new \Doctrine\Common\Collections\ArrayCollection(); parent::__construct($data); }
/** * Prepare order before save data operation * * @return void * * @PrePersist * @PreUpdate */ public function prepareBeforeSave() { parent::prepareBeforeSave(); if (!is_numeric($this->date) || !is_int($this->date)) { $this->setDate(\XLite\Core\Converter::time()); } }
/** * Constructor * * @param array $data Entity properties OPTIONAL * * @return void */ public function __construct(array $data = array()) { $this->categoryProducts = new \Doctrine\Common\Collections\ArrayCollection(); $this->children = new \Doctrine\Common\Collections\ArrayCollection(); parent::__construct($data); }
/** * Constructor * * @param array $data Entity properties OPTIONAL * * @return void */ public function __construct(array $data = array()) { $this->categoryProducts = new \Doctrine\Common\Collections\ArrayCollection(); $this->images = new \Doctrine\Common\Collections\ArrayCollection(); $this->order_items = new \Doctrine\Common\Collections\ArrayCollection(); $this->classes = new \Doctrine\Common\Collections\ArrayCollection(); parent::__construct($data); }