1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-03 20:22:46 +01:00
phorge-phorge/src/applications/countdown/controller/PhabricatorCountdownController.php

35 lines
885 B
PHP
Raw Normal View History

<?php
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 PhabricatorMenuItemView())
->setName(pht('Create Countdown'))
->setHref($this->getApplicationURI('edit/'))
->setIcon('create'));
return $crumbs;
}
}