1: <?php
2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12:
13:
14: class Whups_Form_Admin_EditVersionStepOne extends Horde_Form
15: {
16:
17: public function __construct(&$vars)
18: {
19: global $whups_driver;
20:
21: parent::__construct($vars, _("Edit or Delete Versions"));
22: $this->setButtons(array(_("Edit Version"), _("Delete Version")));
23:
24: $versions = $whups_driver->getVersions($vars->get('queue'), true);
25: if ($versions) {
26: $vtype = 'enum';
27: $type_params = array($versions);
28: } else {
29: $vtype = 'invalid';
30: $type_params = array(_("There are no versions to edit"));
31: }
32:
33: $this->addHidden('', 'queue', 'int', true, true);
34: $this->addVariable(_("Version Name"), 'version', $vtype, true, false, null, $type_params);
35: }
36:
37: }
38: