src/Entity/EnterpriseHasEquipment.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Entity\Trait\isActif;
  4. use App\Repository\EnterpriseHasEquipmentRepository;
  5. use Doctrine\ORM\Mapping as ORM;
  6. /**
  7.  * @ORM\Entity(repositoryClass=EnterpriseHasEquipmentRepository::class)
  8.  */
  9. class EnterpriseHasEquipment
  10. {
  11.     use isActif;
  12.     /**
  13.      * @ORM\Id
  14.      * @ORM\GeneratedValue
  15.      * @ORM\Column(type="integer")
  16.      */
  17.     private $id;
  18.     /**
  19.      * @ORM\ManyToOne(targetEntity=Equipment::class, cascade={"detach"})
  20.      */
  21.     private $equipment;
  22.     /**
  23.      * @ORM\ManyToOne(targetEntity=Enterprise::class, inversedBy="equipments", cascade={"detach"})
  24.      */
  25.     private $enterprise;
  26.     /**
  27.      * @ORM\Column(type="boolean")
  28.      */
  29.     private $used;
  30.     /**
  31.      * @ORM\ManyToOne(targetEntity=Contract::class)
  32.      */
  33.     private $contract;
  34.     public function getId(): ?int
  35.     {
  36.         return $this->id;
  37.     }
  38.     public function getEquipment(): ?Equipment
  39.     {
  40.         return $this->equipment;
  41.     }
  42.     public function setEquipment(?Equipment $equipment): self
  43.     {
  44.         $this->equipment $equipment;
  45.         return $this;
  46.     }
  47.     public function getEnterprise(): ?Enterprise
  48.     {
  49.         return $this->enterprise;
  50.     }
  51.     public function setEnterprise(?Enterprise $enterprise): self
  52.     {
  53.         $this->enterprise $enterprise;
  54.         return $this;
  55.     }
  56.     public function getUsed(): ?bool
  57.     {
  58.         return $this->used;
  59.     }
  60.     public function setUsed(bool $used): self
  61.     {
  62.         $this->used $used;
  63.         return $this;
  64.     }
  65.     public function getContract(): ?Contract
  66.     {
  67.         return $this->contract;
  68.     }
  69.     public function setContract(?Contract $contract): self
  70.     {
  71.         $this->contract $contract;
  72.         return $this;
  73.     }
  74. }