summaryrefslogtreecommitdiffstats
path: root/application/modules/user/forms
diff options
context:
space:
mode:
authormichael pereira2011-04-21 15:55:59 +0200
committermichael pereira2011-04-21 15:55:59 +0200
commit4d141b993337331b61945cc02c43cb15d89714e9 (patch)
tree38e42801af6fee086771eca48ff44d2b668f1986 /application/modules/user/forms
parentconfig fix (diff)
downloadpbs2-4d141b993337331b61945cc02c43cb15d89714e9.tar.gz
pbs2-4d141b993337331b61945cc02c43cb15d89714e9.tar.xz
pbs2-4d141b993337331b61945cc02c43cb15d89714e9.zip
Preboot gefixt
Diffstat (limited to 'application/modules/user/forms')
-rw-r--r--application/modules/user/forms/Bootos.php33
-rw-r--r--application/modules/user/forms/Preboot.php11
2 files changed, 9 insertions, 35 deletions
diff --git a/application/modules/user/forms/Bootos.php b/application/modules/user/forms/Bootos.php
index 1dd0d07..d9cd24f 100644
--- a/application/modules/user/forms/Bootos.php
+++ b/application/modules/user/forms/Bootos.php
@@ -63,39 +63,6 @@ class user_Form_Bootos extends Zend_Form
'label' => 'Description:',
));
- $this->addElement('text', 'path_init', array(
- 'filters' => array('StringTrim'),
- 'validators' => array(
- array('StringLength', false, array(0, 250)),
- ),
- 'required' => false,
- 'size' => 50,
- 'readOnly' => $meta,
- 'label' => 'Init-Path:',
- ));
-
- $this->addElement('text', 'path_kernel', array(
- 'filters' => array('StringTrim'),
- 'validators' => array(
- array('StringLength', false, array(0, 250)),
- ),
- 'required' => false,
- 'size' => 50,
- 'readOnly' => $meta,
- 'label' => 'Kernel-Path:',
- ));
-
- $this->addElement('text', 'path_config', array(
- 'filters' => array('StringTrim'),
- 'validators' => array(
- array('StringLength', false, array(0, 250)),
- ),
- 'required' => false,
- 'size' => 50,
- 'readOnly' => $meta,
- 'label' => 'Config-Path:',
- ));
-
$this->addElement('textarea', 'defaultkcl', array(
'filters' => array('StringTrim'),
'validators' => array(
diff --git a/application/modules/user/forms/Preboot.php b/application/modules/user/forms/Preboot.php
index 634b2b7..54dc216 100644
--- a/application/modules/user/forms/Preboot.php
+++ b/application/modules/user/forms/Preboot.php
@@ -33,6 +33,12 @@ class user_Form_Preboot extends Zend_Form
else
$meta = null;
+ if($this->action == 'editpreboot')
+ $filereq = false;
+ else
+ $filereq = true;
+
+
$this->addElement('text', 'title', array(
'filters' => array('StringTrim'),
'validators' => array(
@@ -45,7 +51,7 @@ class user_Form_Preboot extends Zend_Form
$this->addElement('textarea', 'description', array(
'filters' => array('StringTrim'),
'validators' => array(
- array('StringLength', false, array(0, 50)),
+ array('StringLength', false, array(0, 140)),
),
'required' => false,
'rows' => 5,
@@ -54,7 +60,8 @@ class user_Form_Preboot extends Zend_Form
));
$this->addElement('file', 'preboot', array(
- 'required' => true,
+ 'validators' => array(array('Extension', false, array('zip'))),
+ 'required' => $filereq,
'readOnly' => $meta,
'label' => 'Preboot:',
));