mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-22 23:02:42 +01:00
Mark the "Reviewer" field for Commits as deprecated
Summary: Depends on D18931. Ref T13048. Ref T13041. This field means "the first accepting reviewer, where order is mostly arbitrary". Modern rules should almost certainly use "Accepting Reviewers" instead. Getting rid of this completely is a pain, but we can at least reduce confusion by marking it as not-the-new-hotness. Add a "Deprecated" group, move it there, and mark it for exile. Test Plan: Edited a commit rule, saw it in "Deprecated" group at the bottom of the list: {F5395001} Reviewers: amckinley Reviewed By: amckinley Maniphest Tasks: T13048, T13041 Differential Revision: https://secure.phabricator.com/D18932
This commit is contained in:
parent
5c762d8957
commit
a9f87857af
3 changed files with 22 additions and 1 deletions
|
@ -1362,6 +1362,7 @@ phutil_register_library_map(array(
|
|||
'HeraldController' => 'applications/herald/controller/HeraldController.php',
|
||||
'HeraldCoreStateReasons' => 'applications/herald/state/HeraldCoreStateReasons.php',
|
||||
'HeraldDAO' => 'applications/herald/storage/HeraldDAO.php',
|
||||
'HeraldDeprecatedFieldGroup' => 'applications/herald/field/HeraldDeprecatedFieldGroup.php',
|
||||
'HeraldDifferentialAdapter' => 'applications/differential/herald/HeraldDifferentialAdapter.php',
|
||||
'HeraldDifferentialDiffAdapter' => 'applications/differential/herald/HeraldDifferentialDiffAdapter.php',
|
||||
'HeraldDifferentialRevisionAdapter' => 'applications/differential/herald/HeraldDifferentialRevisionAdapter.php',
|
||||
|
@ -6561,6 +6562,7 @@ phutil_register_library_map(array(
|
|||
'HeraldController' => 'PhabricatorController',
|
||||
'HeraldCoreStateReasons' => 'HeraldStateReasons',
|
||||
'HeraldDAO' => 'PhabricatorLiskDAO',
|
||||
'HeraldDeprecatedFieldGroup' => 'HeraldFieldGroup',
|
||||
'HeraldDifferentialAdapter' => 'HeraldAdapter',
|
||||
'HeraldDifferentialDiffAdapter' => 'HeraldDifferentialAdapter',
|
||||
'HeraldDifferentialRevisionAdapter' => array(
|
||||
|
|
|
@ -6,7 +6,11 @@ final class DiffusionCommitReviewerHeraldField
|
|||
const FIELDCONST = 'diffusion.commit.reviewer';
|
||||
|
||||
public function getHeraldFieldName() {
|
||||
return pht('Reviewer');
|
||||
return pht('Reviewer (Deprecated)');
|
||||
}
|
||||
|
||||
public function getFieldGroupKey() {
|
||||
return HeraldDeprecatedFieldGroup::FIELDGROUPKEY;
|
||||
}
|
||||
|
||||
public function getHeraldFieldValue($object) {
|
||||
|
|
15
src/applications/herald/field/HeraldDeprecatedFieldGroup.php
Normal file
15
src/applications/herald/field/HeraldDeprecatedFieldGroup.php
Normal file
|
@ -0,0 +1,15 @@
|
|||
<?php
|
||||
|
||||
final class HeraldDeprecatedFieldGroup extends HeraldFieldGroup {
|
||||
|
||||
const FIELDGROUPKEY = 'deprecated';
|
||||
|
||||
public function getGroupLabel() {
|
||||
return pht('Deprecated');
|
||||
}
|
||||
|
||||
protected function getGroupOrder() {
|
||||
return 99999;
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in a new issue