From 959337ec62f5f72dacd6541715106c2a54d19449 Mon Sep 17 00:00:00 2001 From: epriestley Date: Fri, 15 Jul 2016 14:17:58 -0700 Subject: [PATCH] Add crumbs to Calendar events to return to the month/day view Summary: Ref T11326. This makes it a little easier to jump back up to check out your day. Test Plan: {F1725575} Reviewers: chad Reviewed By: chad Maniphest Tasks: T11326 Differential Revision: https://secure.phabricator.com/D16309 --- .../PhabricatorCalendarEventViewController.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/applications/calendar/controller/PhabricatorCalendarEventViewController.php b/src/applications/calendar/controller/PhabricatorCalendarEventViewController.php index 16e057ebcc..08c7d91869 100644 --- a/src/applications/calendar/controller/PhabricatorCalendarEventViewController.php +++ b/src/applications/calendar/controller/PhabricatorCalendarEventViewController.php @@ -26,6 +26,18 @@ final class PhabricatorCalendarEventViewController $monogram = $event->getMonogram(); $page_title = $monogram.' '.$event->getName(); $crumbs = $this->buildApplicationCrumbs(); + + $start = new DateTime('@'.$event->getViewerDateFrom()); + $start->setTimeZone($viewer->getTimeZone()); + + $crumbs->addTextCrumb( + $start->format('F Y'), + '/calendar/query/month/'.$start->format('Y/m/')); + + $crumbs->addTextCrumb( + $start->format('D jS'), + '/calendar/query/month/'.$start->format('Y/m/d/')); + $crumbs->addTextCrumb($monogram); $crumbs->setBorder(true);