src/Entity/MarketAppImage.php line 22
<?phpnamespace App\Entity;use ApiPlatform\Metadata\ApiResource;use ApiPlatform\Metadata\Get;use ApiPlatform\Metadata\GetCollection;use App\Entity\Traits\CreatedAtTrait;use App\Entity\Traits\UpdatedAtTrait;use App\Repository\MarketAppImageRepository;use Doctrine\ORM\Mapping as ORM;use Symfony\Bridge\Doctrine\Types\UlidType;use Symfony\Component\HttpFoundation\File\File;use Symfony\Component\Serializer\Annotation\Groups;use Symfony\Component\Uid\Ulid;use Symfony\Component\Validator\Constraints as Assert;use Vich\UploaderBundle\Mapping\Annotation as Vich;#[ORM\HasLifecycleCallbacks]#[Vich\Uploadable]#[ORM\Entity(repositoryClass: MarketAppImageRepository::class)]class MarketAppImage{use CreatedAtTrait;use UpdatedAtTrait;#[ORM\Id]#[ORM\GeneratedValue]#[ORM\Column]#[Groups(['read', 'MarketCategory:read'])]private ?int $id = null;#[Vich\UploadableField(mapping: 'screenshots_file', fileNameProperty: 'image')]#[Assert\Image(mimeTypes: ['image/png', 'image/jpeg', 'image/jpg'])]private ?File $imageFile = null;#[ORM\Column(length: 255, nullable: true)]#[Groups(['read', 'MarketCategory:read'])]private ?string $image = null;#[ORM\ManyToOne(inversedBy: 'images')]private ?MarketApp $marketApp = null;public function getId(): ?int{return $this->id;}public function getImage(): ?string{return $this->image;}public function setImage(?string $image): self{$this->image = $image;return $this;}public function getImageFile(): ?File{return $this->imageFile;}public function setImageFile(?File $imageFile): void{$this->imageFile = $imageFile;if (null !== $imageFile) {$this->updatedAt = new \DateTime();}}public function getMarketApp(): ?MarketApp{return $this->marketApp;}public function setMarketApp(?MarketApp $marketApp): self{$this->marketApp = $marketApp;return $this;}}