diff --git a/modules/monitoring/application/views/scripts/show/components/command.phtml b/modules/monitoring/application/views/scripts/show/components/command.phtml
index 6e76bbfc6..ec70c50a5 100644
--- a/modules/monitoring/application/views/scripts/show/components/command.phtml
+++ b/modules/monitoring/application/views/scripts/show/components/command.phtml
@@ -1,30 +1,16 @@
-
-
+
+$parts = explode('!', $object->check_command);
+$command = array_shift($parts);
+
+?>
+ = $this->translate('Command') ?> |
+ = $this->escape($command) ?>
+ |
+\n
%s | \n
%s | \n\n";
+for ($i = 0; $i < count($parts); $i++) {
+ printf($row, '$ARG' . ($i + 1) . '$', $this->escape($parts[$i]));
+}
-
-
-
- Command |
-
- object->check_command, 2);
- $command = array_shift($explodedCommand);
- echo $command;
- ?>
- |
-
-
- Arguments |
-
- = $this->commandArguments($this->object->check_command); ?>
- |
-
-
-
-
diff --git a/modules/monitoring/application/views/scripts/show/components/contacts.phtml b/modules/monitoring/application/views/scripts/show/components/contacts.phtml
index cbd1a8bb4..6ead26293 100644
--- a/modules/monitoring/application/views/scripts/show/components/contacts.phtml
+++ b/modules/monitoring/application/views/scripts/show/components/contacts.phtml
@@ -1,65 +1,39 @@
contacts as $contact) {
- $contacts[] = ''
- . $contact->contact_alias
- . '';
+
+if (! empty($object->contacts)) {
+
+ $list = array();
+ foreach ($object->contacts as $contact) {
+ $list[] = $this->qlink($contact->contact_alias, 'monitoring/show/contact', array(
+ 'contact_name' => $contact->contact_name
+ ));
+ }
+
+ printf(
+ "%s | %s %s |
\n",
+ $this->translate('Contacts'),
+ $this->img('img/icons/user_petrol.png'),
+ implode(', ', $list)
+ );
+
}
-?>
-
-
-
-
-
-
- No Contacts
-
- = implode(', ', $contacts); ?>
-
-
-
-
-contactgroups as $contactgroup) {
- $contactgroups[] = ''
- . $contactgroup->contactgroup_alias
- . '';
+ array('contactgroup_name' => $contactgroup->contactgroup_name)
+ );
+ }
+
+ printf(
+ "%s | %s %s |
\n",
+ $this->translate('Contactgroups'),
+ $this->img('img/icons/user_petrol.png'),
+ implode(', ', $list)
+ );
+
}
-?>
-
-
-
-
-
-
- No Contactgroups
-
- = implode(', ', $contactgroups); ?>
-
-
-
diff --git a/modules/monitoring/application/views/scripts/show/components/customvars.phtml b/modules/monitoring/application/views/scripts/show/components/customvars.phtml
index e3ba9563b..9eeb4a0ac 100644
--- a/modules/monitoring/application/views/scripts/show/components/customvars.phtml
+++ b/modules/monitoring/application/views/scripts/show/components/customvars.phtml
@@ -1,22 +1,16 @@
-
-
+
+if (! $object->customvars) { return; }
+
+foreach ($object->customvars as $name => $value) {
+ $name = ucwords(str_replace('_', ' ', strtolower($name)));
+ if (preg_match('~(?:pw|pass|community)~', strtolower($name))) {
+ $value = '***';
+ }
+ printf(
+ "
%s | %s |
---|
\n",
+ $this->escape($name),
+ $this->escape($value)
+ );
+}
-
- object->customvars)): ?>
- No customvars
-
-
- object->customvars as $varname => $varvalue): ?>
- - = $varname; ?>
- - = $varvalue; ?>
-
-
-
-
-
\ No newline at end of file
diff --git a/modules/monitoring/application/views/scripts/show/components/hostgroups.phtml b/modules/monitoring/application/views/scripts/show/components/hostgroups.phtml
index 8f7709ef0..f0cb76140 100644
--- a/modules/monitoring/application/views/scripts/show/components/hostgroups.phtml
+++ b/modules/monitoring/application/views/scripts/show/components/hostgroups.phtml
@@ -1,25 +1,17 @@
hostgroups)) return;
+
+$list = array();
foreach ($object->hostgroups as $name => $alias) {
- $hostgroups[] = ''
- . $alias
- . '';
+ $list[] = $this->qlink($alias, 'monitoring/list/services', array(
+ 'hostgroup' => $name
+ ));
}
-?>
-
-
+printf(
+ "
%s | %s %s |
---|
\n",
+ $this->translate('Hostgroups'),
+ $this->img('img/icons/hostgroup_petrol.png'),
+ implode(', ', $list)
+);
-
-
-
-
- No Hostgroups
-
- = implode(', ', $hostgroups); ?>
-
-
-
diff --git a/modules/monitoring/application/views/scripts/show/components/servicegroups.phtml b/modules/monitoring/application/views/scripts/show/components/servicegroups.phtml
index c4620e13f..1609eea13 100644
--- a/modules/monitoring/application/views/scripts/show/components/servicegroups.phtml
+++ b/modules/monitoring/application/views/scripts/show/components/servicegroups.phtml
@@ -1,25 +1,18 @@
servicegroups)) return;
+
+$list = array();
foreach ($object->servicegroups as $name => $alias) {
- $servicegroups[] = ''
- . $alias
- . '';
+ $list[] = $this->qlink($alias, 'monitoring/list/services', array(
+ 'servicegroup' => $name
+ ));
}
-?>
-
-
-
+printf(
+ "
%s | %s %s |
---|
\n",
+ $this->translate('Servicegroups'),
+ $this->img('img/icons/servicegroup_petrol.png'),
+ implode(', ', $list)
+);
-
-
- No Servicegroups
-
- = implode(', ', $servicegroups); ?>
-
-
-