Rename all ProfilePanels into ProfileMenuItems

Summary: Ref T11957.

Test Plan:
  - Viewed an existing project profile.
  - Viewed a user profile.
  - Created a new project.
  - Edited a profile menu.
  - Added new profile items.
  - Grepped for renamed symbols.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T11957

Differential Revision: https://secure.phabricator.com/D17028
This commit is contained in:
epriestley
2016-12-11 10:08:26 -08:00
parent 8480776ccd
commit 42896f9f90
40 changed files with 389 additions and 388 deletions

View File

@@ -6,7 +6,7 @@ abstract class PhabricatorProjectBoardController
protected function getProfileMenu() {
$menu = parent::getProfileMenu();
$menu->selectFilter(PhabricatorProject::PANEL_WORKBOARD);
$menu->selectFilter(PhabricatorProject::ITEM_WORKBOARD);
$menu->addClass('project-board-nav');
return $menu;

View File

@@ -170,7 +170,7 @@ final class PhabricatorProjectBoardViewController
}
$nav = $this->getProfileMenu();
$nav->selectFilter(PhabricatorProject::PANEL_WORKBOARD);
$nav->selectFilter(PhabricatorProject::ITEM_WORKBOARD);
$crumbs = $this->buildApplicationCrumbs();
$crumbs->addTextCrumb(pht('Workboard'));
@@ -936,7 +936,7 @@ final class PhabricatorProjectBoardViewController
if ($set_default) {
$this
->getProfileMenuEngine()
->adjustDefault(PhabricatorProject::PANEL_WORKBOARD);
->adjustDefault(PhabricatorProject::ITEM_WORKBOARD);
}
if ($request->isFormPost()) {

View File

@@ -255,7 +255,7 @@ final class PhabricatorProjectEditPictureController
->setForm($upload_form);
$nav = $this->getProfileMenu();
$nav->selectFilter(PhabricatorProject::PANEL_MANAGE);
$nav->selectFilter(PhabricatorProject::ITEM_MANAGE);
return $this->newPage()
->setTitle($title)

View File

@@ -39,7 +39,7 @@ final class PhabricatorProjectManageController
$timeline->setShouldTerminate(true);
$nav = $this->getProfileMenu();
$nav->selectFilter(PhabricatorProject::PANEL_MANAGE);
$nav->selectFilter(PhabricatorProject::ITEM_MANAGE);
$crumbs = $this->buildApplicationCrumbs();
$crumbs->addTextCrumb(pht('Manage'));
@@ -91,7 +91,7 @@ final class PhabricatorProjectManageController
id(new PhabricatorActionView())
->setName(pht('Edit Menu'))
->setIcon('fa-th-list')
->setHref($this->getApplicationURI("{$id}/panel/configure/"))
->setHref($this->getApplicationURI("{$id}/item/configure/"))
->setDisabled(!$can_edit)
->setWorkflow(!$can_edit));

View File

@@ -42,7 +42,7 @@ final class PhabricatorProjectMembersViewController
->setUserPHIDs($project->getWatcherPHIDs());
$nav = $this->getProfileMenu();
$nav->selectFilter(PhabricatorProject::PANEL_MEMBERS);
$nav->selectFilter(PhabricatorProject::ITEM_MEMBERS);
$crumbs = $this->buildApplicationCrumbs();
$crumbs->addTextCrumb(pht('Members'));

View File

@@ -1,6 +1,6 @@
<?php
final class PhabricatorProjectPanelController
final class PhabricatorProjectMenuItemController
extends PhabricatorProjectController {
public function handleRequest(AphrontRequest $request) {

View File

@@ -70,7 +70,7 @@ final class PhabricatorProjectProfileController
->setUserPHIDs($project->getWatcherPHIDs());
$nav = $this->getProfileMenu();
$nav->selectFilter(PhabricatorProject::PANEL_PROFILE);
$nav->selectFilter(PhabricatorProject::ITEM_PROFILE);
$stories = id(new PhabricatorFeedQuery())
->setViewer($viewer)

View File

@@ -92,7 +92,7 @@ final class PhabricatorProjectSubprojectsController
->addPropertyList($property_list);
$nav = $this->getProfileMenu();
$nav->selectFilter(PhabricatorProject::PANEL_SUBPROJECTS);
$nav->selectFilter(PhabricatorProject::ITEM_SUBPROJECTS);
$crumbs = $this->buildApplicationCrumbs();
$crumbs->addTextCrumb(pht('Subprojects'));

View File

@@ -18,13 +18,13 @@ final class PhabricatorProjectViewController
$project = $this->getProject();
$engine = $this->getProfileMenuEngine();
$default = $engine->getDefaultPanel();
$default = $engine->getDefaultItem();
switch ($default->getBuiltinKey()) {
case PhabricatorProject::PANEL_WORKBOARD:
case PhabricatorProject::ITEM_WORKBOARD:
$controller_object = new PhabricatorProjectBoardViewController();
break;
case PhabricatorProject::PANEL_PROFILE:
case PhabricatorProject::ITEM_PROFILE:
default:
$controller_object = new PhabricatorProjectProfileController();
break;