Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F124740920
PhabricatorPeopleProfileController.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Mon, Aug 4, 09:04
Size
1 KB
Mime Type
text/x-php
Expires
Wed, Aug 6, 09:04 (2 d)
Engine
blob
Format
Raw Data
Handle
27888730
Attached To
rPH Phabricator
PhabricatorPeopleProfileController.php
View Options
<?php
abstract
class
PhabricatorPeopleProfileController
extends
PhabricatorPeopleController
{
private
$user
;
private
$profileMenu
;
public
function
shouldRequireAdmin
()
{
return
false
;
}
public
function
setUser
(
PhabricatorUser
$user
)
{
$this
->
user
=
$user
;
return
$this
;
}
public
function
getUser
()
{
return
$this
->
user
;
}
public
function
buildApplicationMenu
()
{
$menu
=
$this
->
newApplicationMenu
();
$profile_menu
=
$this
->
getProfileMenu
();
if
(
$profile_menu
)
{
$menu
->
setProfileMenu
(
$profile_menu
);
}
return
$menu
;
}
protected
function
getProfileMenu
()
{
if
(!
$this
->
profileMenu
)
{
$user
=
$this
->
getUser
();
if
(
$user
)
{
$viewer
=
$this
->
getViewer
();
$engine
=
id
(
new
PhabricatorPeopleProfileMenuEngine
())
->
setViewer
(
$viewer
)
->
setProfileObject
(
$user
);
$this
->
profileMenu
=
$engine
->
buildNavigation
();
}
}
return
$this
->
profileMenu
;
}
protected
function
buildApplicationCrumbs
()
{
$crumbs
=
parent
::
buildApplicationCrumbs
();
$user
=
$this
->
getUser
();
if
(
$user
)
{
$crumbs
->
addTextCrumb
(
$user
->
getUsername
(),
urisprintf
(
'/p/%s/'
,
$user
->
getUsername
()));
}
return
$crumbs
;
}
}
Event Timeline
Log In to Comment