mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-09 16:32:39 +01:00
Hide "Packages" field in Diffusion Commits query form when application uninstalled
Summary: Fixes T15698 Test Plan: 1. Uninstall Packages via `/applications/view/PhabricatorPackagesApplication/` 2. Go to `/diffusion/commit/`, expand the Query form, and see that `Packages` is not shown anymore Reviewers: O1 Blessed Committers, 20after4 Reviewed By: O1 Blessed Committers, 20after4 Subscribers: tobiaswiese, valerio.bozzolan, Matthew, Cigaryno Maniphest Tasks: T15698 Differential Revision: https://we.phorge.it/D25506
This commit is contained in:
parent
428f9686c4
commit
d92ed9ce0c
1 changed files with 3 additions and 0 deletions
|
@ -70,6 +70,8 @@ final class PhabricatorCommitSearchEngine
|
|||
}
|
||||
|
||||
protected function buildCustomSearchFields() {
|
||||
$show_packages = PhabricatorApplication::isClassInstalled(
|
||||
'PhabricatorPackagesApplication');
|
||||
return array(
|
||||
id(new PhabricatorSearchDatasourceField())
|
||||
->setLabel(pht('Responsible Users'))
|
||||
|
@ -118,6 +120,7 @@ final class PhabricatorCommitSearchEngine
|
|||
->setConduitKey('packages')
|
||||
->setAliases(array('package', 'packages', 'packagePHID'))
|
||||
->setDatasource(new PhabricatorOwnersPackageDatasource())
|
||||
->setIsHidden(!$show_packages)
|
||||
->setDescription(
|
||||
pht('Find commits which affect given packages.')),
|
||||
id(new PhabricatorSearchThreeStateField())
|
||||
|
|
Loading…
Reference in a new issue