<?php
namespace App\Entity;
use App\Traits\Creatable;
use App\Traits\Deleteable;
use App\Traits\Updateable;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
/**
* @ORM\Table(name="`pdfmenu_personalization`")
* @ORM\Entity()
* @Gedmo\SoftDeleteable(fieldName="deletedAt")
* @ORM\HasLifecycleCallbacks()
*/
class PdfmenuPersonalization
{
use Creatable, Updateable, Deleteable;
/**
* @ORM\Id
* @ORM\Column(type="integer")
* @ORM\GeneratedValue(strategy="AUTO")
*/
private ?int $id = null;
/**
* @var ?string
*
* @ORM\Column(type="string", nullable=true)
*/
private ?string $title;
/**
* @var ?string
*
* @ORM\Column(type="string", nullable=true)
*/
private ?string $subTitle;
/**
* @var ?string
*
* @ORM\Column(type="string", nullable=true)
*/
private ?string $backgroundColor;
/**
* @var ?string
*
* @ORM\Column(type="string", nullable=true)
*/
private ?string $titleColor;
/**
* @var ?string
*
* @ORM\Column(type="string", nullable=true)
*/
private ?string $subTitleColor;
/**
* @var ?string
*
* @ORM\Column(type="string", nullable=true)
*/
private ?string $buttonBackgroundColor;
/**
* @var ?string
*
* @ORM\Column(type="string", nullable=true)
*/
private ?string $buttonTextColor;
/**
* @ORM\OneToOne (targetEntity="App\Entity\Institution", inversedBy="pdfmenuPersonalization")
* @ORM\JoinColumn(name="institution_id", referencedColumnName="id")
*/
private ?Institution $institution = null;
/**
* @var false
* @ORM\Column(type="boolean")
*/
private bool $displayLogo;
/**
* @var ?string (LIST|TAB|SLIDER)
* @ORM\Column(type="string", options={"default": "LIST"})
*/
private ?string $displayMode;
public function __construct()
{
$this->title = 'Bienvenue sur le menu de votre établissement !';
$this->subTitle = 'Quelle carte voulez-vous consulter ?';
$this->backgroundColor = 'rgba(255, 245, 247, 1)';
$this->titleColor = 'rgba(255, 57, 94, 1)';
$this->subTitleColor = 'rgba(255, 57, 94, 1)';
$this->buttonBackgroundColor = 'rgba(255, 57, 94, 1)';
$this->buttonTextColor = 'rgba(255, 245, 247, 1)';
$this->displayLogo = false;
$this->displayMode = 'LIST';
}
public function getId(): ?int
{
return $this->id;
}
public function getTitle(): ?string
{
return $this->title;
}
public function setTitle(?string $title): self
{
$this->title = $title;
return $this;
}
public function getSubTitle(): ?string
{
return $this->subTitle;
}
public function setSubTitle(?string $subTitle): self
{
$this->subTitle = $subTitle;
return $this;
}
public function getBackgroundColor(): ?string
{
return $this->backgroundColor;
}
public function setBackgroundColor(?string $backgroundColor): self
{
$this->backgroundColor = $backgroundColor;
return $this;
}
public function getTitleColor(): ?string
{
return $this->titleColor;
}
public function setTitleColor(?string $titleColor): self
{
$this->titleColor = $titleColor;
return $this;
}
public function getSubTitleColor(): ?string
{
return $this->subTitleColor;
}
public function setSubTitleColor(?string $subTitleColor): self
{
$this->subTitleColor = $subTitleColor;
return $this;
}
public function getButtonBackgroundColor(): ?string
{
return $this->buttonBackgroundColor;
}
public function setButtonBackgroundColor(?string $buttonBackgroundColor): self
{
$this->buttonBackgroundColor = $buttonBackgroundColor;
return $this;
}
public function getButtonTextColor(): ?string
{
return $this->buttonTextColor;
}
public function setButtonTextColor(?string $buttonTextColor): self
{
$this->buttonTextColor = $buttonTextColor;
return $this;
}
public function getInstitution(): ?Institution
{
return $this->institution;
}
public function setInstitution(?Institution $institution): self
{
$this->institution = $institution;
return $this;
}
public function getDisplayLogo(): ?bool
{
return $this->displayLogo;
}
public function setDisplayLogo(?bool $displayLogo): self
{
$this->displayLogo = $displayLogo;
return $this;
}
public function getDisplayMode(): ?string
{
return $this->displayMode;
}
public function setDisplayMode(?string $displayMode): self
{
$this->displayMode = $displayMode;
return $this;
}
}