Page MenuHomePhabricator

D18843.id45203.diff
No OneTemporary

D18843.id45203.diff

diff --git a/src/applications/project/controller/PhabricatorProjectViewController.php b/src/applications/project/controller/PhabricatorProjectViewController.php
--- a/src/applications/project/controller/PhabricatorProjectViewController.php
+++ b/src/applications/project/controller/PhabricatorProjectViewController.php
@@ -20,6 +20,14 @@
$engine = $this->getProfileMenuEngine();
$default = $engine->getDefaultItem();
+ // If defaults are broken somehow, serve the manage page. See T13033 for
+ // discussion.
+ if ($default) {
+ $default_key = $default->getBuiltinKey();
+ } else {
+ $default_key = PhabricatorProject::ITEM_MANAGE;
+ }
+
switch ($default->getBuiltinKey()) {
case PhabricatorProject::ITEM_WORKBOARD:
$controller_object = new PhabricatorProjectBoardViewController();
@@ -27,6 +35,9 @@
case PhabricatorProject::ITEM_PROFILE:
$controller_object = new PhabricatorProjectProfileController();
break;
+ case PhabricatorProject::ITEM_MANAGE:
+ $controller_object = new PhabricatorProjectManageController();
+ break;
default:
return $engine->buildResponse();
}
diff --git a/src/applications/project/menuitem/PhabricatorProjectManageProfileMenuItem.php b/src/applications/project/menuitem/PhabricatorProjectManageProfileMenuItem.php
--- a/src/applications/project/menuitem/PhabricatorProjectManageProfileMenuItem.php
+++ b/src/applications/project/menuitem/PhabricatorProjectManageProfileMenuItem.php
@@ -18,6 +18,11 @@
return false;
}
+ public function canMakeDefault(
+ PhabricatorProfileMenuItemConfiguration $config) {
+ return true;
+ }
+
public function getDisplayName(
PhabricatorProfileMenuItemConfiguration $config) {
$name = $config->getMenuItemProperty('name');

File Metadata

Mime Type
text/plain
Expires
Wed, Mar 12, 6:33 AM (1 w, 4 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7577564
Default Alt Text
D18843.id45203.diff (1 KB)

Event Timeline