| 123456789101112131415161718192021222324252627282930313233343536373839404142 |
- <?php
- declare(strict_types=1);
- namespace App\Entity\Core;
- // use DH\Auditor\Provider\Doctrine\Auditing\Annotation\Auditable;
- use Doctrine\ORM\Mapping as ORM;
- /**
- * Classe ... qui ...
- */
- // #[Auditable]
- #[ORM\Entity]
- class Department
- {
- #[ORM\Id]
- #[ORM\Column]
- #[ORM\GeneratedValue]
- private ?int $id = null;
- #[ORM\ManyToOne(targetEntity: Region::class, cascade: [])]
- #[ORM\JoinColumn(nullable: false)]
- protected Region $region;
- public function getId(): ?int
- {
- return $this->id;
- }
- public function getRegion(): Region
- {
- return $this->region;
- }
- public function setRegion(Region $region): self
- {
- $this->region = $region;
- return $this;
- }
- }
|