1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-22 23:02:42 +01:00

Include owners packages in the MailableFunction datasource

Summary:
Ref T13151. See PHI684. Currently, the `MailableFunction` datasource does not include Owners packages, but they are valid subscribers and the `Mailable` datasource includes them.

Include them in the `MailableFunction` datasource, too.

Test Plan: Searched for revisions with particular package subscribers, got expected results in the UI (tokenizer knew about packages) and response.

Reviewers: amckinley, jmeador

Reviewed By: jmeador

Maniphest Tasks: T13151

Differential Revision: https://secure.phabricator.com/D19476
This commit is contained in:
epriestley 2018-06-07 09:59:11 -07:00
parent 7729c51cc4
commit 2951e0c86b
2 changed files with 4 additions and 1 deletions

View file

@ -8,7 +8,8 @@ final class PhabricatorMetaMTAMailableFunctionDatasource
} }
public function getPlaceholderText() { public function getPlaceholderText() {
return pht('Type a username, project, mailing list, or function...'); return pht(
'Type a username, project, mailing list, package, or function...');
} }
public function getDatasourceApplicationClass() { public function getDatasourceApplicationClass() {
@ -21,6 +22,7 @@ final class PhabricatorMetaMTAMailableFunctionDatasource
new PhabricatorPeopleDatasource(), new PhabricatorPeopleDatasource(),
new PhabricatorProjectMembersDatasource(), new PhabricatorProjectMembersDatasource(),
new PhabricatorProjectDatasource(), new PhabricatorProjectDatasource(),
new PhabricatorOwnersPackageDatasource(),
); );
} }

View file

@ -10,6 +10,7 @@ final class PhabricatorSearchSubscribersField
protected function getValueFromRequest(AphrontRequest $request, $key) { protected function getValueFromRequest(AphrontRequest $request, $key) {
$allow_types = array( $allow_types = array(
PhabricatorProjectProjectPHIDType::TYPECONST, PhabricatorProjectProjectPHIDType::TYPECONST,
PhabricatorOwnersPackagePHIDType::TYPECONST,
); );
return $this->getUsersFromRequest($request, $key, $allow_types); return $this->getUsersFromRequest($request, $key, $allow_types);
} }