Skip to content

Commit

Permalink
Don't display piecharts for empty host and service sets
Browse files Browse the repository at this point in the history
refs #8565
  • Loading branch information
majentsch committed Apr 9, 2015
1 parent f4c6939 commit 2efea21
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 24 deletions.
@@ -1,20 +1,14 @@
<?php
use Icinga\Module\Monitoring\Object\Host;
?>

<?php
$i = 0;
$hidden = array();
$hiddenRich = array();
?>

<div class="hbox-item">
<?= $this->translate('States:') ?>
&nbsp;<?= $hostStatesPieChart; ?>
</div>

<?php if (($hostCount = count($objects)) > 0): ?>

<div class="hbox-item">
<?= $this->translate('States:') ?>
&nbsp;<?= $hostStatesPieChart; ?>
</div>
<p>
<table class="state statesummary">

Expand Down
@@ -1,22 +1,17 @@
<?php
use Icinga\Module\Monitoring\Object\Service;
?>

<div class="hbox-item">
<?= $this->translate('Service states:') ?>
&nbsp;<?= $serviceStatesPieChart; ?>
</div>
<div class="hbox-item">
<?= $this->translate('Host states:') ?>
&nbsp;<?= $hostStatesPieChart; ?>
</div>

<?php
$i = 0;
$hidden = array();
$hiddenRich = array();
$i = 0;
?>
<?php if (($serviceCount = count($objects)) > 0): ?>
<div class="hbox-item">
<?= $this->translate('Service states:') ?>
&nbsp;<?= $serviceStatesPieChart; ?>
</div>
<div class="hbox-item">
<?= $this->translate('Host states:') ?>
&nbsp;<?= $hostStatesPieChart; ?>
</div>
<p>
<table class="state statesummary">
<tbody>
Expand Down

0 comments on commit 2efea21

Please sign in to comment.