mirror of
https://we.phorge.it/source/phorge.git
synced 2025-02-01 09:28:22 +01:00
f1bf27959f
Summary: This diff covers a bit of ground. - PHUIDocumentExample has been added - PHUIDocument has been extended with new features - PhabricatorMenuView is now PHUIListView - PhabricatorMenuItemView is now PHUIItemListView Overall - I think I've gotten all the edges covered here. There is some derpi-ness that we can talk about, comments in the code. Responsive design is missing from the new features on PHUIDocument, will follow up later. Test Plan: Tested mobile and desktop menus, old phriction layout, new document views, new lists, and object lists. Reviewers: epriestley, btrahan Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D6130
37 lines
906 B
PHP
37 lines
906 B
PHP
<?php
|
|
|
|
/**
|
|
* @group countdown
|
|
*/
|
|
abstract class PhabricatorCountdownController extends PhabricatorController {
|
|
|
|
public function buildSideNavView() {
|
|
$user = $this->getRequest()->getUser();
|
|
|
|
$nav = new AphrontSideNavFilterView();
|
|
$nav->setBaseURI(new PhutilURI($this->getApplicationURI()));
|
|
|
|
$nav->addFilter('', pht('All Countdowns'),
|
|
$this->getApplicationURI(''));
|
|
$nav->addFilter('', pht('Create Countdown'),
|
|
$this->getApplicationURI('edit/'));
|
|
|
|
return $nav;
|
|
}
|
|
|
|
public function buildApplicationMenu() {
|
|
return $this->buildSideNavView()->getMenu();
|
|
}
|
|
|
|
public function buildApplicationCrumbs() {
|
|
$crumbs = parent::buildApplicationCrumbs();
|
|
|
|
$crumbs->addAction(
|
|
id(new PHUIListItemView())
|
|
->setName(pht('Create Countdown'))
|
|
->setHref($this->getApplicationURI('edit/'))
|
|
->setIcon('create'));
|
|
|
|
return $crumbs;
|
|
}
|
|
}
|