Correct a parameter order swap in "diffusion.historyquery" for Mercurial
[phabricator.git] / src / applications / diffusion / herald / DiffusionPreCommitRefChangeHeraldField.php
blob8de278e4497fe8c4753e64d0d408ede923a9679d
1 <?php
3 final class DiffusionPreCommitRefChangeHeraldField
4 extends DiffusionPreCommitRefHeraldField {
6 const FIELDCONST = 'diffusion.pre.ref.change';
8 public function getHeraldFieldName() {
9 return pht('Ref change type');
12 public function getHeraldFieldValue($object) {
13 return $object->getChangeFlags();
16 public function getHeraldFieldConditions() {
17 return array(
18 HeraldAdapter::CONDITION_HAS_BIT,
19 HeraldAdapter::CONDITION_NOT_BIT,
23 public function getHeraldFieldValueType($condition) {
24 return id(new HeraldSelectFieldValue())
25 ->setKey(self::FIELDCONST)
26 ->setOptions(
27 PhabricatorRepositoryPushLog::getHeraldChangeFlagConditionOptions())
28 ->setDefault(PhabricatorRepositoryPushLog::CHANGEFLAG_ADD);