Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F92652093
PonderQuestionStatus.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
Fri, Nov 22, 10:01
Size
716 B
Mime Type
text/x-php
Expires
Sun, Nov 24, 10:01 (1 d, 17 h)
Engine
blob
Format
Raw Data
Handle
22478494
Attached To
rPH Phabricator
PonderQuestionStatus.php
View Options
<?php
final
class
PonderQuestionStatus
extends
PonderConstants
{
const
STATUS_OPEN
=
0
;
const
STATUS_CLOSED
=
1
;
public
static
function
getQuestionStatusMap
()
{
return
array
(
self
::
STATUS_OPEN
=>
pht
(
'Open'
),
self
::
STATUS_CLOSED
=>
pht
(
'Closed'
),
);
}
public
static
function
getQuestionStatusFullName
(
$status
)
{
$map
=
array
(
self
::
STATUS_OPEN
=>
pht
(
'Open'
),
self
::
STATUS_CLOSED
=>
pht
(
'Closed by author'
),
);
return
idx
(
$map
,
$status
,
pht
(
'Unknown'
));
}
public
static
function
getQuestionStatusTagColor
(
$status
)
{
$map
=
array
(
self
::
STATUS_CLOSED
=>
PHUITagView
::
COLOR_BLACK
,
);
return
idx
(
$map
,
$status
);
}
}
Event Timeline
Log In to Comment