diff --git a/src/applications/project/query/PhabricatorProjectQuery.php b/src/applications/project/query/PhabricatorProjectQuery.php index 9b051c00dd..293378355e 100644 --- a/src/applications/project/query/PhabricatorProjectQuery.php +++ b/src/applications/project/query/PhabricatorProjectQuery.php @@ -187,6 +187,11 @@ final class PhabricatorProjectQuery 'column' => 'milestoneNumber', 'type' => 'int', ), + 'status' => array( + 'table' => $this->getPrimaryTableAlias(), + 'column' => 'status', + 'type' => 'int', + ), ); } diff --git a/src/applications/project/typeahead/PhabricatorProjectDatasource.php b/src/applications/project/typeahead/PhabricatorProjectDatasource.php index d0abcad2ca..e5b24335cf 100644 --- a/src/applications/project/typeahead/PhabricatorProjectDatasource.php +++ b/src/applications/project/typeahead/PhabricatorProjectDatasource.php @@ -26,7 +26,8 @@ final class PhabricatorProjectDatasource $query = id(new PhabricatorProjectQuery()) ->needImages(true) - ->needSlugs(true); + ->needSlugs(true) + ->setOrderVector(array('-status', 'id')); if ($this->getPhase() == self::PHASE_PREFIX) { $prefix = $this->getPrefixQuery();