src/Entity/Order/OrderItemPhoto.php line 31
<?php/** This file is part of the Pellipop project.** (c) Mobizel** For the full copyright and license information, please view the LICENSE* file that was distributed with this source code.*/declare(strict_types=1);namespace App\Entity\Order;use App\Entity\Media\File;use App\OrderItemPhotoStates;use App\Repository\Order\OrderItemPhotoRepository;use App\Validator\Constraints\OrderItemPhotosMaxCount;use Doctrine\ORM\Mapping as ORM;use Monofony\Contracts\Core\Model\Media\FileInterface;use Symfony\Component\Validator\Constraints as Assert;use Vich\UploaderBundle\Mapping\Annotation as Vich;/*** @Vich\Uploadable*/#[ORM\Entity(repositoryClass: OrderItemPhotoRepository::class)]#[ORM\Table(name: 'app_order_item_photo')]#[OrderItemPhotosMaxCount()]class OrderItemPhoto extends File implements FileInterface{/*** @Vich\UploadableField(mapping="order_item_photo", fileNameProperty="path")*/#[Assert\Image(maxSize: '100M')]protected ?\SplFileInfo $file = null;#[ORM\ManyToOne(inversedBy: 'photos')]#[ORM\JoinColumn(nullable: false)]private ?OrderItem $orderItem = null;#[ORM\Column(length: 255, nullable: true)]#[Groups(['image:read'])]private ?string $fujiHash = null;#[ORM\Column(length: 20)]#[Groups(['image:read'])]private ?string $state = null;#[ORM\Column(length: 1000, nullable: true)]#[Groups(['image:read'])]private ?string $tag = null;public function __construct(){$this->state = OrderItemPhotoStates::STATE_NEW;parent::__construct();}public function getOrderItem(): ?OrderItem{return $this->orderItem;}public function setOrderItem(?OrderItem $orderItem): self{$this->orderItem = $orderItem;return $this;}public function getFujiHash(): ?string{return $this->fujiHash;}public function setFujiHash(?string $fujiHash): self{$this->fujiHash = $fujiHash;return $this;}public function getState(): ?string{return $this->state;}public function setState(string $state): self{$this->state = $state;return $this;}public function getTag(): ?string{return $this->tag;}public function setTag(?string $tag): void{$this->tag = $tag;}}