Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F100980597
PhabricatorProjectColumnTransaction.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
Tue, Feb 4, 12:16
Size
2 KB
Mime Type
text/x-php
Expires
Thu, Feb 6, 12:16 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
24069103
Attached To
rPH Phabricator
PhabricatorProjectColumnTransaction.php
View Options
<?php
final
class
PhabricatorProjectColumnTransaction
extends
PhabricatorApplicationTransaction
{
const
TYPE_NAME
=
'project:col:name'
;
const
TYPE_STATUS
=
'project:col:status'
;
const
TYPE_LIMIT
=
'project:col:limit'
;
public
function
getApplicationName
()
{
return
'project'
;
}
public
function
getApplicationTransactionType
()
{
return
PhabricatorProjectColumnPHIDType
::
TYPECONST
;
}
public
function
getTitle
()
{
$old
=
$this
->
getOldValue
();
$new
=
$this
->
getNewValue
();
$author_handle
=
$this
->
renderHandleLink
(
$this
->
getAuthorPHID
());
switch
(
$this
->
getTransactionType
())
{
case
PhabricatorProjectColumnTransaction
::
TYPE_NAME
:
if
(
$old
===
null
)
{
return
pht
(
'%s created this column.'
,
$author_handle
);
}
else
{
if
(!
strlen
(
$old
))
{
return
pht
(
'%s named this column "%s".'
,
$author_handle
,
$new
);
}
else
if
(
strlen
(
$new
))
{
return
pht
(
'%s renamed this column from "%s" to "%s".'
,
$author_handle
,
$old
,
$new
);
}
else
{
return
pht
(
'%s removed the custom name of this column.'
,
$author_handle
);
}
}
case
PhabricatorProjectColumnTransaction
::
TYPE_LIMIT
:
if
(!
$old
)
{
return
pht
(
'%s set the point limit for this column to %s.'
,
$author_handle
,
$new
);
}
else
if
(!
$new
)
{
return
pht
(
'%s removed the point limit for this column.'
,
$author_handle
);
}
else
{
return
pht
(
'%s changed point limit for this column from %s to %s.'
,
$author_handle
,
$old
,
$new
);
}
case
PhabricatorProjectColumnTransaction
::
TYPE_STATUS
:
switch
(
$new
)
{
case
PhabricatorProjectColumn
::
STATUS_ACTIVE
:
return
pht
(
'%s marked this column visible.'
,
$author_handle
);
case
PhabricatorProjectColumn
::
STATUS_HIDDEN
:
return
pht
(
'%s marked this column hidden.'
,
$author_handle
);
}
break
;
}
return
parent
::
getTitle
();
}
}
Event Timeline
Log In to Comment