Move all ListFilter buttons into crumbs
Summary: Maniphest and Owners still have green ListFilter buttons, which have looked awkward for a while and are extra-awkward after D4447. Move them into crumbs and remove the ability of ListFilter to support buttons. The actual implementation can be simplified too now. Test Plan: Looked at Owners, Maniphest. Clicked create buttons. Looked at UIExample. Reviewers: chad Reviewed By: chad CC: aran Differential Revision: https://secure.phabricator.com/D4451
This commit is contained in:
@@ -281,15 +281,6 @@ final class ManiphestTaskListController extends ManiphestController {
|
||||
}
|
||||
|
||||
$filter = new AphrontListFilterView();
|
||||
$filter->addButton(
|
||||
phutil_render_tag(
|
||||
'a',
|
||||
array(
|
||||
'href' => (string)$create_uri,
|
||||
'class' => 'green button',
|
||||
),
|
||||
'Create New Task'));
|
||||
|
||||
if (empty($key)) {
|
||||
$filter->appendChild($form);
|
||||
}
|
||||
@@ -400,10 +391,24 @@ final class ManiphestTaskListController extends ManiphestController {
|
||||
$list_container->appendChild('</div>');
|
||||
$nav->appendChild($list_container);
|
||||
|
||||
$title = pht('Task List');
|
||||
|
||||
$crumbs = $this->buildApplicationCrumbs($nav)
|
||||
->addCrumb(
|
||||
id(new PhabricatorCrumbView())
|
||||
->setName($title))
|
||||
->addAction(
|
||||
id(new PhabricatorMenuItemView())
|
||||
->setHref($this->getApplicationURI('/task/create/'))
|
||||
->setName(pht('Create Task'))
|
||||
->setIcon('create'));
|
||||
|
||||
$nav->setCrumbs($crumbs);
|
||||
|
||||
return $this->buildStandardPageResponse(
|
||||
$nav,
|
||||
array(
|
||||
'title' => 'Task List',
|
||||
'title' => $title,
|
||||
));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user