Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F14022682
D12631.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D12631.id.diff
View Options
diff --git a/src/applications/calendar/query/PhabricatorCalendarEventSearchEngine.php b/src/applications/calendar/query/PhabricatorCalendarEventSearchEngine.php
--- a/src/applications/calendar/query/PhabricatorCalendarEventSearchEngine.php
+++ b/src/applications/calendar/query/PhabricatorCalendarEventSearchEngine.php
@@ -191,35 +191,23 @@
PhabricatorSavedQuery $query,
array $handles) {
assert_instances_of($events, 'PhabricatorCalendarEvent');
-
$viewer = $this->requireViewer();
-
$list = new PHUIObjectItemListView();
foreach ($events as $event) {
- if ($event->getUserPHID() == $viewer->getPHID()) {
- $href = '/E'.$event->getID();
- } else {
- $from = $event->getDateFrom();
- $month = phabricator_format_local_time($from, $viewer, 'm');
- $year = phabricator_format_local_time($from, $viewer, 'Y');
- $uri = new PhutilURI($this->getApplicationURI());
- $uri->setQueryParams(
- array(
- 'month' => $month,
- 'year' => $year,
- ));
- $href = (string) $uri;
- }
+ $href = '/E'.$event->getID();
$from = phabricator_datetime($event->getDateFrom(), $viewer);
$to = phabricator_datetime($event->getDateTo(), $viewer);
$creator_handle = $handles[$event->getUserPHID()];
+ $name = (strlen($event->getName())) ?
+ $event->getName() : $event->getTerseSummary($viewer);
+
$color = ($event->getStatus() == PhabricatorCalendarEvent::STATUS_AWAY)
? 'red'
: 'yellow';
$item = id(new PHUIObjectItemView())
- ->setHeader($event->getTerseSummary($viewer))
+ ->setHeader($name)
->setHref($href)
->setBarColor($color)
->addByline(pht('Creator: %s', $creator_handle->renderLink()))
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Nov 7, 6:41 PM (1 w, 4 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6714254
Default Alt Text
D12631.id.diff (1 KB)
Attached To
Mode
D12631: Calendar items in Upcoming Events query should link to events, not calendar
Attached
Detach File
Event Timeline
Log In to Comment