Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2892414
PhortuneAccountSubscriptionController.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
1 KB
Referenced Files
None
Subscribers
None
PhortuneAccountSubscriptionController.php
View Options
<?php
final
class
PhortuneAccountSubscriptionController
extends
PhortuneAccountProfileController
{
protected
function
shouldRequireAccountEditCapability
(
)
{
return
false
;
}
protected
function
handleAccountRequest
(
AphrontRequest
$request
)
{
$account
=
$this
->
getAccount
(
)
;
$title
=
$account
->
getName
(
)
;
$crumbs
=
$this
->
buildApplicationCrumbs
(
)
->
addTextCrumb
(
pht
(
'Subscriptions'
)
)
->
setBorder
(
true
)
;
$header
=
$this
->
buildHeaderView
(
)
;
$authority
=
$this
->
newAccountAuthorityView
(
)
;
$subscriptions
=
$this
->
buildSubscriptionsSection
(
$account
)
;
$view
=
id
(
new
PHUITwoColumnView
(
)
)
->
setHeader
(
$header
)
->
setFooter
(
array
(
$authority
,
$subscriptions
,
)
)
;
$navigation
=
$this
->
buildSideNavView
(
'subscriptions'
)
;
return
$this
->
newPage
(
)
->
setTitle
(
$title
)
->
setCrumbs
(
$crumbs
)
->
setNavigation
(
$navigation
)
->
appendChild
(
$view
)
;
}
private
function
buildSubscriptionsSection
(
PhortuneAccount
$account
)
{
$viewer
=
$this
->
getViewer
(
)
;
$subscriptions
=
id
(
new
PhortuneSubscriptionQuery
(
)
)
->
setViewer
(
$viewer
)
->
withAccountPHIDs
(
array
(
$account
->
getPHID
(
)
)
)
->
setLimit
(
25
)
->
execute
(
)
;
$table
=
id
(
new
PhortuneSubscriptionTableView
(
)
)
->
setUser
(
$viewer
)
->
setSubscriptions
(
$subscriptions
)
;
$header
=
id
(
new
PHUIHeaderView
(
)
)
->
setHeader
(
pht
(
'Subscriptions'
)
)
;
return
id
(
new
PHUIObjectBoxView
(
)
)
->
setHeader
(
$header
)
->
setBackground
(
PHUIObjectBoxView
::
BLUE_PROPERTY
)
->
setTable
(
$table
)
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sun, Jan 19, 16:46 (2 w, 5 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1126624
Default Alt Text
PhortuneAccountSubscriptionController.php (1 KB)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment