monitoring: Don't render an empty table if there are no hosts to list
refs #5543
This commit is contained in:
parent
55cc3eae78
commit
d107d18a3d
|
@ -19,6 +19,10 @@ if (! $this->compact): ?>
|
||||||
</div>
|
</div>
|
||||||
<?php endif ?>
|
<?php endif ?>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
|
<?php if (! $hosts->hasResult()): ?>
|
||||||
|
<p><?= $this->translate('No hosts found matching the filter'.) ?></p>
|
||||||
|
</div>
|
||||||
|
<?php return; endif ?>
|
||||||
<table data-base-target="_next"
|
<table data-base-target="_next"
|
||||||
class="action-table multiselect"
|
class="action-table multiselect"
|
||||||
data-icinga-multiselect-url="<?= $this->href('monitoring/hosts/show') ?>"
|
data-icinga-multiselect-url="<?= $this->href('monitoring/hosts/show') ?>"
|
||||||
|
@ -94,9 +98,7 @@ if (! $this->compact): ?>
|
||||||
<?php endforeach ?>
|
<?php endforeach ?>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
<?php if (! $hosts->hasResult()): ?>
|
<?php if ($hosts->hasMore()): ?>
|
||||||
<?= $this->translate('No hosts found matching the filter') ?>
|
|
||||||
<?php elseif ($hosts->hasMore()): ?>
|
|
||||||
<div class="text-right">
|
<div class="text-right">
|
||||||
<?= $this->qlink(
|
<?= $this->qlink(
|
||||||
$this->translate('Show More'),
|
$this->translate('Show More'),
|
||||||
|
|
Loading…
Reference in New Issue