src/Entity/Cursus.php line 14

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\DBAL\Types\Types;
  4. use Doctrine\ORM\Mapping as ORM;
  5. /**
  6. * Cursus
  7. *
  8. * @ORM\Table(name="CURSUS", indexes={@ORM\Index(name="utilisateurmaj_id", columns={"utilisateurmaj_id"})})
  9. * @ORM\Entity
  10. */
  11. class Cursus
  12. {
  13. /**
  14. * @var int
  15. *
  16. * @ORM\Column(name="idcursus", type="integer", nullable=false)
  17. * @ORM\Id
  18. * @ORM\GeneratedValue(strategy="IDENTITY")
  19. */
  20. private $idcursus;
  21. /**
  22. * @var string
  23. *
  24. * @ORM\Column(name="libellecursus", type="string", length=255, nullable=false)
  25. */
  26. private $libellecursus;
  27. /**
  28. * @var string
  29. *
  30. * @ORM\Column(name="codecursus", type="string", length=5, nullable=false)
  31. */
  32. private $codecursus;
  33. /**
  34. * @var \DateTime
  35. *
  36. * @ORM\Column(name="datecrea", type="datetime", nullable=false)
  37. */
  38. private $datecrea;
  39. /**
  40. * @var \DateTime
  41. *
  42. * @ORM\Column(name="datemaj", type="datetime", nullable=false)
  43. */
  44. private $datemaj;
  45. /**
  46. * @var \Utilisateur
  47. *
  48. * @ORM\ManyToOne(targetEntity="Utilisateur")
  49. * @ORM\JoinColumns({
  50. * @ORM\JoinColumn(name="utilisateurmaj_id", referencedColumnName="idutilisateur")
  51. * })
  52. */
  53. private $utilisateurmaj;
  54. public function __ToString(): string
  55. {
  56. return $this->codecursus . " - " . $this->libellecursus;
  57. }
  58. public function getIdcursus(): ?int
  59. {
  60. return $this->idcursus;
  61. }
  62. public function getLibellecursus(): ?string
  63. {
  64. return $this->libellecursus;
  65. }
  66. public function setLibellecursus(string $libellecursus): static
  67. {
  68. $this->libellecursus = $libellecursus;
  69. return $this;
  70. }
  71. public function getCodecursus(): ?string
  72. {
  73. return $this->codecursus;
  74. }
  75. public function setCodecursus(string $codecursus): static
  76. {
  77. $this->codecursus = $codecursus;
  78. return $this;
  79. }
  80. public function getDatecrea(): ?\DateTimeInterface
  81. {
  82. return $this->datecrea;
  83. }
  84. public function setDatecrea(\DateTimeInterface $datecrea): static
  85. {
  86. $this->datecrea = $datecrea;
  87. return $this;
  88. }
  89. public function getDatemaj(): ?\DateTimeInterface
  90. {
  91. return $this->datemaj;
  92. }
  93. public function setDatemaj(\DateTimeInterface $datemaj): static
  94. {
  95. $this->datemaj = $datemaj;
  96. return $this;
  97. }
  98. public function getUtilisateurmaj(): ?Utilisateur
  99. {
  100. return $this->utilisateurmaj;
  101. }
  102. public function setUtilisateurmaj(?Utilisateur $utilisateurmaj): static
  103. {
  104. $this->utilisateurmaj = $utilisateurmaj;
  105. return $this;
  106. }
  107. }