mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-19 03:50:54 +01:00
8476ad1a28
Summary: Ref T11114. See that task for some discussion. Overall, Differential custom fields ended up with too many responsibilities. Later work in EditEngine provides a more promising model for achieving modularity with smaller, more consistent components. In particular, we have some custom fields like `DifferentialGitSVNIDField` and `DifferentialConflictsField` which serve //only// to support the field parser. This starts pulling commit message responsibilities out of the core list of custom fields and into simpler dedicated parsers. Test Plan: Created and edited revisions from the CLI. Added a bit of test coverage. Reviewers: chad Reviewed By: chad Maniphest Tasks: T11114 Differential Revision: https://secure.phabricator.com/D17058
30 lines
600 B
PHP
30 lines
600 B
PHP
<?php
|
|
|
|
final class DifferentialSubscribersCommitMessageField
|
|
extends DifferentialCommitMessageField {
|
|
|
|
const FIELDKEY = 'ccPHIDs';
|
|
|
|
public function getFieldName() {
|
|
return pht('Subscribers');
|
|
}
|
|
|
|
public function getFieldAliases() {
|
|
return array(
|
|
'CC',
|
|
'CCs',
|
|
'Subscriber',
|
|
);
|
|
}
|
|
|
|
public function parseFieldValue($value) {
|
|
return $this->parseObjectList(
|
|
$value,
|
|
array(
|
|
PhabricatorPeopleUserPHIDType::TYPECONST,
|
|
PhabricatorProjectProjectPHIDType::TYPECONST,
|
|
PhabricatorOwnersPackagePHIDType::TYPECONST,
|
|
));
|
|
}
|
|
|
|
}
|