summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xapplication/controllers/EventController.php3
-rwxr-xr-xapplication/forms/EventEdit.php5
2 files changed, 6 insertions, 2 deletions
diff --git a/application/controllers/EventController.php b/application/controllers/EventController.php
index db271ed..b891d47 100755
--- a/application/controllers/EventController.php
+++ b/application/controllers/EventController.php
@@ -576,6 +576,9 @@ class EventController extends Zend_Controller_Action
}
$this->getRequest()->setParam('participants', $event->getParticipants());
$this->getRequest()->setParam('category', $event->getCategory());
+ $eventCategory = new Application_Model_Eventcategory();
+ $this->eventcategoryMapper->find($event->getCategory(), $eventCategory);
+ $this->getRequest()->setParam('categoryLabel', $eventCategory->getTitle());
$this->getRequest()->setParam('note', $event->getNote());
$this->getRequest()->setParam('pbs_poolID', $event->getPbs_poolID());
$this->getRequest()->setParam('pbs_bootosID', $event->getPbs_bootosID());
diff --git a/application/forms/EventEdit.php b/application/forms/EventEdit.php
index c223527..6866dd2 100755
--- a/application/forms/EventEdit.php
+++ b/application/forms/EventEdit.php
@@ -113,6 +113,7 @@ class Application_Form_EventEdit extends Zend_Form
$eventcategoryfield->setRegisterInArrayValidator(false);
$eventcategoryfield->setValue($this->params['category']);
+ $eventcategoryfield->setAttrib("disabled", true);
$eventcategoryfield->setAttrib('onchange', "editeventcategoryfieldChanged('category');");
$this->addElement($eventcategoryfield);
@@ -138,7 +139,7 @@ class Application_Form_EventEdit extends Zend_Form
'label' => 'Start:',
'value' => date ('m/d/Y h:i a', strtotime( $this->params['start'])),
));
-
+
if(isset($this->params['end'])) {
$this->addElement('text', 'end', array(
'filters' => array('StringTrim'),
@@ -152,7 +153,7 @@ class Application_Form_EventEdit extends Zend_Form
'value' => date ('m/d/Y h:i a', strtotime( $this->params['end'])),
));
$this->getElement('end')->addPrefixPath('Poolctrl_Validate', 'Poolctrl/Validator/', 'validate');
- } else {
+ } else if($this->params['categoryLabel'] != "Boot" && $this->params['categoryLabel'] != "Shutdown") {
$this->addElement('text', 'end', array(
'filters' => array('StringTrim'),
'validators' => array(