diff options
Diffstat (limited to 'src/model/entities/CESU.php')
-rw-r--r-- | src/model/entities/CESU.php | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/model/entities/CESU.php b/src/model/entities/CESU.php index 09a2542..de3a359 100644 --- a/src/model/entities/CESU.php +++ b/src/model/entities/CESU.php | |||
@@ -13,9 +13,12 @@ class CESU | |||
13 | #[ORM\GeneratedValue] | 13 | #[ORM\GeneratedValue] |
14 | private int|null $id = null; | 14 | private int|null $id = null; |
15 | 15 | ||
16 | #[ORM\ManyToOne(targetEntity: Prestation::class, cascade: ['persist'])] | 16 | //~ #[ORM\ManyToOne(targetEntity: Prestation::class, cascade: ['persist'])] |
17 | //~ #[ORM\JoinColumn(name: 'id_presta', referencedColumnName: 'id')] | ||
18 | //~ private Prestation|null $presta = null; | ||
19 | #[ORM\OneToOne(targetEntity: Prestation::class, inversedBy: 'cesu', cascade: ['persist'])] | ||
17 | #[ORM\JoinColumn(name: 'id_presta', referencedColumnName: 'id')] | 20 | #[ORM\JoinColumn(name: 'id_presta', referencedColumnName: 'id')] |
18 | private Prestation|null $presta = null; | 21 | private ?Prestation $presta = null; |
19 | 22 | ||
20 | #[ORM\Column] | 23 | #[ORM\Column] |
21 | private string $taches; | 24 | private string $taches; |
@@ -39,6 +42,10 @@ class CESU | |||
39 | { | 42 | { |
40 | return $this->presta; | 43 | return $this->presta; |
41 | } | 44 | } |
45 | public function getSalaire(): float | ||
46 | { | ||
47 | return $this->salaire; | ||
48 | } | ||
42 | 49 | ||
43 | public function getAllWithWindowFields(): array | 50 | public function getAllWithWindowFields(): array |
44 | { | 51 | { |