Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F5995329
EchoManualPresentationModel.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
EchoManualPresentationModel.php
View Options
<?php
namespace
MediaWiki\Extension\Notifications\Formatters
;
use
MediaWiki\Language\RawMessage
;
class
EchoManualPresentationModel
extends
EchoEventPresentationModel
{
/** @inheritDoc */
public
function
getIconType
()
{
return
'robot'
;
}
/** @inheritDoc */
public
function
getHeaderMessage
()
{
return
$this
->
msg
(
'notification-header-api-triggered'
)
->
plaintextParams
(
$this
->
event
->
getExtraParam
(
'header'
),
$this
->
event
->
getAgent
()->
getName
()
);
}
/** @inheritDoc */
public
function
getSubjectMessage
()
{
return
$this
->
getHeaderMessage
();
}
/** @inheritDoc */
public
function
getPrimaryLink
()
{
if
(
!
$this
->
event
->
getTitle
()
)
{
return
false
;
}
return
[
'url'
=>
$this
->
event
->
getTitle
()->
getLocalURL
(),
'label'
=>
$this
->
msg
(
'notification-link-api-triggered'
)->
text
(),
];
}
/** @inheritDoc */
public
function
getBodyMessage
()
{
$content
=
$this
->
event
->
getExtraParam
(
'content'
);
// Content here passed through plaintextParams for sanitization
return
$content
?
(
new
RawMessage
(
'$1'
)
)->
plaintextParams
(
$content
)
:
false
;
}
/** @inheritDoc */
public
function
getSecondaryLinks
()
{
$agentLink
=
$this
->
getAgentLink
();
$agentLink
[
'tooltip'
]
=
$this
->
msg
(
'notification-tooltip-api-triggered'
,
$this
->
event
->
getAgent
()->
getName
()
);
return
[
$agentLink
,
];
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Oct 4 2026, 03:45 (4 w, 6 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
e0/67/5aaca6ea8d10ec1e8639e6e162eb
Default Alt Text
EchoManualPresentationModel.php (1 KB)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment