src/Entity/Website/Page/Page.php line 14

Open in your IDE?
  1. <?php
  2. namespace App\Entity\Website\Page;
  3. use App\Entity\BaseEntity;
  4. use App\Entity\SeoFieldsTrait;
  5. use App\Entity\Website\Website\Website;
  6. use App\Repository\Website\Page\PageRepository;
  7. use Doctrine\DBAL\Types\Types;
  8. use Doctrine\ORM\Mapping as ORM;
  9. use Symfony\Bridge\Doctrine\IdGenerator\UuidGenerator;
  10. #[ORM\Entity(repositoryClassPageRepository::class)]
  11. class Page extends BaseEntity
  12. {
  13.     use SeoFieldsTrait;
  14.     #[ORM\Id]
  15.     #[ORM\Column(type'guid'uniquetrue)]
  16.     #[ORM\GeneratedValue(strategy'CUSTOM')]
  17.     #[ORM\CustomIdGenerator(class: UuidGenerator::class)]
  18.     private ?string $id;
  19.     #[ORM\Column(length255)]
  20.     private ?string $title null;
  21.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  22.     private ?string $description null;
  23.     #[ORM\Column(length255nullabletrue)]
  24.     private ?string $imageUrl null;
  25.     #[ORM\ManyToOne(inversedBy'pages')]
  26.     #[ORM\JoinColumn(nullablefalse)]
  27.     private ?Website $website null;
  28.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  29.     private ?string $content null;
  30.     public function __construct()
  31.     {
  32.         parent::__construct();
  33.     }
  34.     public function getId(): ?string
  35.     {
  36.         return $this->id;
  37.     }
  38.     public function getTitle(): ?string
  39.     {
  40.         return $this->title;
  41.     }
  42.     public function setTitle(string $title): static
  43.     {
  44.         $this->title $title;
  45.         return $this;
  46.     }
  47.     public function getDescription(): ?string
  48.     {
  49.         return $this->description;
  50.     }
  51.     public function setDescription(?string $description): static
  52.     {
  53.         $this->description $description;
  54.         return $this;
  55.     }
  56.     public function getImageUrl(): ?string
  57.     {
  58.         return $this->imageUrl;
  59.     }
  60.     public function setImageUrl(?string $imageUrl): static
  61.     {
  62.         $this->imageUrl $imageUrl;
  63.         return $this;
  64.     }
  65.     public function getWebsite(): ?Website
  66.     {
  67.         return $this->website;
  68.     }
  69.     public function setWebsite(?Website $shop): static
  70.     {
  71.         $this->website $shop;
  72.         return $this;
  73.     }
  74.     public function getContent(): ?string
  75.     {
  76.         return $this->content;
  77.     }
  78.     public function setContent(?string $content): static
  79.     {
  80.         $this->content $content;
  81.         return $this;
  82.     }
  83. }