From ada5f81614b874a08883029af08177cba50211cf Mon Sep 17 00:00:00 2001 From: vrana Date: Fri, 31 Aug 2012 13:02:15 -0700 Subject: [PATCH] Display 'away until' in owners and revision comment Summary: It would be best to add this everywhere at once but I'm too lazy for it. Test Plan: Displayed package list and detail and revision comment with away users. Reviewers: epriestley Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D3419 --- .../controller/DifferentialCommentPreviewController.php | 1 + .../controller/PhabricatorOwnersDetailController.php | 8 ++++++-- .../owners/controller/PhabricatorOwnersListController.php | 4 +++- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/src/applications/differential/controller/DifferentialCommentPreviewController.php b/src/applications/differential/controller/DifferentialCommentPreviewController.php index 3c97ed0e45..c7d080083e 100644 --- a/src/applications/differential/controller/DifferentialCommentPreviewController.php +++ b/src/applications/differential/controller/DifferentialCommentPreviewController.php @@ -60,6 +60,7 @@ final class DifferentialCommentPreviewController } $handles = id(new PhabricatorObjectHandleData($handles)) + ->setViewer($request->getUser()) ->loadHandles(); $view = new DifferentialRevisionCommentView(); diff --git a/src/applications/owners/controller/PhabricatorOwnersDetailController.php b/src/applications/owners/controller/PhabricatorOwnersDetailController.php index 368997a14c..bc511a3b65 100644 --- a/src/applications/owners/controller/PhabricatorOwnersDetailController.php +++ b/src/applications/owners/controller/PhabricatorOwnersDetailController.php @@ -59,7 +59,9 @@ final class PhabricatorOwnersDetailController } $phids = array_keys($phids); - $handles = id(new PhabricatorObjectHandleData($phids))->loadHandles(); + $handles = id(new PhabricatorObjectHandleData($phids)) + ->setViewer($this->getRequest()->getUser()) + ->loadHandles(); $rows = array(); @@ -214,7 +216,9 @@ final class PhabricatorOwnersDetailController $phids[] = $commit_view['view']->getRequiredHandlePHIDs(); } $phids = array_mergev($phids); - $handles = id(new PhabricatorObjectHandleData($phids))->loadHandles(); + $handles = id(new PhabricatorObjectHandleData($phids)) + ->setViewer($user) + ->loadHandles(); $commit_panels = array(); foreach ($commit_views as $commit_view) { diff --git a/src/applications/owners/controller/PhabricatorOwnersListController.php b/src/applications/owners/controller/PhabricatorOwnersListController.php index a6fb2287a2..f53749a666 100644 --- a/src/applications/owners/controller/PhabricatorOwnersListController.php +++ b/src/applications/owners/controller/PhabricatorOwnersListController.php @@ -222,7 +222,9 @@ final class PhabricatorOwnersListController $phids[$owner->getUserPHID()] = true; } $phids = array_keys($phids); - $handles = id(new PhabricatorObjectHandleData($phids))->loadHandles(); + $handles = id(new PhabricatorObjectHandleData($phids)) + ->setViewer($this->getRequest()->getUser()) + ->loadHandles(); $repository_phids = array(); foreach ($paths as $path) {