Differential D18588 Diff 44639 src/applications/repository/query/PhabricatorRepositorySearchEngine.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/repository/query/PhabricatorRepositorySearchEngine.php
Show All 18 Lines | return id(new PhabricatorRepositoryQuery()) | ||||
->needProfileImage(true); | ->needProfileImage(true); | ||||
} | } | ||||
protected function buildCustomSearchFields() { | protected function buildCustomSearchFields() { | ||||
return array( | return array( | ||||
id(new PhabricatorSearchStringListField()) | id(new PhabricatorSearchStringListField()) | ||||
->setLabel(pht('Callsigns')) | ->setLabel(pht('Callsigns')) | ||||
->setKey('callsigns'), | ->setKey('callsigns'), | ||||
id(new PhabricatorSearchTextField()) | |||||
->setLabel(pht('Name Contains')) | |||||
->setKey('name'), | |||||
id(new PhabricatorSearchSelectField()) | id(new PhabricatorSearchSelectField()) | ||||
->setLabel(pht('Status')) | ->setLabel(pht('Status')) | ||||
->setKey('status') | ->setKey('status') | ||||
->setOptions($this->getStatusOptions()), | ->setOptions($this->getStatusOptions()), | ||||
id(new PhabricatorSearchSelectField()) | id(new PhabricatorSearchSelectField()) | ||||
->setLabel(pht('Hosted')) | ->setLabel(pht('Hosted')) | ||||
->setKey('hosted') | ->setKey('hosted') | ||||
->setOptions($this->getHostedOptions()), | ->setOptions($this->getHostedOptions()), | ||||
Show All 29 Lines | if ($map['hosted']) { | ||||
$query->withHosted($hosted); | $query->withHosted($hosted); | ||||
} | } | ||||
} | } | ||||
if ($map['types']) { | if ($map['types']) { | ||||
$query->withTypes($map['types']); | $query->withTypes($map['types']); | ||||
} | } | ||||
if (strlen($map['name'])) { | |||||
$query->withNameContains($map['name']); | |||||
} | |||||
if ($map['uris']) { | if ($map['uris']) { | ||||
$query->withURIs($map['uris']); | $query->withURIs($map['uris']); | ||||
} | } | ||||
return $query; | return $query; | ||||
} | } | ||||
protected function getURI($path) { | protected function getURI($path) { | ||||
▲ Show 20 Lines • Show All 188 Lines • Show Last 20 Lines |