Fix displaying calendar: reproduce same getAtDate method as Activity

This commit is contained in:
Julien Fastré 2024-06-07 13:07:25 +02:00
parent ebb856fe85
commit f62f1891d8
Signed by: julienfastre
GPG Key ID: BDE2190974723FCB

View File

@ -524,6 +524,16 @@ class Calendar implements TrackCreationInterface, TrackUpdateInterface, HasCente
return $this->startDate;
}
/**
* get the date of the calendar.
*
* Useful for showing the date of the calendar event, required by twig in some places.
*/
public function getDate(): ?\DateTimeImmutable
{
return $this->getStartDate();
}
public function getStatus(): ?string
{
return $this->status;