Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F93887662
PhabricatorCalendarEventCancelTransaction.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
Mon, Dec 2, 07:02
Size
1012 B
Mime Type
text/x-php
Expires
Wed, Dec 4, 07:02 (2 d)
Engine
blob
Format
Raw Data
Handle
22717673
Attached To
rPH Phabricator
PhabricatorCalendarEventCancelTransaction.php
View Options
<?php
final
class
PhabricatorCalendarEventCancelTransaction
extends
PhabricatorCalendarEventTransactionType
{
const
TRANSACTIONTYPE
=
'calendar.cancel'
;
public
function
generateOldValue
(
$object
)
{
return
(
int
)
$object
->
getIsCancelled
();
}
public
function
generateNewValue
(
$object
,
$value
)
{
return
(
int
)
$value
;
}
public
function
applyInternalEffects
(
$object
,
$value
)
{
$object
->
setIsCancelled
(
$value
);
}
public
function
getTitle
()
{
if
(
$this
->
getNewValue
())
{
return
pht
(
'%s cancelled this event.'
,
$this
->
renderAuthor
());
}
else
{
return
pht
(
'%s reinstated this event.'
,
$this
->
renderAuthor
());
}
}
public
function
getTitleForFeed
()
{
if
(
$this
->
getNewValue
())
{
return
pht
(
'%s cancelled %s.'
,
$this
->
renderAuthor
(),
$this
->
renderObject
());
}
else
{
return
pht
(
'%s reinstated %s.'
,
$this
->
renderAuthor
(),
$this
->
renderObject
());
}
}
}
Event Timeline
Log In to Comment