diff --git a/src/__phutil_library_map__.php b/src/__phutil_library_map__.php index 2f09ae2442..44d67c6259 100644 --- a/src/__phutil_library_map__.php +++ b/src/__phutil_library_map__.php @@ -590,6 +590,7 @@ phutil_register_library_map(array( 'DifferentialRevisionStatus' => 'applications/differential/constants/DifferentialRevisionStatus.php', 'DifferentialRevisionStatusDatasource' => 'applications/differential/typeahead/DifferentialRevisionStatusDatasource.php', 'DifferentialRevisionStatusFunctionDatasource' => 'applications/differential/typeahead/DifferentialRevisionStatusFunctionDatasource.php', + 'DifferentialRevisionStatusHeraldField' => 'applications/differential/herald/DifferentialRevisionStatusHeraldField.php', 'DifferentialRevisionStatusTransaction' => 'applications/differential/xaction/DifferentialRevisionStatusTransaction.php', 'DifferentialRevisionSummaryHeraldField' => 'applications/differential/herald/DifferentialRevisionSummaryHeraldField.php', 'DifferentialRevisionSummaryTransaction' => 'applications/differential/xaction/DifferentialRevisionSummaryTransaction.php', @@ -5701,6 +5702,7 @@ phutil_register_library_map(array( 'DifferentialRevisionStatus' => 'Phobject', 'DifferentialRevisionStatusDatasource' => 'PhabricatorTypeaheadDatasource', 'DifferentialRevisionStatusFunctionDatasource' => 'PhabricatorTypeaheadCompositeDatasource', + 'DifferentialRevisionStatusHeraldField' => 'DifferentialRevisionHeraldField', 'DifferentialRevisionStatusTransaction' => 'DifferentialRevisionTransactionType', 'DifferentialRevisionSummaryHeraldField' => 'DifferentialRevisionHeraldField', 'DifferentialRevisionSummaryTransaction' => 'DifferentialRevisionTransactionType', diff --git a/src/applications/differential/herald/DifferentialRevisionStatusHeraldField.php b/src/applications/differential/herald/DifferentialRevisionStatusHeraldField.php new file mode 100644 index 0000000000..1f343eeb90 --- /dev/null +++ b/src/applications/differential/herald/DifferentialRevisionStatusHeraldField.php @@ -0,0 +1,29 @@ +getStatus(); + } + + protected function getHeraldFieldStandardType() { + return self::STANDARD_PHID; + } + + protected function getDatasource() { + return new DifferentialRevisionStatusDatasource(); + } + + protected function getDatasourceValueMap() { + $map = DifferentialRevisionStatus::getAll(); + return mpull($map, 'getDisplayName', 'getKey'); + } + +}