From 9fc80ec34fb9a4d57ef4d390375e2a82f89d7d0d Mon Sep 17 00:00:00 2001 From: Matthias Jentsch Date: Fri, 6 Mar 2015 12:45:29 +0100 Subject: [PATCH] Use more readable coding style in service multi-view refs #8565 --- .../views/scripts/services/show.phtml | 218 +++++++++--------- 1 file changed, 109 insertions(+), 109 deletions(-) diff --git a/modules/monitoring/application/views/scripts/services/show.phtml b/modules/monitoring/application/views/scripts/services/show.phtml index 5cd3af1b6..d9aed1581 100644 --- a/modules/monitoring/application/views/scripts/services/show.phtml +++ b/modules/monitoring/application/views/scripts/services/show.phtml @@ -20,124 +20,130 @@ use Icinga\Web\Url; - translate('No services matching the filter'); ?> + translate('No services matching the filter'); ?> - + -

+

-
qlink( + +
+ qlink( $this->translate('Reschedule the next check'), $rescheduleAllLink, null, array('icon' => 'reschedule') - ); ?>
-
qlink( + ); ?> +
+ +
+ qlink( $this->translate('Schedule a downtime'), $downtimeAllLink, null, array('icon' => 'plug') - ); ?>
-
qlink( + ); ?> +
+ +
+ qlink( $this->translate('Submit a passive check result'), $processCheckResultAllLink, null, array('icon' => 'reply') - ); ?>
-
qlink( + ); ?> +
+ +
+ qlink( $this->translate('Add a comment'), $addCommentLink, null, array('icon' => 'comment') - ); ?>
-

- - 0): ?> -
-

- icon('attention-alt') ?> - translatePlural( - 'Unhandled Problem', - 'Unhandled Problems', - $unhandledCount - ) ?> -

- -

' . $unhandledCount . '') ?> - -

- qlink( - sprintf( - $this->translatePlural( - 'Schedule a downtime for %u unhandled service problem', - 'Schedule a downtime for %u unhandled service problems', - $unhandledCount - ), - $unhandledCount - ), - $downtimeUnhandledLink, - null, - array('icon' => 'plug') ); ?> -
- -
qlink( - sprintf( - $this->translatePlural( - 'Acknowledge %u unhandled service problem', - 'Acknowledge %u unhandled service problems', - $unhandledCount - ), - $unhandledCount - ), - $acknowledgeUnhandledLink, - null, - array('icon' => 'ok') - ); ?>
+

- -
- - - 0): ?> - -

icon('ok', $this->translate('Acknowledgements')) ?> translate('Acknowledgements') ?>

-

- translatePlural( - '%u Acknowledged Service Problem', - '%u Acknowledged Service Problems', - $acknowledgedCount - ), - $acknowledgedCount - ); ?> -

- - - - 0): ?> - -

icon('plug', $this->translate('Downtimes')) ?> translate('Downtimes') ?>

-

translatePlural( - '%u service currently in downtime', - '%u services currently in downtime', - $inDowntimeCount - ), $inDowntimeCount) ?> - + 0): ?>

- qlink( - $this->translate('List all'), - $inDowntimeLink, - null, - array('icon' => 'plug') - );?> +

+ icon('attention-alt') ?> + translatePlural( + 'Unhandled Problem', + 'Unhandled Problems', + $unhandledCount + ) ?> +

+ +

' . $unhandledCount . '') ?> + +

+ qlink( + sprintf( + $this->translatePlural( + 'Schedule a downtime for %u unhandled service problem', + 'Schedule a downtime for %u unhandled service problems', + $unhandledCount + ), + $unhandledCount + ), + $downtimeUnhandledLink, + null, + array('icon' => 'plug') + ); ?> +
+ +
qlink( + sprintf( + $this->translatePlural( + 'Acknowledge %u unhandled service problem', + 'Acknowledge %u unhandled service problems', + $unhandledCount + ), + $unhandledCount + ), + $acknowledgeUnhandledLink, + null, + array('icon' => 'ok') + ); ?>
+

+
-

+ + + 0): ?> +

icon('ok', $this->translate('Acknowledgements')) ?> translate('Acknowledgements') ?>

+

+ translatePlural( + '%u Acknowledged Service Problem.', + '%u Acknowledged Service Problems.', + $acknowledgedCount + ), + $acknowledgedCount + ); ?> +

+ + + + 0 /*&& $auth->hasPermission('monitoring/command/comment/delete')*/): ?> +

icon('plug', $this->translate('Downtimes')) ?> translate('Downtimes') ?>

+

translatePlural( + '%u service currently in downtime.', + '%u services currently in downtime.', + $inDowntimeCount + ), $inDowntimeCount) ?> + + qlink( + $this->translate('List all'), + $inDowntimeLink, + null + );?> +

@@ -146,12 +152,18 @@ use Icinga\Web\Url;

icon('comment') ?>

translatePlural( - 'There are no comments.', - 'There are %d comments', + 'There is %d comment.', + 'There are %d comments.', $commentCount ), $commentCount); ?> + qlink( + $this->translate('List all'), + $commentsLink, + null + ); ?>

+ fetchComments(); ?> @@ -180,20 +192,9 @@ use Icinga\Web\Url;
+ + - + -->