Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2893156
PhabricatorCalendarEventEndDateTransaction.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
1 KB
Referenced Files
None
Subscribers
None
PhabricatorCalendarEventEndDateTransaction.php
View Options
<?php
final
class
PhabricatorCalendarEventEndDateTransaction
extends
PhabricatorCalendarEventDateTransaction
{
const
TRANSACTIONTYPE
=
'calendar.enddate'
;
public
function
generateOldValue
(
$object
)
{
$editor
=
$this
->
getEditor
(
)
;
return
$object
->
newEndDateTimeForEdit
(
)
->
newAbsoluteDateTime
(
)
->
setIsAllDay
(
$editor
->
getOldIsAllDay
(
)
)
->
toDictionary
(
)
;
}
public
function
applyInternalEffects
(
$object
,
$value
)
{
$actor
=
$this
->
getActor
(
)
;
$editor
=
$this
->
getEditor
(
)
;
$datetime
=
PhutilCalendarAbsoluteDateTime
::
newFromDictionary
(
$value
)
;
$datetime
->
setIsAllDay
(
$editor
->
getNewIsAllDay
(
)
)
;
$object
->
setEndDateTime
(
$datetime
)
;
}
public
function
shouldHide
(
)
{
if
(
$this
->
isCreateTransaction
(
)
)
{
return
true
;
}
return
false
;
}
public
function
getTitle
(
)
{
return
pht
(
'%s changed the end date for this event from %s to %s.'
,
$this
->
renderAuthor
(
)
,
$this
->
renderOldDate
(
)
,
$this
->
renderNewDate
(
)
)
;
}
public
function
getTitleForFeed
(
)
{
return
pht
(
'%s changed the end date for %s from %s to %s.'
,
$this
->
renderAuthor
(
)
,
$this
->
renderObject
(
)
,
$this
->
renderOldDate
(
)
,
$this
->
renderNewDate
(
)
)
;
}
protected
function
getInvalidDateMessage
(
)
{
return
pht
(
'End date is invalid.'
)
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sun, Jan 19, 17:57 (1 w, 5 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1127195
Default Alt Text
PhabricatorCalendarEventEndDateTransaction.php (1 KB)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment