Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F91028902
PhabricatorFavoritesMenuItemController.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
Thu, Nov 7, 02:18
Size
953 B
Mime Type
text/x-php
Expires
Sat, Nov 9, 02:18 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
22181665
Attached To
rPH Phabricator
PhabricatorFavoritesMenuItemController.php
View Options
<?php
final
class
PhabricatorFavoritesMenuItemController
extends
PhabricatorFavoritesController
{
public
function
handleRequest
(
AphrontRequest
$request
)
{
$viewer
=
$this
->
getViewer
();
$type
=
$request
->
getURIData
(
'type'
);
$custom_phid
=
null
;
$menu
=
PhabricatorProfileMenuEngine
::
MENU_GLOBAL
;
if
(
$type
==
'personal'
)
{
$custom_phid
=
$viewer
->
getPHID
();
$menu
=
PhabricatorProfileMenuEngine
::
MENU_PERSONAL
;
}
$application
=
'PhabricatorFavoritesApplication'
;
$favorites
=
id
(
new
PhabricatorApplicationQuery
())
->
setViewer
(
$viewer
)
->
withClasses
(
array
(
$application
))
->
withInstalled
(
true
)
->
executeOne
();
$engine
=
id
(
new
PhabricatorFavoritesProfileMenuEngine
())
->
setProfileObject
(
$favorites
)
->
setCustomPHID
(
$custom_phid
)
->
setController
(
$this
)
->
setMenuType
(
$menu
)
->
setShowNavigation
(
false
);
return
$engine
->
buildResponse
();
}
}
Event Timeline
Log In to Comment