/**
  * {@inheritDoc}
  */
 public function setDefault($default)
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'setDefault', array($default));
     return parent::setDefault($default);
 }
Пример #2
0
 /**
  * @ORM\PrePersist
  */
 public function addDefaultGallery()
 {
     $gallery = new Gallery();
     $gallery->setUser($this);
     $gallery->setDefault(true);
     $this->addGallery($gallery);
 }