diff --git a/src/Controller/ItineraryController.php b/src/Controller/ItineraryController.php index 272c939..19996b8 100644 --- a/src/Controller/ItineraryController.php +++ b/src/Controller/ItineraryController.php @@ -42,6 +42,8 @@ class ItineraryController extends AbstractController #[Route('/itinerary/report', name: 'app_report_itinerary')] public function reportItinerary(Request $request, #[CurrentUser()] ?User $user): Response { + $this->navLinks['case_itinerary'] = NavList::PRESENT_LINK; + $this->msgs = $this->entityManager->getRepository(Messages::class)->getUnreadMessages($user); $this->notificationCount = $this->entityManager->getRepository(Messages::class)->getUnreadMessageCount($user); @@ -76,6 +78,8 @@ class ItineraryController extends AbstractController #[Route('/itinerary/map', name: 'app_map_itinerary')] public function mapItinerary(Request $request, #[CurrentUser()] ?User $user): Response { + $this->navLinks['case_itinerary'] = NavList::PRESENT_LINK; + $case = null; if ($request->getPayload()->get('caseId')) { $case = $this->entityManager->getRepository(MemberCase::class)->find($request->getPayload()->get('caseId')); @@ -93,8 +97,8 @@ class ItineraryController extends AbstractController ]); $map = new Map('default'); - $map->center(new Point(39.768502, -86.157918)) - ->zoom(9) + $map->center(new Point($_ENV['MAP_CENTER_LAT'], $_ENV['MAP_CENTER_LON'])) + ->zoom($_ENV['MAP_ZOOM_LEVEL']) ; $total_distance = 0; @@ -148,7 +152,7 @@ class ItineraryController extends AbstractController [ 'breadcrumbs' => [ new Breadcrumb($this->generateUrl('app_my_cases'), 'My Cases'), - new Breadcrumb($this->generateUrl('app_itinerary_report'), 'Itinerary Report'), + new Breadcrumb($this->generateUrl('app_report_itinerary'), 'Itinerary Report'), ], 'notifications' => $this->msgs, 'notificationCount' => $this->notificationCount,