src/Entity/Vetoadom/SecteurConsigne.php line 14

Open in your IDE?
  1. <?php
  2. namespace App\Entity\Vetoadom;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5.  * SecteurConsigne
  6.  *
  7.  * @ORM\Table(name="secteur_consigne", indexes={@ORM\Index(name="FK_secteur_consigne_secteur", columns={"secteur_id"}), @ORM\Index(name="FK_secteur_consigne_secteur_consigne_type", columns={"secteur_consigne_type_id"})})
  8.  * @ORM\Entity(repositoryClass="App\Repository\Vetoadom\SecteurConsigneRepository")
  9.  * @ORM\HasLifecycleCallbacks()
  10.  */
  11. class SecteurConsigne
  12. {
  13.     /**
  14.      * @var int
  15.      *
  16.      * @ORM\Column(name="id", type="integer", nullable=false)
  17.      * @ORM\Id
  18.      * @ORM\GeneratedValue(strategy="IDENTITY")
  19.      */
  20.     private $id;
  21.     /**
  22.      * @var int
  23.      *
  24.      * @ORM\Column(name="saisie_user_id", type="integer", nullable=false)
  25.      */
  26.     private $saisieUserId;
  27.     /**
  28.      * @var int|null
  29.      *
  30.      * @ORM\Column(name="suppression_user_id", type="integer", nullable=true)
  31.      */
  32.     private $suppressionUserId;
  33.     /**
  34.      * @var string
  35.      *
  36.      * @ORM\Column(name="consigne", type="text", length=65535, nullable=false)
  37.      */
  38.     private $consigne;
  39.     /**
  40.      * @var \DateTime
  41.      *
  42.      * @ORM\Column(name="date_debut", type="datetime", nullable=false)
  43.      */
  44.     private $dateDebut;
  45.     /**
  46.      * @var \DateTime
  47.      *
  48.      * @ORM\Column(name="date_fin", type="datetime", nullable=false)
  49.      */
  50.     private $dateFin;
  51.     /**
  52.      * @var \DateTime|null
  53.      *
  54.      * @ORM\Column(name="date_suppression", type="datetime", nullable=true)
  55.      */
  56.     private $dateSuppression;
  57.     /**
  58.      * @var \DateTime
  59.      *
  60.      * @ORM\Column(name="date_creation", type="datetime", nullable=false)
  61.      */
  62.     private $dateCreation;
  63.     /**
  64.      * @var \DateTime
  65.      *
  66.      * @ORM\Column(name="date_modification", type="datetime", nullable=false, options={"default"="CURRENT_TIMESTAMP"})
  67.      */
  68.     private $dateModification;
  69.     /**
  70.      * @var \Secteur
  71.      *
  72.      * @ORM\ManyToOne(targetEntity="Secteur", inversedBy="secteurConsigne")
  73.      * @ORM\JoinColumns({
  74.      *   @ORM\JoinColumn(name="secteur_id", referencedColumnName="id")
  75.      * })
  76.      */
  77.     private $secteur;
  78.     /**
  79.      * @var \SecteurConsigneType
  80.      *
  81.      * @ORM\ManyToOne(targetEntity="SecteurConsigneType")
  82.      * @ORM\JoinColumns({
  83.      *   @ORM\JoinColumn(name="secteur_consigne_type_id", referencedColumnName="id")
  84.      * })
  85.      */
  86.     private $secteurConsigneType;
  87.     public function getId(): ?int
  88.     {
  89.         return $this->id;
  90.     }
  91.     public function getConsigne(): ?string
  92.     {
  93.         return $this->consigne;
  94.     }
  95.     public function setConsigne(string $consigne): self
  96.     {
  97.         $this->consigne $consigne;
  98.         return $this;
  99.     }
  100.     public function getSaisieUserId(): ?int
  101.     {
  102.         return $this->saisieUserId;
  103.     }
  104.     public function setSaisieUserId(?int $saisieUserId): self
  105.     {
  106.         $this->saisieUserId $saisieUserId;
  107.         return $this;
  108.     }
  109.     public function getSuppressionUserId(): ?int
  110.     {
  111.         return $this->suppressionUserId;
  112.     }
  113.     public function setSuppressionUserId(?int $suppressionUserId): self
  114.     {
  115.         $this->suppressionUserId $suppressionUserId;
  116.         return $this;
  117.     }
  118.     public function getDateDebut(): ?\DateTimeInterface
  119.     {
  120.         return $this->dateDebut;
  121.     }
  122.     public function setDateDebut(\DateTimeInterface $dateDebut): self
  123.     {
  124.         $this->dateDebut $dateDebut;
  125.         return $this;
  126.     }
  127.     public function getDateFin(): ?\DateTimeInterface
  128.     {
  129.         return $this->dateFin;
  130.     }
  131.     public function setDateFin(\DateTimeInterface $dateFin): self
  132.     {
  133.         $this->dateFin $dateFin;
  134.         return $this;
  135.     }
  136.     public function getDateSuppression(): ?\DateTimeInterface
  137.     {
  138.         return $this->dateSuppression;
  139.     }
  140.     public function setDateSuppression(?\DateTimeInterface $dateSuppression): self
  141.     {
  142.         $this->dateSuppression $dateSuppression;
  143.         return $this;
  144.     }
  145.     public function getDateCreation(): ?\DateTimeInterface
  146.     {
  147.         return $this->dateCreation;
  148.     }
  149.     public function setDateCreation(\DateTimeInterface $dateCreation): self
  150.     {
  151.         $this->dateCreation $dateCreation;
  152.         return $this;
  153.     }
  154.     public function getDateModification(): ?\DateTimeInterface
  155.     {
  156.         return $this->dateModification;
  157.     }
  158.     public function setDateModification(\DateTimeInterface $dateModification): self
  159.     {
  160.         $this->dateModification $dateModification;
  161.         return $this;
  162.     }
  163.     public function getSecteur(): ?Secteur
  164.     {
  165.         return $this->secteur;
  166.     }
  167.     public function setSecteur(?Secteur $secteur): self
  168.     {
  169.         $this->secteur $secteur;
  170.         return $this;
  171.     }
  172.     public function getSecteurConsigneType(): ?SecteurConsigneType
  173.     {
  174.         return $this->secteurConsigneType;
  175.     }
  176.     public function setSecteurConsigneType(?SecteurConsigneType $secteurConsigneType): self
  177.     {
  178.         $this->secteurConsigneType $secteurConsigneType;
  179.         return $this;
  180.     }
  181.     /**
  182.      * @ORM\PrePersist
  183.      */
  184.     public function setCreatedAtValue()
  185.     {
  186.         $this->dateCreation = new \DateTimeImmutable();
  187.     }
  188. }