Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F429438
PhabricatorNotificationIndividualController.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
917 B
Referenced Files
None
Subscribers
None
PhabricatorNotificationIndividualController.php
View Options
<?php
final
class
PhabricatorNotificationIndividualController
extends
PhabricatorNotificationController
{
public
function
processRequest
()
{
$request
=
$this
->
getRequest
();
$user
=
$request
->
getUser
();
$stories
=
id
(
new
PhabricatorNotificationQuery
())
->
setViewer
(
$user
)
->
setUserPHID
(
$user
->
getPHID
())
->
withKeys
(
array
(
$request
->
getStr
(
'key'
)))
->
execute
();
if
(!
$stories
)
{
return
id
(
new
AphrontAjaxResponse
())->
setContent
(
array
(
'pertinent'
=>
false
,
));
}
$builder
=
new
PhabricatorNotificationBuilder
(
$stories
);
$content
=
$builder
->
buildView
()->
render
();
$response
=
array
(
'pertinent'
=>
true
,
'primaryObjectPHID'
=>
head
(
$stories
)->
getPrimaryObjectPHID
(),
'content'
=>
hsprintf
(
'%s'
,
$content
),
);
return
id
(
new
AphrontAjaxResponse
())->
setContent
(
$response
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sat, May 3, 8:31 AM (2 d)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
59701
Default Alt Text
PhabricatorNotificationIndividualController.php (917 B)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment