From 37b86b91b9264571d8777ef44d7192974a398a3b Mon Sep 17 00:00:00 2001 From: Anh Nhan Nguyen Date: Tue, 2 Apr 2013 08:59:14 -0700 Subject: [PATCH] Adding Phriction 'Document Index' link to the crumbs actions Summary: removed references to doc index from document controller / content display / whatever name it currently has Refs T2686 Test Plan: saw it - touched it - tested it Reviewers: epriestley, chad Reviewed By: chad CC: aran, Korvin Maniphest Tasks: T2686 Differential Revision: https://secure.phabricator.com/D5342 Conflicts: src/applications/phriction/controller/PhrictionDocumentController.php --- .../phriction/controller/PhrictionController.php | 8 ++++++++ .../controller/PhrictionDocumentController.php | 10 +--------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/applications/phriction/controller/PhrictionController.php b/src/applications/phriction/controller/PhrictionController.php index 26dccaea9c..de8d9f923d 100644 --- a/src/applications/phriction/controller/PhrictionController.php +++ b/src/applications/phriction/controller/PhrictionController.php @@ -49,6 +49,14 @@ abstract class PhrictionController extends PhabricatorController { public function buildApplicationCrumbs() { $crumbs = parent::buildApplicationCrumbs(); + if (get_class($this) != 'PhrictionListController') { + $crumbs->addAction( + id(new PhabricatorMenuItemView()) + ->setName(pht('Document Index')) + ->setHref('/phriction/') + ->setIcon('transcript')); + } + $crumbs->addAction( id(new PhabricatorMenuItemView()) ->setName(pht('Create Document')) diff --git a/src/applications/phriction/controller/PhrictionDocumentController.php b/src/applications/phriction/controller/PhrictionDocumentController.php index f6a6ca2d0a..3c206e0527 100644 --- a/src/applications/phriction/controller/PhrictionDocumentController.php +++ b/src/applications/phriction/controller/PhrictionDocumentController.php @@ -132,13 +132,6 @@ final class PhrictionDocumentController $handles[$project_phid]->renderLink())); } - $index_link = phutil_tag( - 'a', - array( - 'href' => '/phriction/', - ), - pht('Document Index')); - $subscriber_view = null; if ($subscribers) { $subcriber_list = array(); @@ -219,8 +212,7 @@ final class PhrictionDocumentController } $page_content = hsprintf( - '
%s%s%s%s
', - $index_link, + '
%s%s%s
', $byline, $move_notice, $core_content);