Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F115061462
PhabricatorChatLogChannelListController.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 29, 13:32
Size
1 KB
Mime Type
text/x-php
Expires
Sat, May 31, 13:32 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
26442321
Attached To
rPH Phabricator
PhabricatorChatLogChannelListController.php
View Options
<?php
final
class
PhabricatorChatLogChannelListController
extends
PhabricatorChatLogController
{
public
function
shouldAllowPublic
()
{
return
true
;
}
public
function
handleRequest
(
AphrontRequest
$request
)
{
$viewer
=
$request
->
getViewer
();
$channels
=
id
(
new
PhabricatorChatLogChannelQuery
())
->
setViewer
(
$viewer
)
->
execute
();
$list
=
new
PHUIObjectItemListView
();
foreach
(
$channels
as
$channel
)
{
$item
=
id
(
new
PHUIObjectItemView
())
->
setHeader
(
$channel
->
getChannelName
())
->
setHref
(
'/chatlog/channel/'
.
$channel
->
getID
().
'/'
)
->
addAttribute
(
$channel
->
getServiceName
())
->
addAttribute
(
$channel
->
getServiceType
());
$list
->
addItem
(
$item
);
}
$crumbs
=
$this
->
buildApplicationCrumbs
()
->
addTextCrumb
(
pht
(
'Channel List'
),
$this
->
getApplicationURI
());
$box
=
id
(
new
PHUIObjectBoxView
())
->
setHeaderText
(
'Channel List'
)
->
setObjectList
(
$list
);
return
$this
->
buildApplicationPage
(
array
(
$crumbs
,
$box
,
),
array
(
'title'
=>
pht
(
'Channel List'
),
));
}
}
Event Timeline
Log In to Comment