addAttachment() public method

Setter for attachments.
public addAttachment ( Attachment $attachment ) : self
$attachment Attachment
return self
Ejemplo n.º 1
0
 public function addAttachmentToArticle(Article $article, Attachment $attachment)
 {
     $article->addAttachment($attachment);
     $this->em->flush();
 }