Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F14013550
D15199.id36694.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D15199.id36694.diff
View Options
diff --git a/src/applications/people/controller/PhabricatorPeopleProfileViewController.php b/src/applications/people/controller/PhabricatorPeopleProfileViewController.php
--- a/src/applications/people/controller/PhabricatorPeopleProfileViewController.php
+++ b/src/applications/people/controller/PhabricatorPeopleProfileViewController.php
@@ -130,7 +130,10 @@
->setViewer($viewer)
->withMemberPHIDs(array($user->getPHID()))
->needImages(true)
- ->withStatus(PhabricatorProjectQuery::STATUS_OPEN)
+ ->withStatuses(
+ array(
+ PhabricatorProjectStatus::STATUS_ACTIVE,
+ ))
->execute();
$header = id(new PHUIHeaderView())
diff --git a/src/applications/policy/query/PhabricatorPolicyQuery.php b/src/applications/policy/query/PhabricatorPolicyQuery.php
--- a/src/applications/policy/query/PhabricatorPolicyQuery.php
+++ b/src/applications/policy/query/PhabricatorPolicyQuery.php
@@ -230,6 +230,10 @@
->setViewer($viewer)
->withMemberPHIDs(array($viewer->getPHID()))
->withIsMilestone(false)
+ ->withStatuses(
+ array(
+ PhabricatorProjectStatus::STATUS_ACTIVE,
+ ))
->setLimit($default_limit)
->execute();
$default_projects = mpull($default_projects, null, 'getPHID');
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
@@ -27,6 +27,7 @@
const STATUS_CLOSED = 'status-closed';
const STATUS_ACTIVE = 'status-active';
const STATUS_ARCHIVED = 'status-archived';
+ private $statuses;
private $needSlugs;
private $needMembers;
@@ -49,6 +50,11 @@
return $this;
}
+ public function withStatuses(array $statuses) {
+ $this->statuses = $statuses;
+ return $this;
+ }
+
public function withMemberPHIDs(array $member_phids) {
$this->memberPHIDs = $member_phids;
return $this;
@@ -387,6 +393,13 @@
$filter);
}
+ if ($this->statuses !== null) {
+ $where[] = qsprintf(
+ $conn,
+ 'status IN (%Ls)',
+ $this->statuses);
+ }
+
if ($this->ids !== null) {
$where[] = qsprintf(
$conn,
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Nov 3, 7:41 AM (2 w, 1 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6729442
Default Alt Text
D15199.id36694.diff (2 KB)
Attached To
Mode
D15199: Don't show archived projects by default in policy control
Attached
Detach File
Event Timeline
Log In to Comment