1: <?php
2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12:
13:
14: class Whups_Form_Admin_DeleteState extends Horde_Form
15: {
16: public function __construct(&$vars)
17: {
18: parent::__construct($vars, _("Delete State Confirmation"));
19:
20: $state = $vars->get('state');
21: $info = $GLOBALS['whups_driver']->getState($state);
22:
23: $this->addHidden('', 'type', 'int', true, true);
24: $this->addHidden('', 'state', 'int', true, true);
25:
26: $sname = &$this->addVariable(_("State Name"), 'name', 'text', false, true);
27: $sname->setDefault($info['name']);
28:
29: $sdesc = &$this->addVariable(_("State Description"), 'description', 'text', false, true);
30: $sdesc->setDefault($info['description']);
31:
32: $yesno = array(array(0 => _("No"), 1 => _("Yes")));
33: $this->addVariable(_("Really delete this state? This may cause data problems!"), 'yesno', 'enum', true, false, null, $yesno);
34: }
35:
36: }
37: