<?php

namespace App\Entity;

use App\Repository\BilletDesignRepository;
use Doctrine\ORM\Mapping as ORM;

#[ORM\Entity(repositoryClass: BilletDesignRepository::class)]
#[ORM\Cache(usage: 'NONSTRICT_READ_WRITE')]
class BilletDesign
{
    #[ORM\Id]
    #[ORM\GeneratedValue]
    #[ORM\Column]
    private ?int $id = null;

    #[ORM\OneToOne(targetEntity: Event::class)]
    #[ORM\JoinColumn(nullable: false, onDelete: 'CASCADE')]
    private ?Event $event = null;

    #[ORM\Column(length: 7)]
    private string $accentColor = '#4f46e5';

    #[ORM\Column(length: 255)]
    private string $invitationTitle = 'Invitation';

    #[ORM\Column(length: 7)]
    private string $invitationColor = '#d4a017';

    #[ORM\Column]
    private \DateTimeImmutable $updatedAt;

    public function __construct()
    {
        $this->updatedAt = new \DateTimeImmutable();
    }

    public function getId(): ?int
    {
        return $this->id;
    }

    public function getEvent(): ?Event
    {
        return $this->event;
    }

    public function setEvent(?Event $event): static
    {
        $this->event = $event;

        return $this;
    }

    public function getAccentColor(): string
    {
        return $this->accentColor;
    }

    public function setAccentColor(string $accentColor): static
    {
        $this->accentColor = $accentColor;

        return $this;
    }

    public function getInvitationTitle(): string
    {
        return $this->invitationTitle;
    }

    public function setInvitationTitle(string $invitationTitle): static
    {
        $this->invitationTitle = $invitationTitle;

        return $this;
    }

    public function getInvitationColor(): string
    {
        return $this->invitationColor;
    }

    public function setInvitationColor(string $invitationColor): static
    {
        $this->invitationColor = $invitationColor;

        return $this;
    }

    public function getUpdatedAt(): \DateTimeImmutable
    {
        return $this->updatedAt;
    }

    public function setUpdatedAt(\DateTimeImmutable $updatedAt): static
    {
        $this->updatedAt = $updatedAt;

        return $this;
    }
}
