src/Entity/ContractAgreement.php line 10

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\ContractAgreementRepository;
  4. use Doctrine\DBAL\Types\Types;
  5. use Doctrine\ORM\Mapping as ORM;
  6. #[ORM\Entity(repositoryClassContractAgreementRepository::class)]
  7. class ContractAgreement
  8. {
  9.     #[ORM\Id]
  10.     #[ORM\GeneratedValue]
  11.     #[ORM\Column]
  12.     private ?int $id null;
  13.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  14.     private ?string $content null;
  15.     #[ORM\OneToOne(inversedBy'agreement'targetEntityContract::class, cascade: ['persist''remove'])]
  16.     #[ORM\JoinColumn(name'fk_contract'nullablefalse)]
  17.     private ?Contract $contract null;
  18.     public function getId(): ?int
  19.     {
  20.         return $this->id;
  21.     }
  22.     public function getContent(): ?string
  23.     {
  24.         return $this->content;
  25.     }
  26.     public function setContent(?string $content): self
  27.     {
  28.         $this->content $content;
  29.         return $this;
  30.     }
  31.     public function getContract(): ?Contract
  32.     {
  33.         return $this->contract;
  34.     }
  35.     public function setContract(?Contract $contract): self
  36.     {
  37.         $this->contract $contract;
  38.         return $this;
  39.     }
  40. }