private function populate()
 {
     $article = new TranslatableArticle();
     $article->setTitle('the title');
     $article->setCode('my code');
     $this->em->persist($article);
     $this->em->flush();
     $this->em->clear();
     $this->articleId = $article->getId();
 }
Example #2
0
 public function addArticle(TranslatableArticle $article)
 {
     $article->setPage($this);
     $this->articles[] = $article;
 }