mirror of
https://github.com/Icinga/icingaweb2-module-graphite.git
synced 2026-05-28 04:34:57 -04:00
parent
e299d9c816
commit
6dac5e7dad
1 changed files with 0 additions and 33 deletions
|
|
@ -40,39 +40,6 @@ class ShowController extends Controller
|
|||
$this->params->shift('r');
|
||||
}
|
||||
|
||||
public function graphAction()
|
||||
{
|
||||
$template = $this->loadTemplate();
|
||||
$title = $template->getTitle();
|
||||
if (false === strpos($title, '$')) {
|
||||
$template->setTitle('$hostname');
|
||||
} else {
|
||||
if (false === strpos($title, '$hostname')) {
|
||||
$template->setTitle('$hostname: ' . $template->getTitle());
|
||||
}
|
||||
}
|
||||
|
||||
$query = $this->graphiteWeb
|
||||
->select()
|
||||
->from(
|
||||
$template->getFilterString()
|
||||
);
|
||||
|
||||
foreach ($this->params->toArray() as $val) {
|
||||
$query->where($val[0], urldecode($val[1]));
|
||||
}
|
||||
|
||||
$img = $this->applyGraphParams(current($query->getImages($template)))
|
||||
->showLegend(false);
|
||||
|
||||
$this->_helper->layout()->disableLayout();
|
||||
|
||||
$image = $img->fetchImage();
|
||||
header('Content-Type: image/png');
|
||||
echo $image;
|
||||
exit;
|
||||
}
|
||||
|
||||
public function XXXserviceAction()
|
||||
{
|
||||
$this->handleDatasourceToggles();
|
||||
|
|
|
|||
Loading…
Reference in a new issue