Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F96527055
ReleephController.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
Fri, Dec 27, 15:20
Size
1 KB
Mime Type
text/x-php
Expires
Sun, Dec 29, 15:20 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
23198477
Attached To
rPH Phabricator
ReleephController.php
View Options
<?php
abstract
class
ReleephController
extends
PhabricatorController
{
public
function
buildStandardPageResponse
(
$view
,
array
$data
)
{
$page
=
$this
->
buildStandardPageView
();
$page
->
setApplicationName
(
pht
(
'Releeph'
));
$page
->
setBaseURI
(
'/releeph/'
);
$page
->
setTitle
(
idx
(
$data
,
'title'
));
$page
->
setGlyph
(
"
\x
D3
\x
82"
);
$page
->
appendChild
(
$view
);
$response
=
new
AphrontWebpageResponse
();
return
$response
->
setContent
(
$page
->
render
());
}
public
function
buildSideNavView
(
$for_app
=
false
)
{
$user
=
$this
->
getRequest
()->
getUser
();
$nav
=
new
AphrontSideNavFilterView
();
$nav
->
setBaseURI
(
new
PhutilURI
(
$this
->
getApplicationURI
()));
if
(
$for_app
)
{
$nav
->
addFilter
(
'project/create/'
,
pht
(
'Create Product'
));
}
id
(
new
ReleephProductSearchEngine
())
->
setViewer
(
$user
)
->
addNavigationItems
(
$nav
->
getMenu
());
$nav
->
selectFilter
(
null
);
return
$nav
;
}
protected
function
buildApplicationMenu
()
{
return
$this
->
buildSideNavView
(
true
)->
getMenu
();
}
protected
function
getProductViewURI
(
ReleephProject
$product
)
{
return
$this
->
getApplicationURI
(
'project/'
.
$product
->
getID
().
'/'
);
}
protected
function
getBranchViewURI
(
ReleephBranch
$branch
)
{
return
$this
->
getApplicationURI
(
'branch/'
.
$branch
->
getID
().
'/'
);
}
}
Event Timeline
Log In to Comment