Deprecated: Constant E_STRICT is deprecated in /var/www/PixelForce/vendor/symfony/error-handler/ErrorHandler.php on line 58

Deprecated: Constant E_STRICT is deprecated in /var/www/PixelForce/vendor/symfony/error-handler/ErrorHandler.php on line 76
Symfony Profiler

src/Entity/ProduitDD.php line 98

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\ProduitDDRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use App\Entity\CategorieDD;
  6. use Exception;
  7. use JsonSerializable;
  8. /**
  9.  * @ORM\Entity(repositoryClass=ProduitDDRepository::class)
  10.  */
  11. class ProduitDD implements JsonSerializable
  12. {
  13.     /**
  14.      * @ORM\Id
  15.      * @ORM\GeneratedValue
  16.      * @ORM\Column(type="integer")
  17.      */
  18.     private $id;
  19.     /**
  20.      * @ORM\Column(type="string", length=255)
  21.      */
  22.     private $nom;
  23.     /**
  24.      * @ORM\Column(type="string", length=3000, nullable=true)
  25.      */
  26.     private $description;
  27.     /**
  28.      * @ORM\Column(type="string", length=255, nullable=true)
  29.      */
  30.     private $photo;
  31.     /**
  32.      * @ORM\ManyToOne(targetEntity=Secteur::class, inversedBy="produits")
  33.      * @ORM\JoinColumn(nullable=false)
  34.      */
  35.     private $secteur;
  36.     /**
  37.      * @ORM\Column(type="integer")
  38.      */
  39.     private $statut;
  40.     /**
  41.      * @ORM\ManyToOne(targetEntity="CategorieDD", inversedBy="products")
  42.      * @ORM\JoinColumn(name="id_categorie", referencedColumnName="id")
  43.      */
  44.     private $categorie;
  45.     public function getId(): ?int
  46.     {
  47.         return $this->id;
  48.     }
  49.     public function getNom(): ?string
  50.     {
  51.         return $this->nom;
  52.     }
  53.     public function setNom(string $nom): self
  54.     {
  55.         $this->nom $nom;
  56.         return $this;
  57.     }
  58.     public function getDescription(): ?string
  59.     {
  60.         return $this->description;
  61.     }
  62.     public function setDescription(?string $description): self
  63.     {
  64.         $this->description $description;
  65.         return $this;
  66.     }
  67.     public function getPhoto(): ?string
  68.     {
  69.         return $this->photo;
  70.     }
  71.     public function setPhoto(?string $photo): self
  72.     {
  73.         $this->photo $photo;
  74.         return $this;
  75.     }
  76.     public function jsonSerialize()
  77.     {
  78.         $vars get_object_vars($this);
  79.         return $vars;
  80.     }
  81.     public function getSecteur(): ?Secteur
  82.     {
  83.         return $this->secteur;
  84.     }
  85.     public function setSecteur(?Secteur $secteur): self
  86.     {
  87.         $this->secteur $secteur;
  88.         return $this;
  89.     }
  90.     public function getStatut(): ?int
  91.     {
  92.         return $this->statut;
  93.     }
  94.     public function setStatut(int $statut): self
  95.     {
  96.         $this->statut $statut;
  97.         return $this;
  98.     }
  99.     /**
  100.      * Get the value of categorie
  101.      */ 
  102.     public function getCategorie(): ?CategorieDD
  103.     {
  104.         return $this->categorie;
  105.     }
  106.     /**
  107.      * Set the value of categorie
  108.      *
  109.      * @return  self
  110.      */ 
  111.     public function setCategorie(CategorieDD $categorie)
  112.     {
  113.         $this->categorie $categorie;
  114.         return $this;
  115.     }
  116.     
  117. }