mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
Fix serialization of accompangying period work referrers
This commit is contained in:
parent
1b0a30baf8
commit
88469dbe8e
5
.changes/unreleased/Fixed-20231114-183343.yaml
Normal file
5
.changes/unreleased/Fixed-20231114-183343.yaml
Normal file
@ -0,0 +1,5 @@
|
||||
kind: Fixed
|
||||
body: 'Fix loading of accompanying period work referrers '
|
||||
time: 2023-11-14T18:33:43.284236146+01:00
|
||||
custom:
|
||||
Issue: "205"
|
@ -392,9 +392,13 @@ class AccompanyingPeriodWork implements AccompanyingPeriodLinkedWithSocialIssues
|
||||
*/
|
||||
public function getReferrers(): ReadableCollection
|
||||
{
|
||||
return $this->referrersHistory
|
||||
$users = $this->referrersHistory
|
||||
->filter(fn (AccompanyingPeriodWorkReferrerHistory $h) => null === $h->getEndDate())
|
||||
->map(fn (AccompanyingPeriodWorkReferrerHistory $h) => $h->getUser());
|
||||
->map(fn (AccompanyingPeriodWorkReferrerHistory $h) => $h->getUser())
|
||||
->getValues()
|
||||
;
|
||||
|
||||
return new ArrayCollection(array_values($users));
|
||||
}
|
||||
|
||||
public function getReferrersHistory(): Collection
|
||||
|
Loading…
x
Reference in New Issue
Block a user