Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F112149458
PhabricatorHomeQuickCreateController.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, May 8, 05:31
Size
1 KB
Mime Type
text/x-php
Expires
Sat, May 10, 05:31 (2 d)
Engine
blob
Format
Raw Data
Handle
26039661
Attached To
rPH Phabricator
PhabricatorHomeQuickCreateController.php
View Options
<?php
final
class
PhabricatorHomeQuickCreateController
extends
PhabricatorHomeController
{
public
function
processRequest
()
{
$viewer
=
$this
->
getRequest
()->
getUser
();
$applications
=
id
(
new
PhabricatorApplicationQuery
())
->
setViewer
(
$viewer
)
->
withInstalled
(
true
)
->
execute
();
$items
=
array
();
foreach
(
$applications
as
$application
)
{
$app_items
=
$application
->
getQuickCreateItems
(
$viewer
);
foreach
(
$app_items
as
$app_item
)
{
$items
[]
=
$app_item
;
}
}
$list
=
id
(
new
PHUIObjectItemListView
())
->
setUser
(
$viewer
);
foreach
(
$items
as
$item
)
{
$list
->
addItem
(
id
(
new
PHUIObjectItemView
())
->
setHeader
(
$item
->
getName
())
->
setWorkflow
(
$item
->
getWorkflow
())
->
setHref
(
$item
->
getHref
()));
}
$crumbs
=
$this
->
buildApplicationCrumbs
();
$crumbs
->
addTextCrumb
(
pht
(
'Quick Create'
));
return
$this
->
buildApplicationPage
(
array
(
$crumbs
,
$list
,
),
array
(
'title'
=>
pht
(
'Quick Create'
),
));
}
}
Event Timeline
Log In to Comment