Add proper titles to the servicegroups view

refs #8458
This commit is contained in:
Johannes Meyer 2015-02-23 17:25:02 +01:00
parent c4aa02c3f0
commit ebdf68550b

View File

@ -79,9 +79,12 @@
</td> </td>
<?php endif ?> <?php endif ?>
<td class="groupname"> <td class="groupname">
<a href="<?= $this->href('monitoring/list/services', array('servicegroup' => $s->servicegroup)); ?>"> <?= $this->qlink(
<?= $this->translate($s->servicegroup_alias) ?> $s->servicegroup_alias,
</a> 'monitoring/list/services',
array('servicegroup' => $s->servicegroup),
array('title' => sprintf($this->translate('List all services in the group "%s"'), $s->servicegroup_alias))
); ?>
</td> </td>
<td class="total"> <td class="total">
<?= $s->services_total; ?> <?= $s->services_total; ?>
@ -89,29 +92,32 @@
<td class="state"> <td class="state">
<?php if ($s->services_ok): ?> <?php if ($s->services_ok): ?>
<span class="state ok"> <span class="state ok">
<a href="<?= $this->href( <?= $this->qlink(
$s->services_ok,
'monitoring/list/services', 'monitoring/list/services',
array( array(
'service_state' => 0, 'service_state' => 0,
'servicegroup' => $s->servicegroup, 'servicegroup' => $s->servicegroup,
'sort' => 'service_severity' 'sort' => 'service_severity'
)
); ?>" title="<?php printf(
$this->translatePlural(
'List %s service with status ok in service group %s',
'List %s Services with status ok in service group %s',
$s->services_ok
), ),
$s->services_ok, array(
$s->servicegroup 'title' => sprintf(
); ?>"> $this->translatePlural(
<?= $s->services_ok; ?> 'List %s service that is currently in state OK in service group "%s"',
</a> 'List %s services which are currently in state OK in service group "%s"',
$s->services_ok
),
$s->services_ok,
$s->servicegroup_alias
)
)
); ?>
</span> </span>
<?php endif ?> <?php endif ?>
<?php if ($s->services_critical_unhandled): ?> <?php if ($s->services_critical_unhandled): ?>
<span class="state critical"> <span class="state critical">
<a href="<?= $this->href( <?= $this->qlink(
$s->services_critical_unhandled,
'monitoring/list/services', 'monitoring/list/services',
array( array(
'service_state' => 2, 'service_state' => 2,
@ -120,40 +126,43 @@
'host_problem' => 0, 'host_problem' => 0,
'servicegroup' => $s->servicegroup, 'servicegroup' => $s->servicegroup,
'sort' => 'service_severity' 'sort' => 'service_severity'
)
); ?>" title="<?php printf(
$this->translatePlural(
'List %s service with status critical unhandled in service group %s',
'List %s Services with status critical unhandled in service group %s',
$s->services_critical_unhandled
), ),
$s->services_critical_unhandled, array(
$s->servicegroup 'title' => sprintf(
); ?>"> $this->translatePlural(
<?= $s->services_critical_unhandled; ?> 'List %s service that is currently in state CRITICAL in service group "%s"',
</a> 'List %s services which are currently in state CRITICAL in service group "%s"',
$s->services_critical_unhandled
),
$s->services_critical_unhandled,
$s->servicegroup_alias
)
)
); ?>
<?php endif ?> <?php endif ?>
<?php if ($s->services_critical_handled): ?> <?php if ($s->services_critical_handled): ?>
<span class="state critical handled"> <span class="state critical handled">
<a href="<?= $this->href( <?= $this->qlink(
$s->services_critical_handled,
'monitoring/list/services', 'monitoring/list/services',
array( array(
'service_state' => 2, 'service_state' => 2,
'service_handled' => 1, 'service_handled' => 1,
'servicegroup' => $s->servicegroup, 'servicegroup' => $s->servicegroup,
'sort' => 'service_severity' 'sort' => 'service_severity'
)
); ?>" title="<?php printf(
$this->translatePlural(
'List %s service with status critical handled in service group %s',
'List %s services with status critical handled in service group %s',
$s->services_critical_handled
), ),
$s->services_critical_handled, array(
$s->servicegroup 'title' => sprintf(
); ?>"> $this->translatePlural(
<?= $s->services_critical_handled; ?> 'List %s service that is currently in state CRITICAL (Acknowledged) in service group "%s"',
</a> 'List %s services which are currently in state CRITICAL (Acknowledged) in service group "%s"',
$s->services_critical_handled
),
$s->services_critical_handled,
$s->servicegroup_alias
)
)
); ?>
</span> </span>
<?php endif ?> <?php endif ?>
<?php if ($s->services_critical_unhandled): ?> <?php if ($s->services_critical_unhandled): ?>
@ -161,7 +170,8 @@
<?php endif ?> <?php endif ?>
<?php if ($s->services_unknown_unhandled): ?> <?php if ($s->services_unknown_unhandled): ?>
<span class="state unknown"> <span class="state unknown">
<a href="<?= $this->href( <?= $this->qlink(
$s->services_unknown_unhandled,
'monitoring/list/services', 'monitoring/list/services',
array( array(
'service_state' => 3, 'service_state' => 3,
@ -170,40 +180,43 @@
'host_problem' => 0, 'host_problem' => 0,
'servicegroup' => $s->servicegroup, 'servicegroup' => $s->servicegroup,
'sort' => 'service_severity' 'sort' => 'service_severity'
)
); ?>" title="<?php printf(
$this->translatePlural(
'List %s service with status unknown unhandled in service group %s',
'List %s services with status unknown unhandled in service group %s',
$s->services_unknown_unhandled
), ),
$s->services_unknown_unhandled, array(
$s->servicegroup 'title' => sprintf(
); ?>"> $this->translatePlural(
<?= $s->services_unknown_unhandled; ?> 'List %s service that is currently in state UNKNOWN in service group "%s"',
</a> 'List %s services which are currently in state UNKNOWN in service group "%s"',
$s->services_unknown_unhandled
),
$s->services_unknown_unhandled,
$s->servicegroup_alias
)
)
); ?>
<?php endif ?> <?php endif ?>
<?php if ($s->services_unknown_handled): ?> <?php if ($s->services_unknown_handled): ?>
<span class="state unknown handled"> <span class="state unknown handled">
<a href="<?= $this->href( <?= $this->qlink(
$s->services_unknown_handled,
'monitoring/list/services', 'monitoring/list/services',
array( array(
'service_state' => 3, 'service_state' => 3,
'service_handled' => 1, 'service_handled' => 1,
'servicegroup' => $s->servicegroup, 'servicegroup' => $s->servicegroup,
'sort' => 'service_severity' 'sort' => 'service_severity'
)
); ?>" title="<?php printf(
$this->translatePlural(
'List %s service with status unknown handled in service group %s',
'List %s services with status unknown handled in service group %s',
$s->services_unknown_handled
), ),
$s->services_unknown_handled, array(
$s->servicegroup 'title' => sprintf(
); ?>"> $this->translatePlural(
<?= $s->services_unknown_handled; ?> 'List %s service that is currently in state UNKNOWN (Acknowledged) in service group "%s"',
</a> 'List %s services which are currently in state UNKNOWN (Acknowledged) in service group "%s"',
$s->services_unknown_handled
),
$s->services_unknown_handled,
$s->servicegroup_alias
)
)
); ?>
</span> </span>
<?php endif ?> <?php endif ?>
<?php if ($s->services_unknown_unhandled): ?> <?php if ($s->services_unknown_unhandled): ?>
@ -211,7 +224,8 @@
<?php endif ?> <?php endif ?>
<?php if ($s->services_warning_unhandled): ?> <?php if ($s->services_warning_unhandled): ?>
<span class="state warning"> <span class="state warning">
<a href="<?= $this->href( <?= $this->qlink(
$s->services_warning_unhandled,
'monitoring/list/services', 'monitoring/list/services',
array( array(
'service_state' => 1, 'service_state' => 1,
@ -220,40 +234,43 @@
'host_problem' => 0, 'host_problem' => 0,
'servicegroup' => $s->servicegroup, 'servicegroup' => $s->servicegroup,
'sort' => 'service_severity' 'sort' => 'service_severity'
)
); ?>" title="<?php printf(
$this->translatePlural(
'List %s service with status warning unhandled in service group %s',
'List %s services with status warning unhandled in service group %s',
$s->services_warning_unhandled
), ),
$s->services_warning_unhandled, array(
$s->servicegroup 'title' => sprintf(
); ?>"> $this->translatePlural(
<?= $s->services_warning_unhandled; ?> 'List %s service that is currently in state WARNING in service group "%s"',
</a> 'List %s services which are currently in state WARNING in service group "%s"',
$s->services_warning_unhandled
),
$s->services_warning_unhandled,
$s->servicegroup_alias
)
)
); ?>
<?php endif ?> <?php endif ?>
<?php if ($s->services_warning_handled): ?> <?php if ($s->services_warning_handled): ?>
<span class="state warning handled"> <span class="state warning handled">
<a href="<?= $this->href( <?= $this->qlink(
$s->services_warning_handled,
'monitoring/list/services', 'monitoring/list/services',
array( array(
'service_state' => 1, 'service_state' => 1,
'service_handled' => 1, 'service_handled' => 1,
'servicegroup' => $s->servicegroup, 'servicegroup' => $s->servicegroup,
'sort' => 'service_severity' 'sort' => 'service_severity'
)
); ?>" title="<?php printf(
$this->translatePlural(
'List %s service with status warning handled in service group %s',
'List %s services with status warning handled in service group %s',
$s->services_warning_handled
), ),
$s->services_warning_handled, array(
$s->servicegroup 'title' => sprintf(
); ?>"> $this->translatePlural(
<?= $s->services_warning_handled; ?> 'List %s service that is currently in state WARNING (Acknowledged) in service group "%s"',
</a> 'List %s services which are currently in state WARNING (Acknowledged) in service group "%s"',
$s->services_warning_handled
),
$s->services_warning_handled,
$s->servicegroup_alias
)
)
); ?>
</span> </span>
<?php endif ?> <?php endif ?>
<?php if ($s->services_warning_unhandled): ?> <?php if ($s->services_warning_unhandled): ?>
@ -261,24 +278,26 @@
<?php endif ?> <?php endif ?>
<?php if ($s->services_pending): ?> <?php if ($s->services_pending): ?>
<span class="state pending"> <span class="state pending">
<a href="<?= $this->href( <?= $this->qlink(
$s->services_pending,
'monitoring/list/services', 'monitoring/list/services',
array( array(
'service_state' => 99, 'service_state' => 99,
'servicegroup' => $s->servicegroup, 'servicegroup' => $s->servicegroup,
'sort' => 'service_severity' 'sort' => 'service_severity'
)
); ?>" title="<?php printf(
$this->translatePlural(
'List %s service with status pending in service group %s',
'List %s services with status pending in service group %s',
$s->services_pending
), ),
$s->services_pending, array(
$s->servicegroup 'title' => sprintf(
); ?>"> $this->translatePlural(
<?= $s->services_pending; ?> 'List %s service that is currenlty in state PENDING in service group "%s"',
</a> 'List %s services which are currently in state PENDING in service group "%s"',
$s->services_pending
),
$s->services_pending,
$s->servicegroup_alias
)
)
); ?>
</span> </span>
<?php endif ?> <?php endif ?>
</td> </td>