Page MenuHomePhabricator

D12827.diff
No OneTemporary

D12827.diff

diff --git a/src/applications/people/controller/PhabricatorPeopleCalendarController.php b/src/applications/people/controller/PhabricatorPeopleCalendarController.php
--- a/src/applications/people/controller/PhabricatorPeopleCalendarController.php
+++ b/src/applications/people/controller/PhabricatorPeopleCalendarController.php
@@ -41,18 +41,37 @@
"{$year}-{$month}-01",
"{$year}-{$month}-31");
+ $start_epoch = strtotime("{$year}-{$month}-01");
+ $end_epoch = strtotime("{$year}-{$month}-01 next month");
+
$statuses = id(new PhabricatorCalendarEventQuery())
->setViewer($user)
->withInvitedPHIDs(array($user->getPHID()))
->withDateRange(
- strtotime("{$year}-{$month}-01"),
- strtotime("{$year}-{$month}-01 next month"))
+ $start_epoch,
+ $end_epoch)
->execute();
+ $start_range_value = AphrontFormDateControlValue::newFromEpoch(
+ $user,
+ $start_epoch);
+ $end_range_value = AphrontFormDateControlValue::newFromEpoch(
+ $user,
+ $end_epoch);
+
if ($month == $month_d && $year == $year_d) {
- $month_view = new PHUICalendarMonthView($month, $year, $day);
+ $month_view = new PHUICalendarMonthView(
+ $start_range_value,
+ $end_range_value,
+ $month,
+ $year,
+ $day);
} else {
- $month_view = new PHUICalendarMonthView($month, $year);
+ $month_view = new PHUICalendarMonthView(
+ $start_range_value,
+ $end_range_value,
+ $month,
+ $year);
}
$month_view->setBrowseURI($request->getRequestURI());
@@ -67,7 +86,7 @@
$event = new AphrontCalendarEventView();
$event->setEpochRange($status->getDateFrom(), $status->getDateTo());
$event->setUserPHID($status->getUserPHID());
- $event->setName($status->getHumanStatus());
+ $event->setName($status->getName());
$event->setDescription($status->getDescription());
$event->setEventID($status->getID());
$month_view->addEvent($event);

File Metadata

Mime Type
text/plain
Expires
Sun, Mar 9, 7:09 PM (1 w, 5 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7390831
Default Alt Text
D12827.diff (1 KB)

Event Timeline