diff --git a/src/applications/project/query/PhabricatorProjectQuery.php b/src/applications/project/query/PhabricatorProjectQuery.php --- a/src/applications/project/query/PhabricatorProjectQuery.php +++ b/src/applications/project/query/PhabricatorProjectQuery.php @@ -187,6 +187,11 @@ '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 --- a/src/applications/project/typeahead/PhabricatorProjectDatasource.php +++ b/src/applications/project/typeahead/PhabricatorProjectDatasource.php @@ -26,7 +26,8 @@ $query = id(new PhabricatorProjectQuery()) ->needImages(true) - ->needSlugs(true); + ->needSlugs(true) + ->setOrderVector(array('-status', 'id')); if ($this->getPhase() == self::PHASE_PREFIX) { $prefix = $this->getPrefixQuery();