1: <?php
2: 3: 4: 5: 6: 7: 8: 9:
10:
11: class Whups_Form_Queue_StepThree extends Horde_Form
12: {
13:
14: public function __construct(&$vars, $title = '')
15: {
16: global $whups_driver;
17:
18: parent::__construct($vars, $title);
19:
20: $this->addHidden('', 'id', 'int', true, true);
21: $this->addHidden('', 'group', 'int', false, true);
22: $this->addHidden('', 'queue', 'int', true, true);
23: $this->addHidden('', 'type', 'int', true, true);
24: $this->addHidden('', 'newcomment', 'longtext', false, true);
25:
26: $info = $whups_driver->getQueue($vars->get('queue'));
27: if (!empty($info['versioned'])) {
28: $this->addHidden('', 'version', 'int', true, true);
29: }
30:
31: 32:
33: $type = $vars->get('type');
34: $this->addVariable(_("State"), 'state', 'enum', true, false, null, array($whups_driver->getStates($type)));
35: $this->addVariable(_("Priority"), 'priority', 'enum', true, false, null, array($whups_driver->getPriorities($type)));
36: }
37:
38: }