Fix the layout errors
Pull all containers in the host and service view to the left site. Change the layout of the comments view to display the comments properly. fixes #4934
This commit is contained in:
parent
cc5fa0a7b4
commit
9e9142055f
|
@ -13,23 +13,13 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
<h1>Comments</h1>
|
||||
|
||||
<div data-icinga-component="app/mainDetailGrid" data-icinga-grid-selection-type="single">
|
||||
|
||||
<?= $this->sortControl->render($this); ?>
|
||||
|
||||
|
||||
<?= $this->paginationControl($comments, null, null, array('preserve' => $this->preserve)); ?>
|
||||
|
||||
<table class="table table-condensed">
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="2">Comment Id</th>
|
||||
<th>Type</th>
|
||||
<th>Host</th>
|
||||
<th>Service</th>
|
||||
<th>Entry Time</th>
|
||||
<th>Author</th>
|
||||
<th>Comment</th>
|
||||
<th>Persistent</th>
|
||||
<th colspan="2">Expires</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($comments as $comment): ?>
|
||||
<?php
|
||||
|
@ -55,55 +45,66 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
)
|
||||
);
|
||||
?>
|
||||
<tr <?= ($this->activeRowHref === $detailLink) ? 'class="active"' : ''; ?>>
|
||||
<tr>
|
||||
<td>
|
||||
<a class="hidden" href="<?= $detailLink; ?>"></a>
|
||||
<?php if ($comment->comment_objecttype_id === '1'): ?>
|
||||
{{{ICON_HOST}}}
|
||||
<i class="icinga-icon-host" rel="tooltip" title="Host comment" ></i>
|
||||
<?php elseif ($comment->comment_objecttype_id === '2'): ?>
|
||||
{{{ICON_SERVICE}}}
|
||||
<i class="icinga-icon-service" rel="tooltip" title="Service comment"></i>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
|
||||
<td>
|
||||
<?= $comment->comment_id; ?>
|
||||
<small>
|
||||
<?php
|
||||
switch ($comment->comment_type) {
|
||||
case 'flapping':
|
||||
$icon = 'icinga-icon-flapping';
|
||||
$tooltip = 'Comment is caused by a flapping host or service.';
|
||||
break;
|
||||
}
|
||||
?>
|
||||
<i class="<?= $icon ?>" rel="tooltip" title="<?= $tooltip ?>"> </i>
|
||||
</small>
|
||||
</td>
|
||||
|
||||
<div rel="tooltip" title="Comment #<?=$comment->comment_id ?>">
|
||||
<td>
|
||||
<?= $comment->comment_type; ?>
|
||||
</td>
|
||||
<td>
|
||||
<a href="<?= $hostLink ?>">
|
||||
<?= $comment->host_name; ?>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<?php if ($comment->service_name): ?>
|
||||
<a href="<?= $detailLink ?>">
|
||||
<?= $comment->service_name ?>
|
||||
<?php if ($comment->service_name): ?>
|
||||
<a href="<?= $detailLink ?>">
|
||||
<?= $comment->service_name ?>
|
||||
</a>
|
||||
on
|
||||
<?php else: ?>
|
||||
|
||||
<?php endif; ?>
|
||||
<a href="<?= $hostLink ?>">
|
||||
<?= $comment->host_name; ?>
|
||||
</a>
|
||||
<?php else: ?>
|
||||
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td>
|
||||
<?= $dateHelper->formatDateTime($comment->comment_timestamp); ?>
|
||||
<?= date('d.m. H:i', $comment->comment_timestamp); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?= $comment->comment_author; ?>
|
||||
</td>
|
||||
<td>
|
||||
<span data-icinga-component="app/ellipsisText">
|
||||
<?= $comment->comment_data; ?>
|
||||
</span>
|
||||
<div class="small-row">
|
||||
<?= $comment->comment_data; ?>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<?= ($comment->comment_is_persistent === '1') ? 'Yes' : 'No'; ?>
|
||||
</td>
|
||||
<td>
|
||||
<?=
|
||||
<small>
|
||||
expires <br /> <?=
|
||||
($comment->comment_expiration_timestamp) ?
|
||||
$dateHelper->formatDateTime($comment->comment_expiration_timestamp) :
|
||||
'at ' . date('d.m H:i', $comment->comment_expiration_timestamp) :
|
||||
'Never';
|
||||
?>
|
||||
?> </small>
|
||||
|
||||
</td>
|
||||
<td>
|
||||
<?php
|
||||
|
@ -125,6 +126,7 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
);
|
||||
?>
|
||||
</td>
|
||||
</div>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
|
|
|
@ -5,6 +5,7 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
<?= $this->tabs->render($this); ?>
|
||||
<h1>Hosts Status</h1>
|
||||
<div data-icinga-component="app/mainDetailGrid" data-icinga-grid-selection-type="multi">
|
||||
|
||||
<div class="container pull-left">
|
||||
<div class="row">
|
||||
<div class="col-md-5">
|
||||
|
@ -17,20 +18,19 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
<div class="row">
|
||||
<?= $this->paginationControl($hosts, null, null, array('preserve' => $this->preserve)); ?>
|
||||
</div>
|
||||
<div>
|
||||
<div class="row">
|
||||
Select
|
||||
<a href='<?=$this->href('monitoring/multi/host',array( 'host' => '*' ))?>'> All </a>
|
||||
<a href='#'> None </a>
|
||||
</div>
|
||||
</div>
|
||||
<table class="table table-condensed">
|
||||
|
||||
<table class="table table-condensed pull-left">
|
||||
<tbody>
|
||||
|
||||
<?php foreach($hosts as $host): ?>
|
||||
<?php $hostStateName = strtolower($this->util()->getHostStateName($host->host_state)); ?>
|
||||
<?php $hostLink = $this->href('monitoring/show/host', array('host' => $host->host_name)); ?>
|
||||
<tr <?= ($this->activeRowHref === $hostLink) ? 'class="active"' : ''; ?> >
|
||||
<tr>
|
||||
|
||||
<!-- Color column -->
|
||||
<td class="tacheader-status-<?= $hostStateName; ?>">
|
||||
|
@ -130,5 +130,8 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
<?= $this->paginationControl($hosts, null, null, array('preserve' => $this->preserve)); ?>
|
||||
|
||||
<div class="pull-left">
|
||||
<?= $this->paginationControl($hosts, null, null, array('preserve' => $this->preserve)); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -5,6 +5,7 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
<?= $this->tabs->render($this); ?>
|
||||
<h1>Services Status</h1>
|
||||
<div data-icinga-component="app/mainDetailGrid" data-icinga-grid-selection-type="multi">
|
||||
|
||||
<div class="container pull-left">
|
||||
<div class="row">
|
||||
<div class="col-md-5">
|
||||
|
@ -17,13 +18,14 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
<div class="row">
|
||||
<?= $this->paginationControl($services, null, null, array('preserve' => $this->preserve)); ?>
|
||||
</div>
|
||||
<div>
|
||||
<div class="row">
|
||||
Select
|
||||
<a href='<?=$this->href('monitoring/multi/service',array( 'host' => '*', 'service' => '*' ))?>'> All </a>
|
||||
<a href='#'> None </a>
|
||||
</div>
|
||||
</div>
|
||||
<table class="table table-condensed">
|
||||
|
||||
<table class="table table-condensed pull-left">
|
||||
<tbody>
|
||||
<?php foreach ($services as $service): ?>
|
||||
<?php
|
||||
|
@ -136,5 +138,9 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
<?= $this->paginationControl($this->services, null, null, array('preserve' => $this->preserve)); ?>
|
||||
|
||||
<div class="pull-left">
|
||||
<?= $this->paginationControl($this->services, null, null, array('preserve' => $this->preserve)); ?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue