Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F102068831
PhabricatorApplicationPeople.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
Sun, Feb 16, 19:15
Size
1 KB
Mime Type
text/x-php
Expires
Tue, Feb 18, 19:15 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
24274725
Attached To
rPH Phabricator
PhabricatorApplicationPeople.php
View Options
<?php
final
class
PhabricatorApplicationPeople
extends
PhabricatorApplication
{
public
function
getShortDescription
()
{
return
'User Accounts'
;
}
public
function
getBaseURI
()
{
return
'/people/'
;
}
public
function
getTitleGlyph
()
{
return
"
\x
E2
\x
99
\x
9F"
;
}
public
function
getIconName
()
{
return
'people'
;
}
public
function
getFlavorText
()
{
return
pht
(
'Sort of a social utility.'
);
}
public
function
getApplicationGroup
()
{
return
self
::
GROUP_ADMIN
;
}
public
function
getRoutes
()
{
return
array
(
'/people/'
=>
array
(
''
=>
'PhabricatorPeopleListController'
,
'logs/'
=>
'PhabricatorPeopleLogsController'
,
'edit/(?:(?P<id>[1-9]
\d
*)/(?:(?P<view>
\w
+)/)?)?'
=>
'PhabricatorPeopleEditController'
,
'ldap/'
=>
'PhabricatorPeopleLdapController'
,
),
'/p/(?P<username>[
\w
._-]+)/(?:(?P<page>
\w
+)/)?'
=>
'PhabricatorPeopleProfileController'
,
'/emailverify/(?P<code>[^/]+)/'
=>
'PhabricatorEmailVerificationController'
,
);
}
public
function
buildMainMenuItems
(
PhabricatorUser
$user
,
PhabricatorController
$controller
=
null
)
{
$items
=
array
();
if
(
$user
->
isLoggedIn
())
{
$image
=
$user
->
loadProfileImageURI
();
$item
=
new
PhabricatorMenuItemView
();
$item
->
setName
(
$user
->
getUsername
());
$item
->
setHref
(
'/p/'
.
$user
->
getUsername
().
'/'
);
$item
->
setSortOrder
(
0.0
);
$item
->
addClass
(
'phabricator-core-menu-item-profile'
);
$classes
=
array
(
'phabricator-core-menu-icon'
,
'phabricator-core-menu-profile-image'
,
);
$item
->
appendChild
(
phutil_tag
(
'span'
,
array
(
'class'
=>
implode
(
' '
,
$classes
),
'style'
=>
'background-image: url('
.
$image
.
')'
,
),
''
));
$items
[]
=
$item
;
}
return
$items
;
}
}
Event Timeline
Log In to Comment