diff --git a/modules/monitoring/application/views/scripts/list/notifications.phtml b/modules/monitoring/application/views/scripts/list/notifications.phtml index 85255cded..02af3ff9a 100644 --- a/modules/monitoring/application/views/scripts/list/notifications.phtml +++ b/modules/monitoring/application/views/scripts/list/notifications.phtml @@ -2,8 +2,6 @@ use Icinga\Module\Monitoring\Object\Host; use Icinga\Module\Monitoring\Object\Service; -$notifications->peekAhead($this->compact); - if (! $this->compact): ?>
@@ -16,22 +14,32 @@ if (! $this->compact): ?>
- +hasResult()): ?> +

translate('No notifications found matching the filter.') ?>

+ + +
- peekAhead($this->compact) as $notification): if (isset($notification->service_description)) { $isService = true; + $stateLabel = Service::getStateText($notification->notification_state, true); $stateName = Service::getStateText($notification->notification_state); } else { $isService = false; + $stateLabel = Host::getStateText($notification->notification_state, true); $stateName = Host::getStateText($notification->notification_state); } ?> @@ -70,17 +78,17 @@ if (! $this->compact): ?>
- timeAgo($notification->notification_start_time, $this->compact) ?> +
+
+ timeAgo($notification->notification_start_time, $this->compact) ?> +
+
icon('service', $this->translate('Service')); ?> link()->service( @@ -45,24 +53,24 @@ if (! $this->compact): ?> icon('host', $this->translate('Host')); ?> link()->host($notification->host_name, $notification->host_display_name) ?> - contact): ?> - - notification_contact_name): ?> - translate('Sent to %s'), - $this->qlink( - $notification->notification_contact_name, - 'monitoring/show/contact', - array('contact_name' => $notification->notification_contact_name) - ) - ) ?> - - translate('This notification was not sent out to any contact.'); ?> - - +
+ notification_contact_name): ?> + translate('Sent to %s'), + $this->qlink( + $notification->notification_contact_name, + 'monitoring/show/contact', + array('contact_name' => $notification->notification_contact_name) + ) + ) ?> + + translate('Sent out to any contact') ?> + +
-

+

+

pluginOutput($this->ellipsis($notification->notification_output, 10000), true) ?>

-hasResult()): ?> - translate('No notifications found matching the filter'); ?> -hasMore()): ?> - qlink( - $this->translate('Show More'), - $this->url(isset($notificationsUrl) ? $notificationsUrl : null)->without(array('view', 'limit')), - null, - array( - 'data-base-target' => '_next', - 'class' => 'pull-right action-link' - ) - ); ?> +hasMore()): ?> +
+ qlink( + $this->translate('Show More'), + $this->url(isset($notificationsUrl) ? $notificationsUrl : null)->without(array('view', 'limit')), + null, + array( + 'class' => 'action-link', + 'data-base-target' => '_next' + ) + ); ?> +
diff --git a/modules/monitoring/public/css/tables.less b/modules/monitoring/public/css/tables.less index 26b3f8e9e..dffb76209 100644 --- a/modules/monitoring/public/css/tables.less +++ b/modules/monitoring/public/css/tables.less @@ -2,10 +2,50 @@ @border-left-width: 6px; +// Check source reachable information in the host and service detail views +.check-source-meta { + font-size: @font-size-small; +} + +// Column for counts, e.g. host group members .count-col { width: 4em; } +// Host name and IP addresses in the host and service detail view +.host-meta { + color: @text-color-light; + font-size: @font-size-small; +} + +// Link to unhandled services in the hosts overview +.host-services-incidents { + color: @color-critical; + font-family: @font-family-wide; + font-size: @font-size-small; +} + +// Notification recipient in the notifications overview +.notification-recipient { + color: @text-color-light; + float: right; + font-size: @font-size-small; +} + +// Plugin output in overviews +.overview-plugin-output { + color: @text-color-light; + font-family: @font-family-fixed; + font-size: @font-size-small; +} + +// Service description if in the service detail view +.service-meta { + color: @text-color-light; + font-size: @font-size-small; +} + +// State column for label and duration in overviews .state-col { &.state-ok, &.state-up { @@ -69,40 +109,24 @@ width: 8em; } -.host-meta, .service-meta { - color: @text-color-light; - font-size: @font-size-small; -} - -// Link to unhandled services in the hosts overview -.host-services-incidents { - color: @color-critical; - font-family: @font-family-wide; - font-size: @font-size-small; -} - -// Plugin output in overviews -.overview-plugin-output { - color: @text-color-light; - font-family: @font-family-fixed; - font-size: @font-size-small; -} - +// Wraps links, icons and meta in overviews .state-header { .clearfix(); } +// State icons, e.g. acknowledged in overviews .state-icons { float: right; } +// State label in overviews .state-label { font-family: @font-family-wide; font-size: @font-size-small; letter-spacing: 1px; } -.check-source-meta, +// State duration and state type information in overviews .state-meta { font-size: @font-size-small; }