mirror of
https://we.phorge.it/source/phorge.git
synced 2025-02-07 20:38:32 +01:00
Summary: Ref T5833. This differentiates address spaces like the public internet from VPNs, so when a service is available at `192.168.0.1`, we'll know it's on some specific NAT block or whatever. Test Plan: See screenshots. Reviewers: btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T5833 Differential Revision: https://secure.phabricator.com/D10715
52 lines
1.2 KiB
PHP
52 lines
1.2 KiB
PHP
<?php
|
|
|
|
final class AlmanacConsoleController extends AlmanacController {
|
|
|
|
public function shouldAllowPublic() {
|
|
return true;
|
|
}
|
|
|
|
public function handleRequest(AphrontRequest $request) {
|
|
$viewer = $request->getViewer();
|
|
|
|
$menu = id(new PHUIObjectItemListView())
|
|
->setUser($viewer);
|
|
|
|
$menu->addItem(
|
|
id(new PHUIObjectItemView())
|
|
->setHeader(pht('Services'))
|
|
->setHref($this->getApplicationURI('service/'))
|
|
->addAttribute(
|
|
pht(
|
|
'Manage Almanac services.')));
|
|
|
|
$menu->addItem(
|
|
id(new PHUIObjectItemView())
|
|
->setHeader(pht('Devices'))
|
|
->setHref($this->getApplicationURI('device/'))
|
|
->addAttribute(
|
|
pht(
|
|
'Manage Almanac devices.')));
|
|
|
|
$menu->addItem(
|
|
id(new PHUIObjectItemView())
|
|
->setHeader(pht('Networks'))
|
|
->setHref($this->getApplicationURI('network/'))
|
|
->addAttribute(
|
|
pht(
|
|
'Manage Almanac networks.')));
|
|
|
|
$crumbs = $this->buildApplicationCrumbs();
|
|
$crumbs->addTextCrumb(pht('Console'));
|
|
|
|
return $this->buildApplicationPage(
|
|
array(
|
|
$crumbs,
|
|
$menu,
|
|
),
|
|
array(
|
|
'title' => pht('Almanac Console'),
|
|
));
|
|
}
|
|
|
|
}
|