src/Entity/Blog.php line 15
<?phpnamespace App\Entity;use App\Entity\Trait\MainTranslationTrait;use App\Entity\Translation\BlogTranslation;use App\Repository\BlogRepository;use Doctrine\ORM\Mapping as ORM;use Gedmo\Mapping\Annotation as Gedmo;use Gedmo\Translatable\Translatable;#[ORM\Table(name: 'blog')]#[ORM\Entity(repositoryClass: BlogRepository::class)]#[Gedmo\TranslationEntity(class: BlogTranslation::class)]class Blog implements Translatable{use MainTranslationTrait;const TRANSLATION_ENTITY = BlogTranslation::class;#[ORM\Id]#[ORM\GeneratedValue]#[ORM\Column]private ?int $id = null;#[ORM\Column(type: 'string', nullable: true)]#[Gedmo\Translatable]private ?string $title = null;#[ORM\Column(type: 'string',unique: true)]#[Gedmo\Slug(fields: ['title'])]private string $slug;#[ORM\Column(type: 'text', nullable: true)]#[Gedmo\Translatable]private ?string $body = null;#[ORM\Column(type: 'string', nullable: true)]private ?string $image = null;#[ORM\Column(type: 'string',length: 160, nullable: true)]#[Gedmo\Translatable]private ?string $metaKeywords = null;#[ORM\Column(type: 'string',length: 160, nullable: true)]#[Gedmo\Translatable]private ?string $metaDescription = null;#[ORM\Column(type: 'string', nullable: true)]private ?string $imageList = null;public function getId(): ?int{return $this->id;}public function __toString(): string{return $this->title ?? "";}public function getTitle(): ?string{return $this->title;}public function setTitle(?string $title): void{$this->title = $title;}public function getSlug(): string{return $this->slug;}public function setSlug(string $slug): void{$this->slug = $slug;}public function getBody(): ?string{return $this->body;}public function setBody(?string $body): void{$this->body = $body;}public function getImage(): ?string{return $this->image;}public function setImage(?string $image): void{$this->image = $image;}public function getImageList(): ?string{return $this->imageList;}public function setImageList(?string $imageList): void{$this->imageList = $imageList;}public function getMetaKeywords(): ?string{return $this->metaKeywords;}public function setMetaKeywords(?string $metaKeywords): void{$this->metaKeywords = $metaKeywords;}public function getMetaDescription(): ?string{return $this->metaDescription;}public function setMetaDescription(?string $metaDescription): void{$this->metaDescription = $metaDescription;}}