瀏覽代碼

Merge branch 'develop'

develop
Guillaume 2 年之前
父節點
當前提交
e79b0218b1
共有 1 個文件被更改,包括 26 次插入0 次删除
  1. +26
    -0
      Doctrine/Extension/ImageTrait.php

+ 26
- 0
Doctrine/Extension/ImageTrait.php 查看文件

@@ -0,0 +1,26 @@
<?php

namespace Lc\SovBundle\Doctrine\Extension;

use App\Entity\File\File;
use Doctrine\ORM\Mapping as ORM;

trait ImageTrait
{
/**
* @ORM\ManyToOne(targetEntity="Lc\SovBundle\Model\File\FileInterface", cascade={"persist", "remove"}, fetch="EAGER")
*/
protected $image;

public function getImage(): ?File
{
return $this->image;
}

public function setImage(?File $image): self
{
$this->image = $image;

return $this;
}
}

Loading…
取消
儲存