Differential D21415 Diff 51032 src/applications/owners/controller/PhabricatorOwnersDetailController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/owners/controller/PhabricatorOwnersDetailController.php
| Show First 20 Lines • Show All 76 Lines • ▼ Show 20 Lines | $attention_commits = id(new DiffusionCommitQuery()) | ||||
| ->setViewer($request->getUser()) | ->setViewer($request->getUser()) | ||||
| ->withPackagePHIDs(array($package->getPHID())) | ->withPackagePHIDs(array($package->getPHID())) | ||||
| ->withStatuses( | ->withStatuses( | ||||
| array( | array( | ||||
| $status_concern, | $status_concern, | ||||
| )) | )) | ||||
| ->needCommitData(true) | ->needCommitData(true) | ||||
| ->needAuditRequests(true) | ->needAuditRequests(true) | ||||
| ->needIdentities(true) | |||||
| ->setLimit(10) | ->setLimit(10) | ||||
| ->execute(); | ->execute(); | ||||
| $view = id(new PhabricatorAuditListView()) | $view = id(new DiffusionCommitGraphView()) | ||||
| ->setUser($viewer) | ->setViewer($viewer) | ||||
| ->setNoDataString(pht('This package has no open problem commits.')) | ->setCommits($attention_commits) | ||||
| ->setCommits($attention_commits); | ->newObjectItemListView(); | ||||
| $view->setNoDataString(pht('This package has no open problem commits.')); | |||||
| $commit_views[] = array( | $commit_views[] = array( | ||||
| 'view' => $view, | 'view' => $view, | ||||
| 'header' => pht('Needs Attention'), | 'header' => pht('Needs Attention'), | ||||
| 'icon' => 'fa-warning', | 'icon' => 'fa-warning', | ||||
| 'button' => id(new PHUIButtonView()) | 'button' => id(new PHUIButtonView()) | ||||
| ->setTag('a') | ->setTag('a') | ||||
| ->setHref($commit_uri->alter('status', $status_concern)) | ->setHref($commit_uri->alter('status', $status_concern)) | ||||
| ->setIcon('fa-list-ul') | ->setIcon('fa-list-ul') | ||||
| ->setText(pht('View All')), | ->setText(pht('View All')), | ||||
| ); | ); | ||||
| $all_commits = id(new DiffusionCommitQuery()) | $all_commits = id(new DiffusionCommitQuery()) | ||||
| ->setViewer($request->getUser()) | ->setViewer($request->getUser()) | ||||
| ->withPackagePHIDs(array($package->getPHID())) | ->withPackagePHIDs(array($package->getPHID())) | ||||
| ->needCommitData(true) | ->needCommitData(true) | ||||
| ->needAuditRequests(true) | ->needAuditRequests(true) | ||||
| ->needIdentities(true) | |||||
| ->setLimit(25) | ->setLimit(25) | ||||
| ->execute(); | ->execute(); | ||||
| $view = id(new PhabricatorAuditListView()) | $view = id(new DiffusionCommitGraphView()) | ||||
| ->setUser($viewer) | ->setViewer($viewer) | ||||
| ->setCommits($all_commits) | ->setCommits($all_commits) | ||||
| ->setNoDataString(pht('No commits in this package.')); | ->newObjectItemListView(); | ||||
| $view->setNoDataString(pht('No commits in this package.')); | |||||
| $commit_views[] = array( | $commit_views[] = array( | ||||
| 'view' => $view, | 'view' => $view, | ||||
| 'header' => pht('Recent Commits'), | 'header' => pht('Recent Commits'), | ||||
| 'icon' => 'fa-code', | 'icon' => 'fa-code', | ||||
| 'button' => id(new PHUIButtonView()) | 'button' => id(new PHUIButtonView()) | ||||
| ->setTag('a') | ->setTag('a') | ||||
| ->setHref($commit_uri) | ->setHref($commit_uri) | ||||
| ▲ Show 20 Lines • Show All 280 Lines • Show Last 20 Lines | |||||