Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F93213272
PhabricatorStandardCustomFieldText.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
Wed, Nov 27, 01:51
Size
1 KB
Mime Type
text/x-php
Expires
Fri, Nov 29, 01:51 (2 d)
Engine
blob
Format
Raw Data
Handle
22596859
Attached To
rPH Phabricator
PhabricatorStandardCustomFieldText.php
View Options
<?php
final
class
PhabricatorStandardCustomFieldText
extends
PhabricatorStandardCustomField
{
public
function
getFieldType
()
{
return
'text'
;
}
public
function
buildFieldIndexes
()
{
$indexes
=
array
();
$value
=
$this
->
getFieldValue
();
if
(
strlen
(
$value
))
{
$indexes
[]
=
$this
->
newStringIndex
(
$value
);
}
return
$indexes
;
}
public
function
readApplicationSearchValueFromRequest
(
PhabricatorApplicationSearchEngine
$engine
,
AphrontRequest
$request
)
{
return
$request
->
getStr
(
$this
->
getFieldKey
());
}
public
function
applyApplicationSearchConstraintToQuery
(
PhabricatorApplicationSearchEngine
$engine
,
PhabricatorCursorPagedPolicyAwareQuery
$query
,
$value
)
{
if
(
strlen
(
$value
))
{
$query
->
withApplicationSearchContainsConstraint
(
$this
->
newStringIndex
(
null
),
$value
);
}
}
public
function
appendToApplicationSearchForm
(
PhabricatorApplicationSearchEngine
$engine
,
AphrontFormView
$form
,
$value
,
array
$handles
)
{
$form
->
appendChild
(
id
(
new
AphrontFormTextControl
())
->
setLabel
(
$this
->
getFieldName
())
->
setName
(
$this
->
getFieldKey
())
->
setValue
(
$value
));
}
}
Event Timeline
Log In to Comment