CheckNowCommandForm: Ignore objects which have no active checks
refs #3665
This commit is contained in:
parent
164555760b
commit
c2fc370273
|
@ -58,6 +58,12 @@ class CheckNowCommandForm extends ObjectsCommandForm
|
|||
{
|
||||
foreach ($this->objects as $object) {
|
||||
/** @var \Icinga\Module\Monitoring\Object\MonitoredObject $object */
|
||||
if (! $object->active_checks_enabled
|
||||
&& ! $this->Auth()->hasPermission('monitoring/command/schedule-check')
|
||||
) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if ($object->getType() === $object::TYPE_HOST) {
|
||||
$check = new ScheduleHostCheckCommand();
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue