Config option to ignore setup issues
Summary: T2381 Test Plan: Include existing setup issues in the ignore config option, reduces the number of setup issues in the status bar, moves ignored issues to the bottom of the list, and marks them as ignored. Also include a string corresponding to no setup issue, and verify that application does not break. Reviewers: epriestley Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D5072
This commit is contained in:
committed by
epriestley
parent
894cd13a41
commit
be7677f211
@@ -11,7 +11,8 @@ final class PhabricatorConfigIssueListController
|
||||
$nav->selectFilter('issue/');
|
||||
|
||||
$issues = PhabricatorSetupCheck::runAllChecks();
|
||||
PhabricatorSetupCheck::setOpenSetupIssueCount(count($issues));
|
||||
PhabricatorSetupCheck::setOpenSetupIssueCount(
|
||||
PhabricatorSetupCheck::countUnignoredIssues($issues));
|
||||
|
||||
$list = $this->buildIssueList($issues);
|
||||
$list->setNoDataString(pht("There are no open setup issues."));
|
||||
@@ -48,15 +49,25 @@ final class PhabricatorConfigIssueListController
|
||||
assert_instances_of($issues, 'PhabricatorSetupIssue');
|
||||
$list = new PhabricatorObjectItemListView();
|
||||
$list->setStackable();
|
||||
$ignored_items = array();
|
||||
|
||||
foreach ($issues as $issue) {
|
||||
$href = $this->getApplicationURI('/issue/'.$issue->getIssueKey().'/');
|
||||
$item = id(new PhabricatorObjectItemView())
|
||||
->setHeader($issue->getName())
|
||||
->setHref($href)
|
||||
->setBarColor('yellow')
|
||||
->addIcon('warning', pht('Setup Warning'))
|
||||
->addAttribute($issue->getSummary());
|
||||
$href = $this->getApplicationURI('/issue/'.$issue->getIssueKey().'/');
|
||||
$item = id(new PhabricatorObjectItemView())
|
||||
->setHeader($issue->getName())
|
||||
->setHref($href)
|
||||
->setBarColor('yellow')
|
||||
->addAttribute($issue->getSummary());
|
||||
if (!$issue->getIsIgnored()) {
|
||||
$item->addIcon('warning', pht('Setup Warning'));
|
||||
$list->addItem($item);
|
||||
} else {
|
||||
$item->addIcon('none', pht('Ignored'));
|
||||
$ignored_items[] = $item;
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($ignored_items as $item) {
|
||||
$list->addItem($item);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user