diff --git a/application/forms/Config/Authentication/ReorderForm.php b/application/forms/Config/Authentication/ReorderForm.php index 0b8a42626..f81ee5b0d 100644 --- a/application/forms/Config/Authentication/ReorderForm.php +++ b/application/forms/Config/Authentication/ReorderForm.php @@ -116,7 +116,7 @@ class ReorderForm extends Form 'escape' => false, 'value' => 'btn_' . $this->getBackendName() . '_reorder_up', 'name' => 'btn_' . $this->getBackendName() . '_reorder_up', - 'label' => $this->getView()->img('img/icons/up.png', array('title' => 'Move up in authentication order')), + 'label' => $this->getView()->icon('up.png', 'Move up in authentication order'), ) ); } @@ -138,7 +138,7 @@ class ReorderForm extends Form 'escape' => false, 'value' => 'btn_' . $this->getBackendName() . '_reorder_down', 'name' => 'btn_' . $this->getBackendName() . '_reorder_down', - 'label' => $this->getView()->img('img/icons/down.png', array('title' => 'Move down in authentication order')), + 'label' => $this->getView()->icon('down.png', 'Move down in authentication order'), ) ); diff --git a/application/forms/Config/GeneralForm.php b/application/forms/Config/GeneralForm.php index 179bd541a..ab3610ab8 100644 --- a/application/forms/Config/GeneralForm.php +++ b/application/forms/Config/GeneralForm.php @@ -397,7 +397,7 @@ class GeneralForm extends Form 'type' => 'submit', 'escape' => false, 'value' => '1', - 'label' => $this->getView()->img('img/icons/save.png', array('title' => 'Save Changes')) + 'label' => $this->getView()->icon('save.png', 'Save Changes') . ' Save changes', ) ); diff --git a/application/views/scripts/config/authentication.phtml b/application/views/scripts/config/authentication.phtml index e8bf9bd3b..a6f3688d3 100644 --- a/application/views/scripts/config/authentication.phtml +++ b/application/views/scripts/config/authentication.phtml @@ -14,9 +14,9 @@ $createDbBackend = $this->href('/config/createAuthenticationBackend', array('typ
- = $this->img('img/icons/create.png'); ?> Create A New LDAP Authentication Backend
+ = $this->icon('create.png'); ?> Create A New LDAP Authentication Backend
- = $this->img('img/icons/create.png'); ?> Create A New DB Authentication Backend
+ = $this->icon('create.png'); ?> Create A New DB Authentication Backend
| comment_objecttype_id === '1'): ?> - = $this->img('img/icons/host.png', array('title' => 'Host comment')) ?> + = $this->icon('host.png', 'Host comment') ?> comment_objecttype_id === '2'): ?> - = $this->img('img/icons/service.png', array('title' => 'Service comment')) ?> + = $this->icon('service.png', 'Service comment') ?> getHelper('MonitoringState'); $tooltip = 'Comment was caused by an acknowledgement.'; } ?> - = $this->img('img/icons/' . $icon . '.png', array('title' => $tooltip)) ?> + = $this->icon($icon . '.png', $tooltip) ?> | diff --git a/modules/monitoring/application/views/scripts/list/hosts.phtml b/modules/monitoring/application/views/scripts/list/hosts.phtml index 63c7ed254..e08a96fd8 100644 --- a/modules/monitoring/application/views/scripts/list/hosts.phtml +++ b/modules/monitoring/application/views/scripts/list/hosts.phtml @@ -32,52 +32,36 @@ if ($hosts->count() === 0) { $icons = array(); if (!$host->host_handled && $host->host_state > 0){ - $icons[] = $this->img('img/icons/unhandled.png', array( - 'title' => 'Unhandled' - )); + $icons[] = $this->icon('unhandled.png', 'Unhandled'); } if ($host->host_acknowledged && !$host->host_in_downtime) { - $icons[] = $this->img('img/icons/acknowledgement.png', array( - 'title' => 'Acknowledged' - )); + $icons[] = $this->icon('acknowledgement.png', 'Acknowledged'); } if ($host->host_is_flapping) { - $icons[] = $this->img('img/icons/flapping.png', array( - 'title' => 'Flapping' - )); + $icons[] = $this->icon('flapping.png', 'Flapping'); } if (!$host->host_notifications_enabled) { - $icons[] = $this->img('img/icons/notification_disabled.png', array( - 'title' => 'Notifications Disabled' - )); + $icons[] = $this->icon('notification_disabled.png', 'Notifications Disabled'); } if (!$host->host_in_downtime) { - $icons[] = $this->img('img/icons/in_downtime.png', array( - 'title' => 'In Downtime' - )); + $icons[] = $this->icon('in_downtime.png', 'In Downtime'); } if (!$host->host_active_checks_enabled) { if (!$host->host_passive_checks_enabled) { - $icons[] = $this->img('img/icons/active_passive_checks_disabled.png', array( - 'title' => 'Active And Passive Checks Disabled' - )); + $icons[] = $this->icon('active_passive_checks_disabled.png', 'Active And Passive Checks Disabled'); } else { - $icons[] = $this->img('img/icons/active_checks_disabled.png', array( - 'title' => 'Active Checks Disabled' - )); + $icons[] = $this->icon('active_checks_disabled.png', 'Active Checks Disabled'); } } // Not available right now: if (isset($host->host_last_comment) && $host->host_last_comment !== null) { - $icons[] = $this->img('img/icons/comment.png', array( - 'title' => 'Comments' - )); + $icons[] = $this->icon('comment.png', 'Comments'); } ?>||
| - - = $servicegroup->servicegroup; ?> - - | -- - | -- - | -
= $this->escape(substr(strip_tags($service->service_output), 0, 10000)); ?>
diff --git a/modules/monitoring/application/views/scripts/multi/components/comments.phtml b/modules/monitoring/application/views/scripts/multi/components/comments.phtml index 97e174076..9ac0d768b 100644 --- a/modules/monitoring/application/views/scripts/multi/components/comments.phtml +++ b/modules/monitoring/application/views/scripts/multi/components/comments.phtml @@ -8,7 +8,7 @@ $this->target ); ?>" class="btn-common btn-small button"> - = $this->img('img/icons/comment.png') ?> + = $this->icon('comment.png') ?> - = $this->img('img/icons/notification.png') ?>"> + = $this->icon('notification.png') ?>"> @@ -43,7 +43,7 @@ $this->target ); ?>" class="button btn-common btn-small input-sm pull-right"> - = $this->img('img/icons/remove.png') ?>"> + = $this->icon('remove.png') ?>"> There are 0 comments assigned to the selected items. diff --git a/modules/monitoring/application/views/scripts/multi/components/downtimes.phtml b/modules/monitoring/application/views/scripts/multi/components/downtimes.phtml index 08e7abfa3..ffbf73640 100644 --- a/modules/monitoring/application/views/scripts/multi/components/downtimes.phtml +++ b/modules/monitoring/application/views/scripts/multi/components/downtimes.phtml @@ -8,7 +8,7 @@ $this->target ); ?>" class="button btn-common btn-small input-sm pull-right"> - = $this->img('img/icons/in_downtime.png') ?> + = $this->icon('in_downtime.png') ?> @@ -30,7 +30,7 @@ $this->target ); ?>" class="button btn-common btn-small input-sm pull-right"> - = $this->img('img/icons/remove.png') ?> + = $this->icon('remove.png') ?> 0 Selected items are currently in downtime. diff --git a/modules/monitoring/application/views/scripts/show/components/comments.phtml b/modules/monitoring/application/views/scripts/show/components/comments.phtml index c142d7e5d..905a9b56d 100644 --- a/modules/monitoring/application/views/scripts/show/components/comments.phtml +++ b/modules/monitoring/application/views/scripts/show/components/comments.phtml @@ -1,5 +1,6 @@ getHelper('CommandForm'); $data = array('host' => $object->host_name); @@ -7,43 +8,59 @@ if ($object->service_description) { $data['service'] = $object->service_description; } -$list = array(); -foreach ($object->comments as $comment) { - - // Ticket hook sample - $text = $this->tickets ? preg_replace_callback( - $this->tickets->getPattern(), - array($this->tickets, 'createLink'), - $this->escape($comment->comment_data) - ) : $this->escape($comment->comment_data); - - $deleteData = $data; - $deleteData['commentid'] = $object->comment_internal_id; - - $iconForm = $cf->iconSubmitForm( - 'img/icons/remove.png', - 'Remove comment', - 'btn-small', - 'removecomment', - $deleteData - ); - - $list[] = sprintf( - "| No comments | +
|
+
+ comment_internal_id;
+
+ echo $cf->iconSubmitForm(
+ 'img/icons/remove.png',
+ 'Remove comment',
+ 'btn-small',
+ 'removecomment',
+ $deleteData
+ );
+ ?>
+
+ = $this->escape($comment->comment_author); ?>, = $comment->comment_type; ?>
+ (= $this->format()->timeSince($comment->comment_timestamp); ?>)
+
+ = $this->escape($comment->comment_data); ?>
+
+ |
+