@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add a "problem commits" prebuilt filter to Audits

Summary: Ref T4715. We show this number on the homepage, provide an easy way to query matching commits.

Test Plan: Clicked "problem commits", saw them.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T4715

Differential Revision: https://secure.phabricator.com/D8880

+12 -2
+10 -2
src/applications/audit/query/PhabricatorCommitSearchEngine.php
··· 107 107 $names = array(); 108 108 109 109 if ($this->requireViewer()->isLoggedIn()) { 110 - $names['need_attention'] = pht('Need Attention'); 110 + $names['need'] = pht('Need Attention'); 111 + $names['problem'] = pht('Problem Commits'); 111 112 } 113 + 112 114 $names['open'] = pht('Open Audits'); 113 115 114 116 $names['all'] = pht('All Commits'); ··· 129 131 'auditStatus', 130 132 DiffusionCommitQuery::AUDIT_STATUS_OPEN); 131 133 return $query; 132 - case 'need_attention': 134 + case 'need': 133 135 $query->setParameter('awaitingUserPHID', $viewer->getPHID()); 134 136 $query->setParameter( 135 137 'auditStatus', ··· 137 139 $query->setParameter( 138 140 'auditorPHIDs', 139 141 PhabricatorAuditCommentEditor::loadAuditPHIDsForUser($viewer)); 142 + return $query; 143 + case 'problem': 144 + $query->setParameter('commitAuthorPHIDs', array($viewer->getPHID())); 145 + $query->setParameter( 146 + 'auditStatus', 147 + DiffusionCommitQuery::AUDIT_STATUS_CONCERN); 140 148 return $query; 141 149 } 142 150
+2
src/applications/home/controller/PhabricatorHomeMainController.php
··· 418 418 ->withAuditorPHIDs($phids) 419 419 ->withAuditStatus(DiffusionCommitQuery::AUDIT_STATUS_OPEN) 420 420 ->withAuditAwaitingUser($user) 421 + ->needAuditRequests(true) 421 422 ->needCommitData(true) 422 423 ->setLimit(10); 423 424 ··· 458 459 ->withAuthorPHIDs($phids) 459 460 ->withAuditStatus(DiffusionCommitQuery::AUDIT_STATUS_CONCERN) 460 461 ->needCommitData(true) 462 + ->needAuditRequests(true) 461 463 ->setLimit(10); 462 464 463 465 $commits = $query->execute();