mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-30 09:14:08 +02:00
Fix template code style, use Bootstrap 3, remove icons
- Icons have now the {{XY_ICON}} format - custom classes are removed - A few typos are fixed - Capitalization refs #4550 refs #4621 refs #4584
This commit is contained in:
parent
872fa2ac6c
commit
015a914aab
@ -1,99 +0,0 @@
|
|||||||
<?php
|
|
||||||
// {{{ICINGA_LICENSE_HEADER}}}
|
|
||||||
/**
|
|
||||||
* Icinga 2 Web - Head for multiple monitoring frontends
|
|
||||||
* Copyright (C) 2013 Icinga Development Team
|
|
||||||
*
|
|
||||||
* This program is free software; you can redistribute it and/or
|
|
||||||
* modify it under the terms of the GNU General Public License
|
|
||||||
* as published by the Free Software Foundation; either version 2
|
|
||||||
* of the License, or (at your option) any later version.
|
|
||||||
*
|
|
||||||
* This program is distributed in the hope that it will be useful,
|
|
||||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
* GNU General Public License for more details.
|
|
||||||
*
|
|
||||||
* You should have received a copy of the GNU General Public License
|
|
||||||
* along with this program; if not, write to the Free Software
|
|
||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
||||||
*
|
|
||||||
* @copyright 2013 Icinga Development Team <info@icinga.org>
|
|
||||||
* @author Icinga Development Team <info@icinga.org>
|
|
||||||
*/
|
|
||||||
// {{{ICINGA_LICENSE_HEADER}}}
|
|
||||||
|
|
||||||
namespace Icinga\Web\Form;
|
|
||||||
|
|
||||||
use Icinga\Web\Form;
|
|
||||||
use Icinga\Web\Session;
|
|
||||||
use Icinga\Web\Notification;
|
|
||||||
use \Icinga\Application\Config;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Class SettingsForm
|
|
||||||
* @package Icinga\Web\Form
|
|
||||||
*/
|
|
||||||
class SettingsForm extends Form
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
public function onSuccess()
|
|
||||||
{
|
|
||||||
$session = Session::getInstance();
|
|
||||||
$values = $this->getValues();
|
|
||||||
$session->language = $values['language'];
|
|
||||||
$session->backend = $values['backend'];
|
|
||||||
$session->show_benchmark = (bool)$values['show_benchmark'];
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function elements()
|
|
||||||
{
|
|
||||||
|
|
||||||
$all_backends = Config::getInstance()->listAll('backends');
|
|
||||||
$language = \Icinga\Web\Session::getInstance()->language;
|
|
||||||
if (!$language) {
|
|
||||||
$language = 'en_US';
|
|
||||||
}
|
|
||||||
return array(
|
|
||||||
'backend' => array(
|
|
||||||
'select',
|
|
||||||
array(
|
|
||||||
'label' => 'Backend',
|
|
||||||
'required' => true,
|
|
||||||
'value' => Session::getInstance()->backend,
|
|
||||||
'multiOptions' => array_combine($all_backends, $all_backends)
|
|
||||||
)
|
|
||||||
),
|
|
||||||
'language' => array(
|
|
||||||
'select',
|
|
||||||
array(
|
|
||||||
'label' => 'Language',
|
|
||||||
'required' => true,
|
|
||||||
'value' => $language,
|
|
||||||
'multiOptions' => array(
|
|
||||||
'de_DE' => 'Deutsch',
|
|
||||||
'en_US' => 'Englisch'
|
|
||||||
)
|
|
||||||
)
|
|
||||||
),
|
|
||||||
'show_benchmark' => array(
|
|
||||||
'checkbox',
|
|
||||||
array(
|
|
||||||
'label' => 'Show Benchmarks'
|
|
||||||
)
|
|
||||||
),
|
|
||||||
'submit' => array(
|
|
||||||
'submit',
|
|
||||||
array(
|
|
||||||
'label' => t('Apply')
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
@ -15,7 +15,7 @@
|
|||||||
<li class="dropdown">
|
<li class="dropdown">
|
||||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
|
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
|
||||||
<?= $this->escape($this->auth()->getUser()->getUsername()); ?>
|
<?= $this->escape($this->auth()->getUser()->getUsername()); ?>
|
||||||
<i>USER ICON</i>
|
<i>{{USER_ICON}}</i>
|
||||||
<b class="caret"></b>
|
<b class="caret"></b>
|
||||||
</a>
|
</a>
|
||||||
<ul class="dropdown-menu">
|
<ul class="dropdown-menu">
|
||||||
|
@ -18,7 +18,7 @@ $createDbBackend = Url::fromPath(
|
|||||||
if (!empty($errors)):
|
if (!empty($errors)):
|
||||||
?>
|
?>
|
||||||
<div class="alert alert-danger">
|
<div class="alert alert-danger">
|
||||||
<h4>There are errors in your configuration</h4>
|
<h4>{{ERROR_ICON}} There are errors in your configuration:</h4>
|
||||||
<br/>
|
<br/>
|
||||||
<ul>
|
<ul>
|
||||||
<?php foreach($errors as $error): ?>
|
<?php foreach($errors as $error): ?>
|
||||||
@ -29,7 +29,7 @@ $createDbBackend = Url::fromPath(
|
|||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<a href="<?= $createLdapBackend ?>">Create a new LDAP authentication backend</a><br/>
|
<a href="<?= $createLdapBackend ?>">{{CREATE_ICON}} Create A New LDAP Authentication Backend</a><br/>
|
||||||
<a href="<?= $createDbBackend ?>">Create a new DB authentication backend</a>
|
<a href="<?= $createDbBackend ?>">{{CREATE_ICON}} Create A New DB Authentication Backend</a>
|
||||||
</div>
|
</div>
|
||||||
<?= $this->form ?>
|
<?= $this->form ?>
|
@ -1,4 +1,4 @@
|
|||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs->render($this); ?>
|
||||||
|
|
||||||
<h4>Create new backend</h4>
|
<h4>{{CREATE_ICON}} Create New Backend</h4>
|
||||||
<?= $this->form ?>
|
<?= $this->form ?>
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
<?php if (!empty($errors)) : ?>
|
<?php if (!empty($errors)) : ?>
|
||||||
<div class="alert alert-danger">
|
<div class="alert alert-danger">
|
||||||
<h4>Errors occured when trying to save the project</h4>
|
<h4>Errors occured when trying to save the project.</h4>
|
||||||
<p>
|
<p>
|
||||||
The following errors occured when trying to save the configuration:
|
The following errors occured when trying to save the configuration:
|
||||||
</p>
|
</p>
|
||||||
|
@ -22,10 +22,10 @@ $modules = $this->modules->paginate();
|
|||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<? if ($module->enabled): ?>
|
<? if ($module->enabled): ?>
|
||||||
<i>ICON OK</i>
|
<i>{{OK_ICON}}</i>
|
||||||
<a href="<?= $disableUrl ?>"><?= $this->escape($module->name); ?></a>
|
<a href="<?= $disableUrl ?>"><?= $this->escape($module->name); ?></a>
|
||||||
<? else: ?>
|
<? else: ?>
|
||||||
<i>ICON REMOVE</i>
|
<i>{{REMOVE_ICON}}</i>
|
||||||
<a href="<?= $enableUrl ?>"><?= $this->escape($module->name); ?></a>
|
<a href="<?= $enableUrl ?>"><?= $this->escape($module->name); ?></a>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
(<?=
|
(<?=
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs->render($this); ?>
|
||||||
<br/>
|
<br/>
|
||||||
<div class="alert alert-error">
|
<div class="alert alert-error">
|
||||||
<h4><i>WARNING ICON</i>Saving <?= $this->escape($this->file); ?>.ini failed</h4>
|
<h4><i>WARNING ICON</i>Saving "<?= $this->escape($this->file); ?>.ini" Failed</h4>
|
||||||
<br/>
|
<br/>
|
||||||
<p>
|
<p>
|
||||||
Your <?= $this->escape($this->file); ?> configuration couldn't be stored (error: "<?= $this->exceptionMessage; ?>").<br/>
|
Your <?= $this->escape($this->file); ?> configuration couldn't be stored (error: "<?= $this->exceptionMessage; ?>").<br/>
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
<h3>Add dashboard URL</h3>
|
<h3>Add Dashboard URL</h3>
|
||||||
|
|
||||||
<?= $this->form->render($this); ?>
|
<?= $this->form->render($this); ?>
|
@ -1,6 +1,6 @@
|
|||||||
<br/>
|
<br/>
|
||||||
<div class="alert alert-error">
|
<div class="alert alert-error">
|
||||||
<h4><i>ICON WARNING</i>Saving dashboard failed</h4>
|
<h4><i>{{WARNING_ICON}}</i>Saving Dashboard Failed</h4>
|
||||||
<br/>
|
<br/>
|
||||||
<p>
|
<p>
|
||||||
Your dashboard couldn't be stored (error: "<?= $this->exceptionMessage; ?>"). This could have one or more
|
Your dashboard couldn't be stored (error: "<?= $this->exceptionMessage; ?>"). This could have one or more
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
|
use Icinga\Web\Url;
|
||||||
|
|
||||||
if ($this->pageCount <= 1) return;
|
if ($this->pageCount <= 1) return;
|
||||||
|
|
||||||
@ -24,9 +25,13 @@ $title_next = sprintf(
|
|||||||
<!-- Previous page link -->
|
<!-- Previous page link -->
|
||||||
|
|
||||||
<?php if (isset($this->previous)): ?>
|
<?php if (isset($this->previous)): ?>
|
||||||
<li><a href="<?= $this->url()->setParam('page', $this->previous) ?>" title="<?= $title_prev ?>">« <?= $this->translate('Back') ?></a></li>
|
<li>
|
||||||
|
<a href="<?= Url::fromRequest()->overwriteParams(array('page' => $this->previous))->getAbsoluteUrl() ?>"
|
||||||
|
title="<?= $title_prev ?>">« <?= $this->translate('Prev') ?>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
<li class="disabled"><span>« <?= $this->translate('Back') ?></span></li>
|
<li class="disabled"><span>« <?= $this->translate('Prev') ?></span></li>
|
||||||
<?php endif ?>
|
<?php endif ?>
|
||||||
|
|
||||||
<!-- Numbered page links -->
|
<!-- Numbered page links -->
|
||||||
@ -45,7 +50,7 @@ foreach ($this->pagesInRange as $page):
|
|||||||
<li class="disabled"><span>...</span></li>
|
<li class="disabled"><span>...</span></li>
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
<li <?= $class ?>>
|
<li <?= $class ?>>
|
||||||
<a href="<?= $this->url()->setParam('page', $page) ?>" title="<?= $title ?>">
|
<a href="<?= Url::fromRequest()->overwriteParams(array('page' => $page))->getAbsoluteUrl() ?>" title="<?= $title ?>">
|
||||||
<?= $page ?>
|
<?= $page ?>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
@ -55,7 +60,11 @@ endforeach;
|
|||||||
?>
|
?>
|
||||||
<!-- Next page link -->
|
<!-- Next page link -->
|
||||||
<? if (isset($this->next)): ?>
|
<? if (isset($this->next)): ?>
|
||||||
<li><a href="<?= $this->url()->setParam('page', $this->next) ?>" title="<?= $title_next ?>"><?= t('Next') ?> »</a></li>
|
<li>
|
||||||
|
<a href="<?= Url::fromRequest()->overwriteParams(array('page' => $this->next))->getAbsoluteUrl() ?>"
|
||||||
|
title="<?= $title_next ?>"><?= t('Next') ?> »
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<? else: ?>
|
<? else: ?>
|
||||||
<li class="disabled"><span><?= t('Next') ?> »</span></li>
|
<li class="disabled"><span><?= t('Next') ?> »</span></li>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
<?php if (isset($this->success)) : ?>
|
<?php if (isset($this->success)) : ?>
|
||||||
<div class="alert alert-success">
|
<div class="alert alert-success">
|
||||||
<h4>Preferences updated successfully</h4>
|
<h4>Preferences Updated Successfully</h4>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
|
@ -1,18 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Icinga\Web\View;
|
|
||||||
|
|
||||||
use Icinga\Web\Url;
|
|
||||||
|
|
||||||
function url($path = null, $params = null)
|
|
||||||
{
|
|
||||||
if ($path === null) {
|
|
||||||
$url = Url::fromRequest();
|
|
||||||
if ($params !== null) {
|
|
||||||
$url->setParams($params);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
$url = Url::fromPath($path, $params);
|
|
||||||
}
|
|
||||||
return $url;
|
|
||||||
}
|
|
@ -1,10 +1,10 @@
|
|||||||
<h4><?= t('List of supported commands'); ?></h4>
|
<h4><?= t('List Of Supported Commands'); ?></h4>
|
||||||
<ul>
|
<ul>
|
||||||
<?php foreach($this->commands as $command): ?>
|
<?php foreach($this->commands as $command): ?>
|
||||||
<li>
|
<li>
|
||||||
<a href="<?= $this->href('monitoring/command/'. $command); ?>">
|
<a href="<?= $this->href('monitoring/command/'. $command); ?>">
|
||||||
<?= $this->escape($command); ?>
|
<?= $this->escape($command); ?>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<?php endforeach; ?>
|
<?php endforeach; ?>
|
||||||
</ul>
|
</ul>
|
@ -1,11 +1,11 @@
|
|||||||
|
|
||||||
<?php if (isset($this->objects) && !empty($this->objects) && isset($this->objects[0]->host_name)): ?>
|
<?php if (isset($this->objects) && !empty($this->objects) && isset($this->objects[0]->host_name)): ?>
|
||||||
<table class="table table-bordered table-striped table-condensed">
|
<table class="table table-bordered table-striped table-condensed">
|
||||||
<legend>Affected objects</legend>
|
<legend>Affected Objects</legend>
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Host name</th>
|
<th>{{HOST_ICON}} Host Name</th>
|
||||||
<th>Service name</th>
|
<th>{{SERVICE_ICON}} Service Name</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs->render($this); ?>
|
||||||
<?php if ($this->name): ?>
|
<?php if ($this->name): ?>
|
||||||
<h4>Edit Backend "<?= $this->escape($this->name) ?>"</h4>
|
<h4><i>{{EDIT_ICON}} Edit Backend "<?= $this->escape($this->name) ?>"</h4>
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
<h4>Create New Backend</h4>
|
<h4>{{CREATE_ICON}} Create New Backend</h4>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($this->error): ?>
|
<?php if ($this->error): ?>
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs->render($this); ?>
|
||||||
|
|
||||||
<?php if (isset($this->name)): ?>
|
<?php if (isset($this->name)): ?>
|
||||||
<h4>Edit Instance Configuration for "<?= $this->escape($this->name) ?>"</h4>
|
<h4>{{EDIT_ICON}} Edit Instance Configuration for "<?= $this->escape($this->name) ?>"</h4>
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
<h4>Configure New Icinga Instance</h4>
|
<h4>{{CREATE_ICON}} Configure New Icinga Instance</h4>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($this->error): ?>
|
<?php if ($this->error): ?>
|
||||||
|
@ -1,11 +1,11 @@
|
|||||||
<?php use Icinga\Web\Url; ?>
|
<?php use Icinga\Web\Url; ?>
|
||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs->render($this); ?>
|
||||||
|
|
||||||
<h3>Backends</h3>
|
<h3>Monitoring Backends</h3>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<a href="<?= Url::fromPath('/monitoring/config/createbackend')->getAbsoluteUrl();?>">
|
<a href="<?= Url::fromPath('/monitoring/config/createbackend')->getAbsoluteUrl();?>">
|
||||||
Create New Backend
|
{{CREATE_ICON}} Create New Monitoring Backend
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<br/>
|
<br/>
|
||||||
@ -17,11 +17,11 @@
|
|||||||
<b><?= $this->escape($backendName); ?></b>
|
<b><?= $this->escape($backendName); ?></b>
|
||||||
<small>(Type: <?= $this->escape($config['type'] === 'ido' ? 'IDO' : ucfirst($config['type'])); ?>)</small>
|
<small>(Type: <?= $this->escape($config['type'] === 'ido' ? 'IDO' : ucfirst($config['type'])); ?>)</small>
|
||||||
<?php if ($config['disabled']): ?>
|
<?php if ($config['disabled']): ?>
|
||||||
- <b>Disabled</b>
|
- <b>{{DISABLED_ICON}} Disabled</b>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<div>
|
<div>
|
||||||
<a href="<?= $removeUrl; ?>">Remove This Backend</a><br/>
|
<a href="<?= $removeUrl; ?>">{{REMOVE_ICON}} Remove This Backend</a><br/>
|
||||||
<a href="<?= $editUrl; ?>">Edit This Backend</a>
|
<a href="<?= $editUrl; ?>">{{EDIT_ICON}} Edit This Backend</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<br/>
|
<br/>
|
||||||
@ -33,7 +33,7 @@
|
|||||||
|
|
||||||
<div>
|
<div>
|
||||||
<a href="<?= Url::fromPath('/monitoring/config/createinstance')->getAbsoluteUrl();?>">
|
<a href="<?= Url::fromPath('/monitoring/config/createinstance')->getAbsoluteUrl();?>">
|
||||||
Create New Instance
|
{{CREATE_ICON}} Create New Instance
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -46,8 +46,8 @@
|
|||||||
<small>(Type: <?= isset($config['host']) ? 'Remote' : 'Local'; ?>)</small>
|
<small>(Type: <?= isset($config['host']) ? 'Remote' : 'Local'; ?>)</small>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<a href="<?= $removeUrl; ?>">Remove This Instance</a><br/>
|
<a href="<?= $removeUrl; ?>">{{REMOVE_ICON}} Remove This Instance</a><br/>
|
||||||
<a href="<?= $editUrl; ?>">Edit This Instance</a>
|
<a href="<?= $editUrl; ?>">{{EDIT_ICON}} Edit This Instance</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<br/>
|
<br/>
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs->render($this); ?>
|
||||||
<h4>Remove Backend "<?= $this->escape($this->name) ?>"</h4>
|
<h4>{{REMOVE_ICON}} Remove Backend "<?= $this->escape($this->name) ?>"</h4>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
Are you sure you want to remove the backend <?= $this->escape($this->name) ?>?
|
Are you sure you want to remove the backend <?= $this->escape($this->name) ?>?
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<?= $this->form; ?>
|
<?= $this->form; ?>
|
||||||
|
@ -1,13 +1,13 @@
|
|||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs->render($this); ?>
|
||||||
<h4>Remove Instance "<?= $this->escape($this->name) ?>"</h4>
|
<h4>{{REMOVE_ICON}} Remove Instance "<?= $this->escape($this->name) ?>"</h4>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
Are you sure you want to remove the instance <?= $this->escape($this->name) ?>?
|
Are you sure you want to remove the instance <?= $this->escape($this->name) ?>?
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
If you have still any environments or views refering to this instance, you won't be able to send commands anymore
|
{{WARNING_ICON}} If you have still any environments or views refering to this instance, you won't be able to send commands anymore
|
||||||
after deletion.
|
after deletion.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<?= $this->form; ?>
|
<?= $this->form; ?>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs->render($this); ?>
|
||||||
<br/>
|
<br/>
|
||||||
<div class="alert alert-error">
|
<div class="alert alert-error">
|
||||||
<h4><i class="icon-warning-sign"> </i>Saving <?= $this->escape($this->file); ?>failed</h4>
|
<h4><i>{{ERROR_ICON}}</i> Saving <?= $this->escape($this->file); ?>failed</h4>
|
||||||
<br/>
|
<br/>
|
||||||
<p>
|
<p>
|
||||||
Your <?= $this->escape($this->file); ?> configuration couldn't be stored (error: "<?= $this->exceptionMessage; ?>").<br/>
|
Your <?= $this->escape($this->file); ?> configuration couldn't be stored (error: "<?= $this->exceptionMessage; ?>").<br/>
|
||||||
|
@ -22,7 +22,7 @@ $downtimes = $downtimes->fetchAll();
|
|||||||
'action' => 'downtimes'
|
'action' => 'downtimes'
|
||||||
));
|
));
|
||||||
?>">
|
?>">
|
||||||
<label>Sort by</label>
|
<label>Sort By</label>
|
||||||
<br/>
|
<br/>
|
||||||
<?=
|
<?=
|
||||||
$this->formSelect(
|
$this->formSelect(
|
||||||
|
@ -29,27 +29,27 @@ $trimArea = $this->getHelper('Trim');
|
|||||||
<div>
|
<div>
|
||||||
<?php if (!$host->host_handled && $host->host_state > 0): ?>
|
<?php if (!$host->host_handled && $host->host_state > 0): ?>
|
||||||
<a href="#" title="<?= 'Unhandled host' ?>">
|
<a href="#" title="<?= 'Unhandled host' ?>">
|
||||||
<i>UNHANDLED ICON</i>
|
<i>{{UNHANDLED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php if ($host->host_acknowledged && !$host->host_in_downtime): ?>
|
<?php if ($host->host_acknowledged && !$host->host_in_downtime): ?>
|
||||||
<a href="#" title="<?= 'Acknowledged' ?>">
|
<a href="#" title="<?= 'Acknowledged' ?>">
|
||||||
<i>ACKNOWLEDGED ICON</i>
|
<i>{{ACKNOWLEDGED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php if ($host->host_is_flapping): ?>
|
<?php if ($host->host_is_flapping): ?>
|
||||||
<a href="#" title="<?= 'Flapping' ?>">
|
<a href="#" title="<?= 'Flapping' ?>">
|
||||||
<i>FLAPPING ICON</i>
|
<i>{{FLAPPING_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php if (!$host->host_notifications_enabled): ?>
|
<?php if (!$host->host_notifications_enabled): ?>
|
||||||
<a href="#" title="<?= 'Notifications disabled' ?>">
|
<a href="#" title="<?= 'Notifications disabled' ?>">
|
||||||
<i>NOTIFICATIONS DISABLED ICON</i>
|
<i>{{NOTIFICATIONS_DISABLED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php if ($host->host_in_downtime): ?>
|
<?php if ($host->host_in_downtime): ?>
|
||||||
<a href="#" title="<?= 'In downtime' ?>">
|
<a href="#" title="<?= 'In downtime' ?>">
|
||||||
<i>IN DOWNTIME ICON</i>
|
<i>{{IN_DOWNTIME_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
@ -58,11 +58,11 @@ $trimArea = $this->getHelper('Trim');
|
|||||||
<div>
|
<div>
|
||||||
<a href="<?= $this->href('monitoring/show/history', array('host' => $host->host_name)); ?>">
|
<a href="<?= $this->href('monitoring/show/history', array('host' => $host->host_name)); ?>">
|
||||||
<b> <?= ucfirst($viewHelper->monitoringState($host, 'host')); ?> </b>
|
<b> <?= ucfirst($viewHelper->monitoringState($host, 'host')); ?> </b>
|
||||||
<div> since
|
<div> Since
|
||||||
<?= $this->timeSince($host->host_last_state_change); ?>
|
<?= $this->timeSince($host->host_last_state_change); ?>
|
||||||
<?php if ($host->host_state_type == 0): ?>
|
<?php if ($host->host_state_type == 0): ?>
|
||||||
<a href="#" title="<?= 'Soft state' ?>">
|
<a href="#" title="<?= 'Soft state' ?>">
|
||||||
<i>SOFTSTATE ICON</i>
|
<i>{{SOFTSTATE_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
@ -72,7 +72,7 @@ $trimArea = $this->getHelper('Trim');
|
|||||||
<td>
|
<td>
|
||||||
<?php if ($host->host_last_comment !== null): ?>
|
<?php if ($host->host_last_comment !== null): ?>
|
||||||
<a href="#" title="<?= 'Comments' ?>">
|
<a href="#" title="<?= 'Comments' ?>">
|
||||||
<i>COMMENT ICON</i>
|
<i>{{COMMENT_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<a href="<?= $this->href('monitoring/show/host', array('host' => $host->host_name)); ?>">
|
<a href="<?= $this->href('monitoring/show/host', array('host' => $host->host_name)); ?>">
|
||||||
|
@ -6,7 +6,7 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<form method="get" class="form-inline" action="<?= $this->href('monitoring/list/hosts', $this->hosts->getAppliedFilter()->toParams());?>">
|
<form method="get" class="form-inline" action="<?= $this->href('monitoring/list/hosts', $this->hosts->getAppliedFilter()->toParams());?>">
|
||||||
<label>Sort by</label>
|
<label>Sort By</label>
|
||||||
<?= $this->formSelect(
|
<?= $this->formSelect(
|
||||||
'sort',
|
'sort',
|
||||||
$this->sort,
|
$this->sort,
|
||||||
@ -19,7 +19,7 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||||||
); ?>
|
); ?>
|
||||||
<noscript>
|
<noscript>
|
||||||
<button class="btn btn-small btn-default">
|
<button class="btn btn-small btn-default">
|
||||||
<i>REFRESH ICON</i>
|
<i>{{REFRESH_ICON}}</i>
|
||||||
</button>
|
</button>
|
||||||
</noscript>
|
</noscript>
|
||||||
</form>
|
</form>
|
||||||
@ -51,31 +51,31 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||||||
<div>
|
<div>
|
||||||
<?php if (!$host->host_handled && $host->host_state > 0): ?>
|
<?php if (!$host->host_handled && $host->host_state > 0): ?>
|
||||||
<a href="#" title="<?= 'Unhandled host' ?>">
|
<a href="#" title="<?= 'Unhandled host' ?>">
|
||||||
<i>UNHANDLED ICON</i>
|
<i>{{UNHANDLED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($host->host_acknowledged && !$host->host_in_downtime): ?>
|
<?php if ($host->host_acknowledged && !$host->host_in_downtime): ?>
|
||||||
<a href="#" title="<?= 'Acknowledged' ?>">
|
<a href="#" title="<?= 'Acknowledged' ?>">
|
||||||
<i>ACKNOWLEDGED ICON</i>
|
<i>{{ACKNOWLEDGED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($host->host_is_flapping): ?>
|
<?php if ($host->host_is_flapping): ?>
|
||||||
<a href="#" title="<?= 'Flapping' ?>">
|
<a href="#" title="<?= 'Flapping' ?>">
|
||||||
<i>FLAPPING ICON</i>
|
<i>{{FLAPPING_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if (!$host->host_notifications_enabled): ?>
|
<?php if (!$host->host_notifications_enabled): ?>
|
||||||
<a href="#" title="<?= 'Notifications disabled' ?>">
|
<a href="#" title="<?= 'Notifications disabled' ?>">
|
||||||
<i>NOTIFICATIONS DISABLED ICON</i>
|
<i>{{NOTIFICATIONS_DISABLED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($host->host_in_downtime): ?>
|
<?php if ($host->host_in_downtime): ?>
|
||||||
<a href="#" title="<?= 'In downtime' ?>">
|
<a href="#" title="<?= 'In downtime' ?>">
|
||||||
<i>IN DOWNTIME ICON</i>
|
<i>{{IN_DOWNTIME_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
@ -84,11 +84,11 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||||||
<td title="<?= $viewHelper->getStateTitle($host, 'host'); ?>">
|
<td title="<?= $viewHelper->getStateTitle($host, 'host'); ?>">
|
||||||
<div >
|
<div >
|
||||||
<b><?= ucfirst($viewHelper->monitoringState($host, 'host')); ?></b>
|
<b><?= ucfirst($viewHelper->monitoringState($host, 'host')); ?></b>
|
||||||
<div> since
|
<div> Since
|
||||||
<?= $this->timeSince($host->host_last_state_change); ?>
|
<?= $this->timeSince($host->host_last_state_change); ?>
|
||||||
<?php if ($host->host_state_type == 0): ?>
|
<?php if ($host->host_state_type == 0): ?>
|
||||||
<a href="#" title="<?= 'Soft state' ?>">
|
<a href="#" title="<?= 'Soft state' ?>">
|
||||||
<i>SOFTSTATE ICON</i>
|
<i>{{SOFTSTATE_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
@ -97,7 +97,7 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||||||
<td>
|
<td>
|
||||||
<?php if ($host->host_last_comment !== null): ?>
|
<?php if ($host->host_last_comment !== null): ?>
|
||||||
<a href="#" title="<?= 'Comments' ?>">
|
<a href="#" title="<?= 'Comments' ?>">
|
||||||
<i>COMMENT ICON</i>
|
<i>{{COMMENT_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@ $formatter = $this->getHelper('MonitoringProperties');
|
|||||||
$this->notifications->getAppliedFilter()->toParams()
|
$this->notifications->getAppliedFilter()->toParams()
|
||||||
);
|
);
|
||||||
?>">
|
?>">
|
||||||
<label>Sort by</label> <?=
|
<label>Sort By</label> <?=
|
||||||
$this->formSelect(
|
$this->formSelect(
|
||||||
'sort',
|
'sort',
|
||||||
$this->sort,
|
$this->sort,
|
||||||
|
@ -34,31 +34,31 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||||||
<div>
|
<div>
|
||||||
<?php if (!$service->service_handled && $service->service_state > 0): ?>
|
<?php if (!$service->service_handled && $service->service_state > 0): ?>
|
||||||
<a href="#" title="<?= 'Unhandled service' ?>">
|
<a href="#" title="<?= 'Unhandled service' ?>">
|
||||||
<i>UNHANDLED ICON</i>
|
<i>{{UNHANDLED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($service->service_acknowledged && !$service->service_in_downtime): ?>
|
<?php if ($service->service_acknowledged && !$service->service_in_downtime): ?>
|
||||||
<a href="#" title="<?= 'Acknowledged' ?>">
|
<a href="#" title="<?= 'Acknowledged' ?>">
|
||||||
<i>ACKNOWLEDGED ICON</i>
|
<i>{{ACKNOWLEDGED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($service->service_is_flapping): ?>
|
<?php if ($service->service_is_flapping): ?>
|
||||||
<a href="#" title="<?= 'Flapping' ?>">
|
<a href="#" title="<?= 'Flapping' ?>">
|
||||||
<i>FLAPPING ICON</i>
|
<i>{{FLAPPING_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if (!$service->service_notifications_enabled): ?>
|
<?php if (!$service->service_notifications_enabled): ?>
|
||||||
<a href="#" title="<?= 'Notifications disabled' ?>">
|
<a href="#" title="<?= 'Notifications disabled' ?>">
|
||||||
<i>NOTIFICATIONS DISABLED ICON</i>
|
<i>{{NOTIFICATIONS_DISABLED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($service->service_in_downtime): ?>
|
<?php if ($service->service_in_downtime): ?>
|
||||||
<a href="#" title="<?= 'In downtime' ?>">
|
<a href="#" title="<?= 'In downtime' ?>">
|
||||||
<i>IN DOWNTIME ICON</i>
|
<i>{{IN_DOWNTIME_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
@ -67,11 +67,11 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||||||
<td title="<?= $viewHelper->getStateTitle($service, 'service'); ?>">
|
<td title="<?= $viewHelper->getStateTitle($service, 'service'); ?>">
|
||||||
<div>
|
<div>
|
||||||
<?= ucfirst($viewHelper->monitoringState($service, 'service')); ?></b>
|
<?= ucfirst($viewHelper->monitoringState($service, 'service')); ?></b>
|
||||||
<div> since '
|
<div> Since '
|
||||||
<?= $this->timeSince($service->service_last_state_change); ?>
|
<?= $this->timeSince($service->service_last_state_change); ?>
|
||||||
<?php if ($service->service_state_type == 0): ?>
|
<?php if ($service->service_state_type == 0): ?>
|
||||||
<a href="#" title="<?= 'Soft state' ?>">
|
<a href="#" title="<?= 'Soft state' ?>">
|
||||||
<i>SOFTSTATE ICON</i>
|
<i>{{SOFTSTATE_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
@ -80,7 +80,7 @@ $viewHelper = $this->getHelper('MonitoringState');
|
|||||||
<td class="servicename">
|
<td class="servicename">
|
||||||
<?php if ($service->service_last_comment !== null): ?>
|
<?php if ($service->service_last_comment !== null): ?>
|
||||||
<a href="#" title="<?= 'Comments' ?>">
|
<a href="#" title="<?= 'Comments' ?>">
|
||||||
<i>COMMENT ICON</i>
|
<i>{{COMMENT_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<b> <?= $service->service_display_name; ?></b>
|
<b> <?= $service->service_display_name; ?></b>
|
||||||
|
@ -13,7 +13,7 @@ $trimArea = $this->getHelper('Trim');
|
|||||||
<?php return; endif ?>
|
<?php return; endif ?>
|
||||||
|
|
||||||
<form method="get" action="<?= $this->href('monitoring/list/services', $this->services->getAppliedFilter()->toParams()); ?>">
|
<form method="get" action="<?= $this->href('monitoring/list/services', $this->services->getAppliedFilter()->toParams()); ?>">
|
||||||
<label>Sort by</label>
|
<label>Sort By</label>
|
||||||
<?= $this->formSelect(
|
<?= $this->formSelect(
|
||||||
'sort',
|
'sort',
|
||||||
$this->sort,
|
$this->sort,
|
||||||
@ -61,31 +61,31 @@ $trimArea = $this->getHelper('Trim');
|
|||||||
<div>
|
<div>
|
||||||
<?php if (!$service->service_handled && $service->service_state > 0): ?>
|
<?php if (!$service->service_handled && $service->service_state > 0): ?>
|
||||||
<a href="#" title="<?= 'Unhandled service' ?>">
|
<a href="#" title="<?= 'Unhandled service' ?>">
|
||||||
<i>UNHANDLED ICON</i>
|
<i>{{UNHANDLED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($service->service_acknowledged && !$service->service_in_downtime): ?>
|
<?php if ($service->service_acknowledged && !$service->service_in_downtime): ?>
|
||||||
<a href="#" title="<?= 'Acknowledged' ?>">
|
<a href="#" title="<?= 'Acknowledged' ?>">
|
||||||
<i>ACKNOWLEDGED ICON</i>
|
<i>{{ACKNOWLEDGED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($service->service_is_flapping): ?>
|
<?php if ($service->service_is_flapping): ?>
|
||||||
<a href="#" title="<?= 'Flapping' ?>">
|
<a href="#" title="<?= 'Flapping' ?>">
|
||||||
<i>FLAPPING ICON</i>
|
<i>{{FLAPPING_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if (!$service->service_notifications_enabled): ?>
|
<?php if (!$service->service_notifications_enabled): ?>
|
||||||
<a href="#" title="<?= 'Notifications disabled' ?>">
|
<a href="#" title="<?= 'Notifications disabled' ?>">
|
||||||
<i>NOTIFICATIONS DISABLED ICON</i>
|
<i>{{NOTIFICATIONS_DISABLED_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if ($service->service_in_downtime): ?>
|
<?php if ($service->service_in_downtime): ?>
|
||||||
<a href="#" title="<?= 'In downtime' ?>">
|
<a href="#" title="<?= 'In downtime' ?>">
|
||||||
<i>IN DOWNTIME ICON</i>
|
<i>{{IN_DOWNTIME_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
@ -96,12 +96,12 @@ $trimArea = $this->getHelper('Trim');
|
|||||||
<td title="<?= $viewHelper->getStateTitle($service, 'service'); ?>">
|
<td title="<?= $viewHelper->getStateTitle($service, 'service'); ?>">
|
||||||
<div>
|
<div>
|
||||||
<b><?= ucfirst($viewHelper->monitoringState($service, 'service')); ?></b>
|
<b><?= ucfirst($viewHelper->monitoringState($service, 'service')); ?></b>
|
||||||
<div> since
|
<div> Since
|
||||||
<?= $this->timeSince($service->service_last_state_change); ?>
|
<?= $this->timeSince($service->service_last_state_change); ?>
|
||||||
|
|
||||||
<?php if ($service->service_state_type == 0): ?>
|
<?php if ($service->service_state_type == 0): ?>
|
||||||
<a href="#" title="<?= 'Soft state' ?>">
|
<a href="#" title="<?= 'Soft state' ?>">
|
||||||
<i>SOFTSTATE ICON</i>
|
<i>{{SOFTSTATE_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
@ -112,7 +112,7 @@ $trimArea = $this->getHelper('Trim');
|
|||||||
<td>
|
<td>
|
||||||
<?php if ($service->service_last_comment !== null): ?>
|
<?php if ($service->service_last_comment !== null): ?>
|
||||||
<a href="#" title="<?= 'Comments' ?>">
|
<a href="#" title="<?= 'Comments' ?>">
|
||||||
<i>COMMENT ICON</i>
|
<i>{{COMMENT_ICON}}</i>
|
||||||
</a>
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
|
@ -1,29 +0,0 @@
|
|||||||
<?= $this->expandable(
|
|
||||||
$this->translate('Check statistics'),
|
|
||||||
'<table style="width:100%">
|
|
||||||
<thead>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr>
|
|
||||||
<td style="width: 25em">' . $this->translate('Last check') . '</td>
|
|
||||||
<td>' . $this->format()->timeSince($object->last_check) . '</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>' . $this->translate('Next check') . '</td>
|
|
||||||
<td class="icinga-uiwidget-countdown" countdown-end="' . $object->next_check . '">'
|
|
||||||
. $this->format()->timeUntil($object->next_check)
|
|
||||||
. '</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>' . $this->translate('Check execution time') . '</td>
|
|
||||||
<td>' . $object->execution_time . '</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>' . $this->translate('Check latency') . '</td>
|
|
||||||
<td>' . $object->latency . '</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
',
|
|
||||||
array('collapsed' => false)
|
|
||||||
);
|
|
@ -2,9 +2,6 @@
|
|||||||
$commandParts = preg_split('|!|', $object->check_command);
|
$commandParts = preg_split('|!|', $object->check_command);
|
||||||
$commandName = array_shift($commandParts);
|
$commandName = array_shift($commandParts);
|
||||||
?>
|
?>
|
||||||
<?= $this->expandable(
|
|
||||||
'<b>Command:</b> '. $commandName,
|
{{COMMAND_ICON}} <b>Command:</b> <?= $commandName; ?>
|
||||||
$this->commandArguments($object->check_command),
|
<?= $this->commandArguments($object->check_command); ?>
|
||||||
// TODO: no JS handler right now, should be collapsed
|
|
||||||
array('collapsed' => ! (bool) strpos($object->check_command, '!'))
|
|
||||||
) ?>
|
|
@ -21,12 +21,13 @@ foreach ($this->comments as $comment) {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<div class="information-container">
|
<div class="panel">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Comments</span>
|
<span>{{COMMENT_ICON}} Comments</span>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="panel-body">
|
||||||
<blockquote> <?= implode('<br />', $list) ?></blockquote>
|
<blockquote> <?= implode('<br />', $list) ?></blockquote>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
@ -11,7 +11,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
echo '<strong>Contacts:</strong> ';
|
echo '<strong>{{CONTACT_ICON}} Contacts:</strong> ';
|
||||||
echo implode(', ', $contactList);
|
echo implode(', ', $contactList);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -25,7 +25,7 @@
|
|||||||
)
|
)
|
||||||
) . '">' . $contactgroup->contactgroup_alias . '</a>';
|
) . '">' . $contactgroup->contactgroup_alias . '</a>';
|
||||||
}
|
}
|
||||||
echo '<strong>Contactgroups:</strong> ';
|
echo '<strong>{{CONTACTGROUP_ICON}} Contactgroups:</strong> ';
|
||||||
echo implode(', ', $contactGroupList);
|
echo implode(', ', $contactGroupList);
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
<?php if (isset($this->customvars) && count($this->customvars)) { ?>
|
<?php if (isset($this->customvars) && count($this->customvars)) { ?>
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Customvariables</span>
|
<span>Customvariables</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div class="panel-body">
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Name</th>
|
<th>Name</th>
|
||||||
|
@ -27,12 +27,12 @@
|
|||||||
$list[] = '<td>'. implode('</td><td>', $row). '</td>';
|
$list[] = '<td>'. implode('</td><td>', $row). '</td>';
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Downtimes</span>
|
<span>{{IN_DOWNTIME_ICON}} Downtimes</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div class="panel-body">
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
<?= implode('</tr><tr>', $list); ?>
|
<?= implode('</tr><tr>', $list); ?>
|
||||||
|
@ -9,17 +9,17 @@
|
|||||||
|
|
||||||
$flags = $this->monitoringFlags($object);
|
$flags = $this->monitoringFlags($object);
|
||||||
?>
|
?>
|
||||||
<table class="flag-container">
|
<table class="table table-condensed">
|
||||||
<?php foreach ($flags as $name => $value): ?>
|
<?php foreach ($flags as $name => $value): ?>
|
||||||
<tr>
|
<tr>
|
||||||
<th><?= $name; ?></th>
|
<th><?= $name; ?></th>
|
||||||
<td>
|
<td>
|
||||||
<?php if ($value === true): ?>
|
<?php if ($value === true): ?>
|
||||||
<span class="flag flag-enabled">ENABLED</span>
|
<span>{{ENABLED_ICON}} ENABLED</span>
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
<span class="flag flag-disabled">DISABLED</span>
|
<span>{{DISABLED_ICON}} DISABLED</span>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<?php endforeach; ?>
|
<?php endforeach; ?>
|
||||||
</table>
|
</table>
|
@ -1,28 +1,33 @@
|
|||||||
<? $showService = $object->service_description && $tabs->getActiveName() !== 'host' ?>
|
<?php $showService = $object->service_description && $tabs->getActiveName() !== 'host' ?>
|
||||||
<? if (! $compact): ?>
|
<?php if (! $compact): ?>
|
||||||
<?= $tabs->render($this) ?>
|
<?= $tabs->render($this) ?>
|
||||||
<? endif ?>
|
<?php endif ?>
|
||||||
<table style="margin-bottom: 1em">
|
|
||||||
<tr class="<?= $this->monitoringState($object, 'host') ?><?= $object->host_handled ? ' handled' : '' ?>">
|
<table class="table">
|
||||||
<td><b><?= $this->escape($object->host_name) ?><?
|
<tr>
|
||||||
if ($object->host_address && $object->host_address !== $object->host_name): ?>
|
<td>
|
||||||
(<?= $this->escape($object->host_address) ?>)
|
{{HOST_ICON}} <b><?= $this->escape($object->host_name) ?>
|
||||||
<? endif ?>
|
<?php if ($object->host_address && $object->host_address !== $object->host_name): ?>
|
||||||
</b></td>
|
(<?= $this->escape($object->host_address) ?>)
|
||||||
<td class="state"<?= $showService ? '' : ' rowspan="2"' ?>>
|
<?php endif ?>
|
||||||
<?= $this->util()->getHostStateName($object->host_state) ?><br />
|
</b>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= $this->util()->getHostStateName($object->host_state) ?>
|
||||||
|
<br/>
|
||||||
since <?= $this->timeSince($object->host_last_state_change) ?>
|
since <?= $this->timeSince($object->host_last_state_change) ?>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<? if ($showService): ?>
|
<?php if ($showService): ?>
|
||||||
<tr class="<?= $this->monitoringState($object, 'service') ?><?= $object->service_handled ? ' handled' : '' ?>">
|
<tr>
|
||||||
<td><b>Service: <?= $this->escape($object->service_description) ?></b></td>
|
<td>
|
||||||
<td class="state">
|
{{SERVICE_ICON}} <b>Service: <?= $this->escape($object->service_description) ?></b>
|
||||||
<?= $this->util()->getServiceStateName($object->service_state); ?><br />
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= $this->util()->getServiceStateName($object->service_state); ?>
|
||||||
|
<br/>
|
||||||
since <?= $this->timeSince($object->service_last_state_change) ?>
|
since <?= $this->timeSince($object->service_last_state_change) ?>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<? else: ?>
|
<?php endif; ?>
|
||||||
<tr><td><b>Host state</b></td></tr>
|
|
||||||
<? endif ?>
|
|
||||||
</table>
|
</table>
|
||||||
|
@ -1,12 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
if (empty($object->hostgroups)) return;
|
|
||||||
|
|
||||||
$list = array();
|
|
||||||
foreach ($object->hostgroups as $name => $alias) {
|
|
||||||
$list[] = '<a href="' . $this->href('monitoring/list/host', array('hostgroups' => $name)) . '">'
|
|
||||||
. $alias
|
|
||||||
. '</a>';
|
|
||||||
}
|
|
||||||
echo '<b>Hostgroups:</b> ' . implode(', ', $list) . "<br />\n";
|
|
||||||
|
|
@ -1,4 +0,0 @@
|
|||||||
<?= $this->expandable(
|
|
||||||
$this->pluginOutput($object->output),
|
|
||||||
$this->pluginOutput($object->long_output)
|
|
||||||
) ?>
|
|
@ -1,7 +0,0 @@
|
|||||||
<? if ($object->perfdata): ?>
|
|
||||||
<?= $this->expandable(
|
|
||||||
'<b>Performance data</b>',
|
|
||||||
$this->perfdata($object->perfdata),
|
|
||||||
array('collapsed' => false)
|
|
||||||
) ?>
|
|
||||||
<? endif ?>
|
|
@ -9,11 +9,11 @@ if (isset($this->service)) {
|
|||||||
|
|
||||||
$properties = $this->monitoringProperties($object);
|
$properties = $this->monitoringProperties($object);
|
||||||
?>
|
?>
|
||||||
<table>
|
<table class="table table-bordered">
|
||||||
<?php foreach ($properties as $label => $value): ?>
|
<?php foreach ($properties as $label => $value): ?>
|
||||||
<tr>
|
<tr>
|
||||||
<th><?= $label ?></th>
|
<th><?= $label ?></th>
|
||||||
<td><?= $value ?></td>
|
<td><?= $value ?></td>
|
||||||
</tr>
|
</tr>
|
||||||
<?php endforeach; ?>
|
<?php endforeach; ?>
|
||||||
</table>
|
</table>
|
@ -8,5 +8,5 @@ foreach ($object->servicegroups as $name => $alias) {
|
|||||||
. $alias
|
. $alias
|
||||||
. '</a>';
|
. '</a>';
|
||||||
}
|
}
|
||||||
echo '<b>Servicegroups:</b> ' . implode(', ', $list) . "<br />\n";
|
echo '{{SERVICEGROUP_ICON}} <b>Servicegroups:</b> ' . implode(', ', $list) . "<br />\n";
|
||||||
|
|
||||||
|
@ -17,107 +17,103 @@ if (!$this->compact) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<div class="information-container">
|
<div>
|
||||||
<?php if ($inlineCommands === true): ?>
|
<?php if ($inlineCommands === true): ?>
|
||||||
<div class="pull-right">
|
<div class="pull-right">
|
||||||
<?=
|
<?=
|
||||||
$this->monitoringCommands(
|
$this->monitoringCommands(
|
||||||
($showService === true) ? $this->service : $this->host,
|
($showService === true) ? $this->service : $this->host,
|
||||||
'small'
|
'small'
|
||||||
);
|
);
|
||||||
?>
|
?>
|
||||||
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
|
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
{{HOST_ICON}}
|
||||||
|
<?php if ($this->host->host_icon_image): ?>
|
||||||
|
<div>
|
||||||
|
<img src="<?= $this->host->host_icon_image; ?>" alt="Host image"/>
|
||||||
</div>
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
|
<strong>
|
||||||
|
<?= $this->escape($this->host->host_name); ?>
|
||||||
|
<?php if ($this->host->host_address && $this->host->host_address !== $this->host->host_name): ?>
|
||||||
|
(<?= $this->escape($this->host->host_address); ?>)
|
||||||
|
<?php endif; ?>
|
||||||
|
</strong>
|
||||||
|
|
||||||
|
<?php if (isset($this->host->host_alias) && $this->host->host_alias !== $this->host->host_name): ?>
|
||||||
|
<br/>
|
||||||
|
<sup>(<?= $this->host->host_alias; ?>)</sup>
|
||||||
|
<?php endif; ?>
|
||||||
|
</td>
|
||||||
|
<td
|
||||||
|
<?= $showService ? '' : ' rowspan="2"'; ?>
|
||||||
|
<?= $this->util()->getHostStateName($this->host->host_state); ?>
|
||||||
|
since <?= $this->timeSince($this->host->host_last_state_change); ?>
|
||||||
|
<?php if ($this->host->host_acknowledged === '1'): ?>
|
||||||
|
(Has been acknowledged)
|
||||||
|
<?php endif; ?>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<?php if ($this->host->host_action_url || $this->host->host_notes_url): ?>
|
||||||
|
<tr>
|
||||||
|
<td rowspan="2">
|
||||||
|
<?php if ($this->host->host_action_url): ?>
|
||||||
|
{{EXTERNAL_LINK_ICON}}
|
||||||
|
<a href='<?= $this->host->host_notes_url ?>'>Host actions </a>
|
||||||
|
<?php endif; ?>
|
||||||
|
<?php if ($this->host->host_notes_url): ?>
|
||||||
|
{{EXTERNAL_LINK_ICON}}
|
||||||
|
<a href='<?= $this->host->host_notes_url ?>'>Host notes </a>
|
||||||
|
<?php endif; ?>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<table>
|
<?php if ($showService === true): ?>
|
||||||
<tr class="<?= $this->monitoringState($this->host, 'host') ?><?= $this->host->host_handled ? ' handled' : '' ?>">
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
|
{{SERVICE_ICON}}
|
||||||
|
<?php if ($this->service->service_icon_image): ?>
|
||||||
|
<div>
|
||||||
|
<img src="<?= $this->service->service_icon_image; ?>" alt="Host image"/>
|
||||||
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
|
<strong>
|
||||||
|
Service: <?= $this->escape($this->service->service_description); ?>
|
||||||
|
</strong>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= $this->util()->getServiceStateName($this->service->service_state); ?>
|
||||||
|
since <?= $this->timeSince($this->service->service_last_state_change); ?>
|
||||||
|
<?php if ($this->service->service_acknowledged === '1'): ?>
|
||||||
|
(Has been acknowledged)
|
||||||
|
<?php endif; ?>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
<?php if ($this->host->host_icon_image): ?>
|
|
||||||
<div class="monitoring_icon">
|
|
||||||
<img src="<?= $this->host->host_icon_image; ?>" alt="Host image" />
|
|
||||||
</div>
|
|
||||||
<?php endif; ?>
|
|
||||||
<strong>
|
|
||||||
<?= $this->escape($this->host->host_name); ?>
|
|
||||||
<?php if ($this->host->host_address && $this->host->host_address !== $this->host->host_name): ?>
|
|
||||||
(<?= $this->escape($this->host->host_address); ?>)
|
|
||||||
<?php endif; ?>
|
|
||||||
</strong>
|
|
||||||
|
|
||||||
<?php if (isset($this->host->host_alias) && $this->host->host_alias !== $this->host->host_name): ?>
|
<?php if ($this->service->service_action_url || $this->service->service_notes_url): ?>
|
||||||
<br />
|
<tr>
|
||||||
<sup>(<?= $this->host->host_alias; ?>)</sup>
|
<td rowspan="2">
|
||||||
<?php endif; ?>
|
<?php if ($this->service->service_action_url): ?>
|
||||||
</td>
|
{{EXTERNAL_LINK_ICON}}
|
||||||
<td class="state"<?= $showService ? '' : ' rowspan="2"'; ?>
|
<a href='<?= $this->service->service_notes_url ?>'>Service actions </a>
|
||||||
<?= $this->util()->getHostStateName($this->host->host_state); ?>
|
|
||||||
since <?= $this->timeSince($this->host->host_last_state_change); ?>
|
|
||||||
<?php if ($this->host->host_acknowledged === '1'): ?>
|
|
||||||
(Has been acknowledged)
|
|
||||||
<?php endif; ?>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
|
|
||||||
<?php if ($this->host->host_action_url || $this->host->host_notes_url): ?>
|
|
||||||
<tr>
|
|
||||||
<td class="urls" rowspan="2">
|
|
||||||
<?php if ($this->host->host_action_url): ?>
|
|
||||||
<span class="url">
|
|
||||||
<a href='<?= $this->host->host_notes_url ?>'>Host actions </a>
|
|
||||||
</span>
|
|
||||||
<?php endif; ?>
|
|
||||||
<?php if ($this->host->host_notes_url): ?>
|
|
||||||
<span class="url">
|
|
||||||
<a href='<?= $this->host->host_notes_url ?>'>Host notes </a>
|
|
||||||
</span>
|
|
||||||
<?php endif; ?>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
|
<?php if ($this->service->service_notes_url): ?>
|
||||||
<?php if ($showService === true): ?>
|
{{EXTERNAL_LINK_ICON}}
|
||||||
<tr class="<?= $this->monitoringState($this->service, 'service'); ?><?= $this->service->service_handled ? ' handled' : '' ?>">
|
<a href='<?= $this->service->service_notes_url ?>'>Service notes </a>
|
||||||
<td>
|
|
||||||
<?php if ($this->service->service_icon_image): ?>
|
|
||||||
<div class="monitoring_icon">
|
|
||||||
<img src="<?= $this->service->service_icon_image; ?>" alt="Host image" />
|
|
||||||
</div>
|
|
||||||
<?php endif; ?>
|
|
||||||
<strong>
|
|
||||||
Service: <?= $this->escape($this->service->service_description); ?>
|
|
||||||
</strong>
|
|
||||||
</td>
|
|
||||||
<td class="state">
|
|
||||||
<?= $this->util()->getServiceStateName($this->service->service_state); ?>
|
|
||||||
since <?= $this->timeSince($this->service->service_last_state_change); ?>
|
|
||||||
<?php if ($this->service->service_acknowledged === '1'): ?>
|
|
||||||
(Has been acknowledged)
|
|
||||||
<?php endif; ?>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
|
|
||||||
|
|
||||||
<?php if ($this->service->service_action_url || $this->service->service_notes_url): ?>
|
|
||||||
<tr>
|
|
||||||
<td class="urls" rowspan="2">
|
|
||||||
<?php if ($this->service->service_action_url): ?>
|
|
||||||
<span class="url">
|
|
||||||
<a href='<?= $this->service->service_notes_url ?>'>Service actions </a>
|
|
||||||
</span>
|
|
||||||
<?php endif; ?>
|
|
||||||
<?php if ($this->service->service_notes_url): ?>
|
|
||||||
<span class="url">
|
|
||||||
<a href='<?= $this->service->service_notes_url ?>'>Service notes </a>
|
|
||||||
</span>
|
|
||||||
<?php endif; ?>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<?php endif; ?>
|
|
||||||
|
|
||||||
|
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</table>
|
</td>
|
||||||
<div class="clearfix"></div>
|
</tr>
|
||||||
|
<?php endif; ?>
|
||||||
|
<?php endif; ?>
|
||||||
|
</table>
|
||||||
|
<div class="clearfix"></div>
|
||||||
</div>
|
</div>
|
@ -4,32 +4,30 @@ $history->limit(10);
|
|||||||
$hhistory = $this->history->paginate();
|
$hhistory = $this->history->paginate();
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<?php if (empty($hhistory)): ?>
|
<?php if (empty($hhistory)): ?>
|
||||||
There are no matching history entries right now
|
There are no matching history entries right now
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
<?= $this->paginationControl($hhistory, null, null, array('preserve' => $preserve)); ?>
|
<?= $this->paginationControl($hhistory, null, null, array('preserve' => $preserve)); ?>
|
||||||
<table class="paginatable">
|
|
||||||
|
<table class="table table-condensed">
|
||||||
<tbody>
|
<tbody>
|
||||||
<?php foreach ($hhistory as $event): ?>
|
<?php foreach ($hhistory as $event): ?>
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
if ($event->object_type == 'host') {
|
if ($event->object_type == 'host') {
|
||||||
$states = array('up', 'down', 'unreachable', 'unknown', 99 => 'pending', null => 'pending');
|
$states = array('up', 'down', 'unreachable', 'unknown', 99 => 'pending', null => 'pending');
|
||||||
} else {
|
} else {
|
||||||
$states = array('ok', 'warning', 'critical', 'unknown', 99 => 'pending', null => 'pending');
|
$states = array('ok', 'warning', 'critical', 'unknown', 99 => 'pending', null => 'pending');
|
||||||
}
|
}
|
||||||
|
|
||||||
$row_class = array_key_exists($event->state, $states) ? $states[$event->state] : 'invalid';
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<tr class="<?= $row_class ?>"><td class="state"><?= date('d.m. H:i', $event->timestamp ) ?></td>
|
<tr>
|
||||||
|
<td><?= date('d.m. H:i', $event->timestamp ) ?></td>
|
||||||
|
|
||||||
<? if (! $object): ?>
|
<? if (! $object): ?>
|
||||||
<td><?= $this->escape($event->host_name) ?></td>
|
<td><?= $this->escape($event->host_name) ?></td>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
|
|
||||||
<? if (! $object instanceof Monitoring\Object\Service): ?>
|
<? if (! $object instanceof Monitoring\Object\Service): ?>
|
||||||
<td>
|
<td>
|
||||||
<? if ($object): ?>
|
<? if ($object): ?>
|
||||||
<a href="<?= $this->href('monitoring/show/service',array(
|
<a href="<?= $this->href('monitoring/show/service',array(
|
||||||
@ -42,45 +40,43 @@ There are no matching history entries right now
|
|||||||
<? endif ?>
|
<? endif ?>
|
||||||
</td>
|
</td>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
<td style="padding: 0.2em;"><?php
|
<td>
|
||||||
$imgparams = array(
|
<?php
|
||||||
'width' => 16,
|
|
||||||
'height' => 16,
|
switch ($event->type) {
|
||||||
);
|
case 'notify':
|
||||||
switch ($event->type) {
|
echo 'NOTIFICATION_ICON';
|
||||||
case 'notify':
|
break;
|
||||||
echo $this->img('img/classic/mail-notification.png', $imgparams);
|
case 'comment':
|
||||||
break;
|
echo 'COMMENT_ICON';
|
||||||
case 'comment':
|
break;
|
||||||
echo $this->img('img/classic/comment.gif', $imgparams);
|
case 'ack':
|
||||||
break;
|
echo 'ACKNOWLEDGEMENT_ICON';
|
||||||
case 'ack':
|
break;
|
||||||
echo $this->img('img/classic/ack.gif', $imgparams);
|
case 'dt_comment':
|
||||||
break;
|
echo 'IN_DOWNTIME_ICON';
|
||||||
case 'dt_comment':
|
break;
|
||||||
echo $this->img('img/classic/downtime.gif', $imgparams);
|
case 'flapping':
|
||||||
break;
|
echo 'FLAPPING_ICON';
|
||||||
case 'flapping':
|
break;
|
||||||
echo $this->img('img/classic/flapping.gif', $imgparams);
|
case 'hard_state':
|
||||||
break;
|
echo 'HARDSTATE_ICON';
|
||||||
case 'hard_state':
|
break;
|
||||||
echo $this->img('img/classic/state-hard.png', $imgparams);
|
case 'soft_state':
|
||||||
break;
|
echo 'SOFTSTATE_ICON';
|
||||||
case 'soft_state':
|
break;
|
||||||
echo $this->img('img/classic/state-soft.png', $imgparams);
|
case 'dt_start':
|
||||||
break;
|
echo 'DOWNTIME_START_ICON';
|
||||||
case 'dt_start':
|
echo ' Downtime start';
|
||||||
echo $this->img('img/classic/downtime-start.png', $imgparams);
|
break;
|
||||||
echo ' Downtime start';
|
case 'dt_end':
|
||||||
break;
|
echo 'DOWNTIME_END_ICON';
|
||||||
case 'dt_end':
|
echo ' Downtime end';
|
||||||
echo $this->img('img/classic/downtime-end.png', $imgparams);
|
break;
|
||||||
echo ' Downtime end';
|
}
|
||||||
break;
|
?>
|
||||||
}
|
|
||||||
?>
|
|
||||||
<? if ($event->attempt !== null): ?>
|
<? if ($event->attempt !== null): ?>
|
||||||
[ <?= $event->attempt ?>/<?=$event->max_attempts ?> ]
|
[ <?= $event->attempt ?>/<?=$event->max_attempts ?> ]
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -22,26 +22,24 @@ $this->partial(
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<?= $this->preview_image ?>
|
<?= $this->preview_image ?>
|
||||||
|
<br/>
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Plugin output</span>
|
<span>Plugin Output</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="panel-body">
|
||||||
<?= $this->pluginOutput($this->host->host_output); ?>
|
<?= $this->pluginOutput($this->host->host_output); ?>
|
||||||
<?= $this->pluginOutput($this->host->host_long_output); ?>
|
<?= $this->pluginOutput($this->host->host_long_output); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Command</span>
|
{{CHECK_ICON}} <span>Check Command</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div class="panel-body">
|
||||||
<strong>Command:</strong>
|
|
||||||
<?php
|
<?php
|
||||||
$explodedCommand = explode('!', $this->host->host_check_command, 2);
|
$explodedCommand = explode('!', $this->host->host_check_command, 2);
|
||||||
array_shift($explodedCommand);
|
array_shift($explodedCommand);
|
||||||
@ -50,16 +48,17 @@ $this->partial(
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Groups and Contacts</span>
|
<span>Groups and Contacts</span>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="panel-body">
|
||||||
<?php if (count($hostgroupLinkList)): ?>
|
<?php if (count($hostgroupLinkList)): ?>
|
||||||
<strong>Hostgroups:</strong>
|
{{HOSTGROUP_ICON}} <strong>Hostgroups:</strong>
|
||||||
<?= implode(' ', $hostgroupLinkList); ?>
|
<?= implode(' ', $hostgroupLinkList); ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?= $this->render('show/components/contacts.phtml') ?>
|
<?= $this->render('show/components/contacts.phtml') ?>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?= $this->render('show/components/comments.phtml'); ?>
|
<?= $this->render('show/components/comments.phtml'); ?>
|
||||||
@ -69,39 +68,39 @@ $this->partial(
|
|||||||
<?= $this->render('show/components/customvars.phtml'); ?>
|
<?= $this->render('show/components/customvars.phtml'); ?>
|
||||||
|
|
||||||
<?php if ($this->host->host_perfdata): ?>
|
<?php if ($this->host->host_perfdata): ?>
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Perfdata</span>
|
<span>Perfdata</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="panel-body">
|
||||||
<?= $this->perfdata($this->host->host_perfdata); ?>
|
<?= $this->perfdata($this->host->host_perfdata); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Flags</span>
|
<span>Flags</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="panel-body">
|
||||||
<?= $this->render('show/components/flags.phtml'); ?>
|
<?= $this->render('show/components/flags.phtml'); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Properties</span>
|
<span>Properties</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="panel-body">
|
||||||
<?= $this->render('show/components/properties.phtml'); ?>
|
<?= $this->render('show/components/properties.phtml'); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="information-container">
|
<div class="panel panel-default">
|
||||||
<div class="head">
|
<div class="panel-heading">
|
||||||
<span>Commands</span>
|
{{COMMAND_ICON}} <span>Commands</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="panel-body">
|
||||||
<?= $this->monitoringCommands($this->host, 'full'); ?>
|
<?= $this->monitoringCommands($this->host, 'full'); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
@ -1,117 +0,0 @@
|
|||||||
<!--<?php if (!isset($this->service) || $this->service == null): ?>
|
|
||||||
<div class="alert alert-info fullpage_infobox">
|
|
||||||
No service selected
|
|
||||||
</div>
|
|
||||||
<?php return; endif; ?>
|
|
||||||
<br>
|
|
||||||
<?= $this->expandable(
|
|
||||||
'<b>'
|
|
||||||
. $this->translate('Plugin output:')
|
|
||||||
. '</b> '
|
|
||||||
. $this->pluginOutput($this->service->service_output),
|
|
||||||
$this->service->service_long_output
|
|
||||||
? $this->pluginOutput($this->service->service_long_output)
|
|
||||||
: ''
|
|
||||||
) ?>
|
|
||||||
<?php
|
|
||||||
$explodedCmd = explode('!', $this->service->service_check_command);
|
|
||||||
$row = '<dd><b>%s</b> : %s</dd>';
|
|
||||||
$table = '';
|
|
||||||
if (count($explodedCmd) > 1) {
|
|
||||||
$table = '<dl>';
|
|
||||||
for ($i = 1; $i < count($explodedCmd); $i++) {
|
|
||||||
$table .= sprintf($row, '$ARG' . $i . '$', $explodedCmd[$i]);
|
|
||||||
}
|
|
||||||
$table .= '</dl>';
|
|
||||||
}
|
|
||||||
echo $this->expandable('<b>' . $this->translate('Check command:') . '</b> ' .$explodedCmd[0], $table); ?>
|
|
||||||
|
|
||||||
<?php
|
|
||||||
|
|
||||||
$perfData = $this->perfdata($this->service->service_perfdata);
|
|
||||||
if (!$perfData && $this->service->service_perfdata)
|
|
||||||
$perfData = $this->service->service_perfdata;
|
|
||||||
|
|
||||||
?>
|
|
||||||
<?php if ($perfData): ?>
|
|
||||||
<div class="expandable" >
|
|
||||||
<div class="expand-title"><b><?= $this->translate('Performance data') ?></b> </div>
|
|
||||||
<div class="expand-content">
|
|
||||||
<?= $perfData ?>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<?php endif; ?>
|
|
||||||
-->
|
|
||||||
<?php //@TODO: Create check_statistic helper
|
|
||||||
?>
|
|
||||||
<?= $this->expandable(
|
|
||||||
$this->translate('Check statistics'),
|
|
||||||
'sdfas'
|
|
||||||
) ?>
|
|
||||||
|
|
||||||
<div class="expandable" >
|
|
||||||
<div class="expand-title">
|
|
||||||
<b><?= $this->translate('Check statistics') ?></b>
|
|
||||||
<div class="expand-controls">
|
|
||||||
<a href="#" target="_self" title="<?= $this->translate('Check now') ?>">
|
|
||||||
<i class='icon-repeat'></i>
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="expand-content">
|
|
||||||
<table style="width:100%">
|
|
||||||
<thead>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr>
|
|
||||||
<td style="width: 25em"><?= $this->translate('Last check') ?></td>
|
|
||||||
<td><?= $this->format()->timeSince($this->service->service_last_check) ?></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td><?= $this->translate('Next check')?></td>
|
|
||||||
<td>
|
|
||||||
<span class="icinga-uiwidget-countdown" countdown-end="<?= $this->service->service_next_check ?>">
|
|
||||||
<?= $this->format()->timeUntil($this->service->service_next_check) ?>
|
|
||||||
</span>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td><?= $this->translate('Check execution time') ?></td>
|
|
||||||
<td><?= $this->service->service_execution_time ?></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td><?= $this->translate('Check latency') ?></td>
|
|
||||||
<td><?=$this->service->service_latency ?></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<?php if (isset($this->service->service_comments) && is_array($this->service->service_comments)): ?>
|
|
||||||
<div class="expandable" >
|
|
||||||
<div class="expand-title">
|
|
||||||
<b><?= $this->translate('Comments') ?></b>+
|
|
||||||
</div>
|
|
||||||
<div class="expand-content" style="padding: 0px">
|
|
||||||
<table class="subTable icinga-widget" type="icinga/subTable" maxItems="10" style="width:100%">
|
|
||||||
<thead>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<?php
|
|
||||||
$comments = $this->service->service_comments;
|
|
||||||
if (! is_array($comments)) {
|
|
||||||
$comments = array($comments);
|
|
||||||
}
|
|
||||||
foreach ($comments as $comment ): ?>
|
|
||||||
<tr>
|
|
||||||
<td><?= $this->timeSince($comment->entry_time); ?></td>
|
|
||||||
<td><?= htmlspecialchars($comment->author); ?></td>
|
|
||||||
<td><?= htmlspecialchars($comment->data); ?></td>
|
|
||||||
</tr>
|
|
||||||
<?php endforeach; ?>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<?php endif; ?>
|
|
@ -25,8 +25,8 @@ $this->partial(
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<?= $this->preview_image ?>
|
<?= $this->preview_image ?>
|
||||||
<div class="information-container">
|
<div>
|
||||||
<div class="head">
|
<div>
|
||||||
<span>Plugin output</span>
|
<span>Plugin output</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
@ -35,27 +35,26 @@ $this->partial(
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="information-container">
|
<div>
|
||||||
<div class="head">
|
<div>
|
||||||
<span>Command</span>
|
{{CHECK_ICON}} <span>Check Command</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<strong>Command:</strong>
|
|
||||||
<?php
|
<?php
|
||||||
$explodedCommand = explode('!', $this->service->service_check_command, 2);
|
$explodedCommand = explode('!', $this->service->service_check_command, 2);
|
||||||
echo array_shift($explodedCommand);
|
echo array_shift($explodedCommand);
|
||||||
?>
|
?>
|
||||||
<?= $this->commandArguments($this->service->service_check_command); ?>
|
<?= $this->commandArguments($this->service->service_check_command); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="information-container">
|
<div>
|
||||||
<div class="head">
|
<div>
|
||||||
<span>Groups and Contacts</span>
|
{{GROUP_ICON}} <span>Groups and Contacts</span>
|
||||||
</div>
|
</div>
|
||||||
<?php if (count($servicegroupLinkList)) { ?>
|
<?php if (count($servicegroupLinkList)) { ?>
|
||||||
<strong>Servicegroups:</strong>
|
{{SERVICEGROUP_ICON}} <strong>Servicegroups:</strong>
|
||||||
<?= implode(' ', $servicegroupLinkList); ?>
|
<?= implode(' ', $servicegroupLinkList); ?>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
|
|
||||||
@ -69,9 +68,9 @@ $this->partial(
|
|||||||
<?= $this->render('show/components/customvars.phtml'); ?>
|
<?= $this->render('show/components/customvars.phtml'); ?>
|
||||||
|
|
||||||
<?php if ($this->service->service_perfdata): ?>
|
<?php if ($this->service->service_perfdata): ?>
|
||||||
<div class="information-container">
|
<div>
|
||||||
|
|
||||||
<div class="head">
|
<div>
|
||||||
<span>Perfdata</span>
|
<span>Perfdata</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
@ -80,8 +79,8 @@ $this->partial(
|
|||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<div class="information-container">
|
<div>
|
||||||
<div class="head">
|
<div>
|
||||||
<span>Flags</span>
|
<span>Flags</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
@ -89,8 +88,8 @@ $this->partial(
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="information-container">
|
<div>
|
||||||
<div class="head">
|
<div>
|
||||||
<span>Properties</span>
|
<span>Properties</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
@ -98,9 +97,9 @@ $this->partial(
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="information-container">
|
<div>
|
||||||
<div class="head">
|
<div>
|
||||||
<span>Commands</span>
|
{{COMMAND_ICON}} <span>Commands</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<?= $this->monitoringCommands($this->service, 'full'); ?>
|
<?= $this->monitoringCommands($this->service, 'full'); ?>
|
||||||
|
@ -1,2 +0,0 @@
|
|||||||
<?= $tabs ?>
|
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user