diff --git a/modules/monitoring/application/forms/Command/ScheduleDowntimeForm.php b/modules/monitoring/application/forms/Command/ScheduleDowntimeForm.php index a07777778..d690091db 100644 --- a/modules/monitoring/application/forms/Command/ScheduleDowntimeForm.php +++ b/modules/monitoring/application/forms/Command/ScheduleDowntimeForm.php @@ -88,7 +88,7 @@ class ScheduleDowntimeForm extends WithChildrenCommandForm $cfg = $this->getConfiguration(); $preferences = $this->getUserPreferences(); - $downtimes = Backend::getInstance($this->getRequest()->getParam('backend'))->select() + $downtimes = Backend::createBackend($this->getRequest()->getParam('backend'))->select() ->from( 'downtime', array( diff --git a/modules/monitoring/application/views/helpers/CommandForm.php b/modules/monitoring/application/views/helpers/CommandForm.php index d93f7eeff..66803128c 100644 --- a/modules/monitoring/application/views/helpers/CommandForm.php +++ b/modules/monitoring/application/views/helpers/CommandForm.php @@ -72,7 +72,6 @@ class Zend_View_Helper_CommandForm extends Zend_View_Helper_Abstract public function labelSubmitForm($submitLabel, $submitTitle, $cls, $commandName, array $arguments = array()) { $form = $this->simpleForm($commandName, $arguments); - $button = new Zend_Form_Element_Button( array( 'name' => 'btn_submit', diff --git a/modules/monitoring/application/views/scripts/show/components/comments.phtml b/modules/monitoring/application/views/scripts/show/components/comments.phtml index fff7bd1f9..aa0d9a02f 100644 --- a/modules/monitoring/application/views/scripts/show/components/comments.phtml +++ b/modules/monitoring/application/views/scripts/show/components/comments.phtml @@ -1,3 +1,7 @@ +getHelper('CommandForm'); +?>
= $this->pluginOutput($object->output); ?>
- + + = $cf->labelSubmitForm( + 'Recheck', + 'Reschedule next check immediately', + 'btn-cta ' . (($objectState > 0) ? 'btn-half-right' : 'btn-wide'), + 'reschedulenextcheck', + array( + 'host' => $this->object->host_name, + 'service' => $this->object->service_description, + 'checktime' => time(), + 'forcecheck' => '1' + ) + ) ?>