|
+ comment_type) {
+ case 'flapping':
+ $icon = 'flapping';
+ $tooltip = 'Comment was caused by a flapping host or service.';
+ break;
+ case 'comment':
+ $icon = 'user';
+ $tooltip = 'Comment was created by an user.';
+ break;
+ case 'downtime':
+ $icon = 'down';
+ $tooltip = 'Comment was caused by a downtime.';
+ case 'ack':
+ $icon = 'acknowledgement';
+ $tooltip = 'Comment was caused by an acknowledgement.';
+ }
+ ?>
+ = $this->icon($icon . '.png', $tooltip) ?> + = $this->timeSince($comment->comment_timestamp) ?> + |
+
+ = $this->icon('service.png', 'Service comment') ?> = $this->qlink(
+ $comment->service_name,
+ 'monitoring/show/service',
+ array(
+ 'host' => $comment->host_name,
+ 'service' => $comment->service_name,
+ )
+ ) ?> on= $this->icon('host.png', 'Host comment') ?> = $this->qlink(
+ $comment->service_name,
+ 'monitoring/show/host',
+ array(
+ 'host' => $comment->host_name
+ )
+ ) ?> by = $this->escape($comment->comment_author) ?> + = $this->escape($comment->comment_data) ?> + comment_is_persistent): ?>Comment is persistent + Expires: = + ($comment->comment_expiration_timestamp) ? + $this->timeUnless($comment->comment_expiration_timestamp) : + 'Never' + ?> + |
+ + $comment->comment_id, + 'host' => $comment->host_name ); + if ($objectType === 'service') { - $hrefParameters['host'] = $comment->host_name; + $data['service'] = $comment->service_name; } - $detailLink = $this->href( - 'monitoring/show/' . $objectType, - $hrefParameters + echo $cf->iconSubmitForm( + 'img/icons/remove.png', + 'Remove comment', + 'link-like', + 'removecomment', + $data ); - $hostLink = $this->href( - 'monitoring/show/host', - array( - 'host' => $comment->host_name - ) - ); - ?> - | |
| - = date('d.m. H:i', $comment->comment_timestamp); ?> +?> | - -- comment_objecttype_id === '1'): ?> - = $this->icon('host.png', 'Host comment') ?> - comment_objecttype_id === '2'): ?> - = $this->icon('service.png', 'Service comment') ?> - - - comment_type) { - case 'flapping': - $icon = 'flapping'; - $tooltip = 'Comment was caused by a flapping host or service.'; - break; - case 'comment': - $icon = 'user'; - $tooltip = 'Comment was created by an user.'; - break; - case 'downtime': - $icon = 'down'; - $tooltip = 'Comment was caused by a downtime.'; - case 'ack': - $icon = 'acknowledgement'; - $tooltip = 'Comment was caused by an acknowledgement.'; - } - ?> - = $this->icon($icon . '.png', $tooltip) ?> - - | - -
-
-
-
-
-
- service_name): ?>
-
- = $comment->service_name ?>
- on
- = $comment->host_name; ?>
-
-
-
- = $comment->host_name; ?>
-
-
-
- by
- = $comment->comment_author; ?>
-
- = $comment->comment_data; ?>
-
-
-
-
- Persists: = ($comment->comment_is_persistent === '1') ? 'Yes' : 'No'; ?>
-
-
- Expires: =
- ($comment->comment_expiration_timestamp) ?
- 'at ' . date('d.m H:i', $comment->comment_expiration_timestamp) :
- 'Never';
- ?>
-
-
-
- |
- - $comment->comment_id, - 'host' => $comment->host_name - ); - - if ($objectType === 'service') { - $data['service'] = $comment->service_name; - } - - echo $commandHelper->iconSubmitForm( - 'img/icons/remove.png', - 'Remove comment', - 'btn-small', - 'removecomment', - $data - ); - ?> - | -