From b92e6d3582f68ff99f06276fffb6bea23682f403 Mon Sep 17 00:00:00 2001 From: Chad Little Date: Mon, 10 Aug 2015 09:07:51 -0700 Subject: [PATCH] Update Dashboards for handleRequest Summary: Updates Dashboards app Test Plan: Click on Manage Dashboard, page load a.ok Reviewers: epriestley Reviewed By: epriestley Subscribers: Korvin Differential Revision: https://secure.phabricator.com/D13836 --- .../PhabricatorDashboardManageController.php | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/src/applications/dashboard/controller/PhabricatorDashboardManageController.php b/src/applications/dashboard/controller/PhabricatorDashboardManageController.php index 1719687b0d..6af8dc7b5e 100644 --- a/src/applications/dashboard/controller/PhabricatorDashboardManageController.php +++ b/src/applications/dashboard/controller/PhabricatorDashboardManageController.php @@ -3,16 +3,10 @@ final class PhabricatorDashboardManageController extends PhabricatorDashboardController { - private $id; + public function handleRequest(AphrontRequest $request) { + $viewer = $request->getViewer(); + $id = $request->getURIData('id'); - public function willProcessRequest(array $data) { - $this->id = $data['id']; - } - - public function processRequest() { - $request = $this->getRequest(); - $viewer = $request->getUser(); - $id = $this->id; $dashboard_uri = $this->getApplicationURI('view/'.$id.'/'); // TODO: This UI should drop a lot of capabilities if the user can't @@ -21,7 +15,7 @@ final class PhabricatorDashboardManageController $dashboard = id(new PhabricatorDashboardQuery()) ->setViewer($viewer) - ->withIDs(array($this->id)) + ->withIDs(array($id)) ->needPanels(true) ->executeOne(); if (!$dashboard) {