Changeset View
Changeset View
Standalone View
Standalone View
src/applications/almanac/controller/AlmanacDeviceViewController.php
Show All 25 Lines | public function handleRequest(AphrontRequest $request) { | ||||
$curtain = $this->buildCurtain($device); | $curtain = $this->buildCurtain($device); | ||||
$header = id(new PHUIHeaderView()) | $header = id(new PHUIHeaderView()) | ||||
->setUser($viewer) | ->setUser($viewer) | ||||
->setHeader($device->getName()) | ->setHeader($device->getName()) | ||||
->setPolicyObject($device) | ->setPolicyObject($device) | ||||
->setHeaderIcon('fa-server'); | ->setHeaderIcon('fa-server'); | ||||
$status = $device->getStatusObject(); | |||||
if ($status->hasStatusTag()) { | |||||
$header->setStatus( | |||||
$status->getStatusTagIcon(), | |||||
$status->getStatusTagColor(), | |||||
$status->getName()); | |||||
} | |||||
$issue = null; | $issue = null; | ||||
if ($device->isClusterDevice()) { | if ($device->isClusterDevice()) { | ||||
$issue = $this->addClusterMessage( | $issue = $this->addClusterMessage( | ||||
pht('This device is bound to a cluster service.'), | pht('This device is bound to a cluster service.'), | ||||
pht( | pht( | ||||
'This device is bound to a cluster service. You do not have '. | 'This device is bound to a cluster service. You do not have '. | ||||
'permission to manage cluster services, so the device can not '. | 'permission to manage cluster services, so the device can not '. | ||||
'be edited.')); | 'be edited.')); | ||||
▲ Show 20 Lines • Show All 182 Lines • Show Last 20 Lines |