From e1e4c12801e49492bc400ac05dbc20d73b474a6d Mon Sep 17 00:00:00 2001 From: Ryan Prather Date: Fri, 10 Jan 2025 14:44:59 +0000 Subject: [PATCH] add InfoWindow data methods for mapping --- src/Entity/CaseItinerary.php | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/Entity/CaseItinerary.php b/src/Entity/CaseItinerary.php index 344e4bf..7eda2ba 100644 --- a/src/Entity/CaseItinerary.php +++ b/src/Entity/CaseItinerary.php @@ -191,4 +191,22 @@ class CaseItinerary } return $points; } + + public function originInfoWindow(): string + { + return <<originLocation->getName()}
+ {$this->originLocation->getFormattedAddress()}
+ {$this->departure->format("g:i a")} + EOL; + } + + public function destinationInfoWindow(): string + { + return <<destLocation->getName()}
+ {$this->destLocation->getFormattedAddress()}
+ {$this->arrival->format("g:i a")} + EOL; + } }