mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-23 22:10:55 +01:00
Unprototype the Ferret UI fields
Summary: Ref T12819. Show the new Ferret engine fields (and enable the indexer) unconditionally. Also pull them to the top since they're fairly general-purpose and appear more broadly now, and also they actually work correctly (WOW). Some redundant fields (like "Name Contains" in Repositories and Owners) could probably be removed now, I may clean those up in a followup. Test Plan: Browsed around, saw Ferret fields in UI without "(Prototype)" suffix. Reviewers: chad Reviewed By: chad Maniphest Tasks: T12819 Differential Revision: https://secure.phabricator.com/D18587
This commit is contained in:
parent
495ab7363b
commit
6edf98eb3b
2 changed files with 5 additions and 2 deletions
|
@ -324,6 +324,9 @@ abstract class PhabricatorApplicationSearchEngine extends Phobject {
|
|||
|
||||
$result = $head + $body + $tail;
|
||||
|
||||
// Force the fulltext "query" field to the top unconditionally.
|
||||
$result = array_select_keys($result, array('query')) + $result;
|
||||
|
||||
foreach ($this->getHiddenFields() as $hidden_key) {
|
||||
unset($result[$hidden_key]);
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@ final class PhabricatorFerretSearchEngineExtension
|
|||
const EXTENSIONKEY = 'ferret';
|
||||
|
||||
public function isExtensionEnabled() {
|
||||
return PhabricatorEnv::getEnvConfig('phabricator.show-prototypes');
|
||||
return true;
|
||||
}
|
||||
|
||||
public function getExtensionName() {
|
||||
|
@ -56,7 +56,7 @@ final class PhabricatorFerretSearchEngineExtension
|
|||
|
||||
$fields[] = id(new PhabricatorSearchTextField())
|
||||
->setKey('query')
|
||||
->setLabel(pht('Query (Prototype)'))
|
||||
->setLabel(pht('Query'))
|
||||
->setDescription(pht('Fulltext search.'));
|
||||
|
||||
return $fields;
|
||||
|
|
Loading…
Reference in a new issue