Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F101359636
PhabricatorCalendarEventStartDateTransaction.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
Sat, Feb 8, 18:34
Size
1 KB
Mime Type
text/x-php
Expires
Mon, Feb 10, 18:34 (2 d)
Engine
blob
Format
Raw Data
Handle
24144115
Attached To
rPH Phabricator
PhabricatorCalendarEventStartDateTransaction.php
View Options
<?php
final
class
PhabricatorCalendarEventStartDateTransaction
extends
PhabricatorCalendarEventDateTransaction
{
const
TRANSACTIONTYPE
=
'calendar.startdate'
;
public
function
generateOldValue
(
$object
)
{
// TODO: Upgrade this.
return
$object
->
getStartDateTimeEpoch
();
}
public
function
applyInternalEffects
(
$object
,
$value
)
{
$actor
=
$this
->
getActor
();
$datetime
=
PhutilCalendarAbsoluteDateTime
::
newFromEpoch
(
$value
,
$actor
->
getTimezoneIdentifier
());
$datetime
->
setIsAllDay
(
$object
->
getIsAllDay
());
$object
->
setStartDateTime
(
$datetime
);
}
public
function
getTitle
()
{
return
pht
(
'%s changed the start date for this event from %s to %s.'
,
$this
->
renderAuthor
(),
$this
->
renderOldDate
(),
$this
->
renderNewDate
());
}
public
function
getTitleForFeed
()
{
return
pht
(
'%s changed the start date for %s from %s to %s.'
,
$this
->
renderAuthor
(),
$this
->
renderObject
(),
$this
->
renderOldDate
(),
$this
->
renderNewDate
());
}
protected
function
getInvalidDateMessage
()
{
return
pht
(
'Start date is invalid.'
);
}
}
Event Timeline
Log In to Comment