diff --git a/modules/monitoring/application/views/scripts/list/components/hostssummary.phtml b/modules/monitoring/application/views/scripts/list/components/hostssummary.phtml index eaa8fe3635..7831f4fa04 100644 --- a/modules/monitoring/application/views/scripts/list/components/hostssummary.phtml +++ b/modules/monitoring/application/views/scripts/list/components/hostssummary.phtml @@ -8,16 +8,16 @@ if (! $stats instanceof stdClass) { } ?>
-qlink( - sprintf($this->translatePlural('%u Host', '%u Hosts', $stats->hosts_total), $stats->hosts_total), - // @TODO(el): Fix that - Url::fromPath('monitoring/list/hosts')->setParams(isset($baseFilter) ? $baseFilter->getUrlParams() : array()), - null, - array('title' => sprintf( - $this->translatePlural('List %u host', 'List all %u hosts', $stats->hosts_total), - $stats->hosts_total - )) -) ?>: + qlink( + sprintf($this->translatePlural('%u Host', '%u Hosts', $stats->hosts_total), $stats->hosts_total), + // @TODO(el): Fix that + Url::fromPath('monitoring/list/hosts')->setParams(isset($baseFilter) ? $baseFilter->getUrlParams() : array()), + null, + array('title' => sprintf( + $this->translatePlural('List %u host', 'List all %u hosts', $stats->hosts_total), + $stats->hosts_total + )) + ) ?>:
-qlink( - sprintf($this->translatePlural( - '%u Service', '%u Services', $stats->services_total), - $stats->services_total - ), - // @TODO(el): Fix that - Url::fromPath('monitoring/list/services')->setParams(isset($baseFilter) ? $baseFilter->getUrlParams() : array()), - null, - array('title' => sprintf( - $this->translatePlural('List %u service', 'List all %u services', $stats->services_total), - $stats->services_total - )) -) ?>: + qlink( + sprintf($this->translatePlural( + '%u Service', '%u Services', $stats->services_total), + $stats->services_total + ), + // @TODO(el): Fix that + Url::fromPath('monitoring/list/services')->setParams(isset($baseFilter) ? $baseFilter->getUrlParams() : array()), + null, + array('title' => sprintf( + $this->translatePlural('List %u service', 'List all %u services', $stats->services_total), + $stats->services_total + )) + ) ?>: $comment): - if ($i > 5) { + if ($i === 5) { break; } ?> diff --git a/modules/monitoring/application/views/scripts/partials/host/objects-header.phtml b/modules/monitoring/application/views/scripts/partials/host/objects-header.phtml index 720e2de40c..731ba1cf88 100644 --- a/modules/monitoring/application/views/scripts/partials/host/objects-header.phtml +++ b/modules/monitoring/application/views/scripts/partials/host/objects-header.phtml @@ -2,7 +2,7 @@ use Icinga\Module\Monitoring\Object\Host; if (! ($hostCount = count($objects))): return; endif ?> - +
$host): /** @var Host $host */ if ($i === 5) { diff --git a/modules/monitoring/application/views/scripts/partials/object/host-header.phtml b/modules/monitoring/application/views/scripts/partials/object/host-header.phtml index 517b590a6f..8bc7b6c641 100644 --- a/modules/monitoring/application/views/scripts/partials/object/host-header.phtml +++ b/modules/monitoring/application/views/scripts/partials/object/host-header.phtml @@ -2,7 +2,7 @@ use Icinga\Module\Monitoring\Object\Host; /** @var Host $object */ ?> -
+
host_state, true) ?>
diff --git a/modules/monitoring/application/views/scripts/partials/object/service-header.phtml b/modules/monitoring/application/views/scripts/partials/object/service-header.phtml index 7bd99b4694..93eb41f942 100644 --- a/modules/monitoring/application/views/scripts/partials/object/service-header.phtml +++ b/modules/monitoring/application/views/scripts/partials/object/service-header.phtml @@ -3,7 +3,7 @@ use Icinga\Module\Monitoring\Object\Host; use Icinga\Module\Monitoring\Object\Service; /** @var \Icinga\Module\Monitoring\Object\MonitoredObject $object */ ?> - +
host_state, true) ?>
diff --git a/modules/monitoring/application/views/scripts/partials/service/objects-header.phtml b/modules/monitoring/application/views/scripts/partials/service/objects-header.phtml index b4df2d1889..7512a30427 100644 --- a/modules/monitoring/application/views/scripts/partials/service/objects-header.phtml +++ b/modules/monitoring/application/views/scripts/partials/service/objects-header.phtml @@ -3,7 +3,7 @@ use Icinga\Module\Monitoring\Object\Host; use Icinga\Module\Monitoring\Object\Service; if (! ($serviceCount = count($objects))): return; endif ?> - +
$service): /** @var Service $service */ if ($i === 5) { diff --git a/modules/monitoring/public/css/module.less b/modules/monitoring/public/css/module.less index 9e4e75e8ea..5ad203768c 100644 --- a/modules/monitoring/public/css/module.less +++ b/modules/monitoring/public/css/module.less @@ -39,16 +39,27 @@ width: 1em; } +// Host and service summaries in detail and list views .hosts-summary, .services-summary { - .v-center(); - margin-top: @horizontal-padding; + margin-bottom: 0.5em; + + > .hosts-link, + > .services-link, + > .state-badges { + vertical-align: middle; + } +} + +// State table in the host and service multi-selection and detail views +.host-detail-state, +.service-detail-state { + margin-bottom: 0.5em; } .grid { .hosts-summary, .services-summary { - margin: 0; .pull-left(); } }