Something went wrong. Try again.
@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
Something went wrong. Try again.
1.9 kB · 61 lines
PHP
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162<?php
final class PhabricatorProjectProfileMenuEngine extends PhabricatorProfileMenuEngine {
protected function isMenuEngineConfigurable() { return true; }
protected function isMenuEnginePersonalizable() { return false; }
public function getItemURI($path) { $project = $this->getProfileObject(); $id = $project->getID(); return "/project/{$id}/item/{$path}"; }
protected function getBuiltinProfileItems($object) { $items = array();
$items[] = $this->newItem() ->setBuiltinKey(PhabricatorProject::ITEM_PICTURE) ->setMenuItemKey(PhabricatorProjectPictureProfileMenuItem::MENUITEMKEY) ->setIsHeadItem(true);
$items[] = $this->newItem() ->setBuiltinKey(PhabricatorProject::ITEM_PROFILE) ->setMenuItemKey(PhabricatorProjectDetailsProfileMenuItem::MENUITEMKEY);
$items[] = $this->newItem() ->setBuiltinKey(PhabricatorProject::ITEM_POINTS) ->setMenuItemKey(PhabricatorProjectPointsProfileMenuItem::MENUITEMKEY);
$items[] = $this->newItem() ->setBuiltinKey(PhabricatorProject::ITEM_WORKBOARD) ->setMenuItemKey(PhabricatorProjectWorkboardProfileMenuItem::MENUITEMKEY);
$items[] = $this->newItem() ->setBuiltinKey(PhabricatorProject::ITEM_REPORTS) ->setMenuItemKey(PhabricatorProjectReportsProfileMenuItem::MENUITEMKEY);
$items[] = $this->newItem() ->setBuiltinKey(PhabricatorProject::ITEM_MEMBERS) ->setMenuItemKey(PhabricatorProjectMembersProfileMenuItem::MENUITEMKEY);
$items[] = $this->newItem() ->setBuiltinKey(PhabricatorProject::ITEM_SUBPROJECTS) ->setMenuItemKey( PhabricatorProjectSubprojectsProfileMenuItem::MENUITEMKEY);
$items[] = $this->newItem() ->setBuiltinKey(PhabricatorProject::ITEM_MANAGE) ->setMenuItemKey(PhabricatorProjectManageProfileMenuItem::MENUITEMKEY) ->setIsTailItem(true);
return $items; }
}