1: <?php
2: /**
3: * Form for adding a new query branch
4: *
5: * Copyright 2001-2002 Robert E. Coyle <robertecoyle@hotmail.com>
6: * Copyright 2001-2012 Horde LLC (http://www.horde.org/)
7: *
8: * See the enclosed file LICENSE for license information (BSD). If you
9: * did not receive this file, see http://www.horde.org/licenses/bsdl.php.
10: *
11: * @author Robert E. Coyle <robertecoyle@hotmail.com>
12: * @author Jan Schneider <jan@horde.org>
13: * @package Whups
14: */
15: class Whups_Form_InsertBranch extends Horde_Form
16: {
17: public function __construct(&$vars)
18: {
19: parent::__construct($vars, _("Insert Branch"));
20:
21: $branchtypes = array(
22: Whups_Query::TYPE_AND => _("And"),
23: Whups_Query::TYPE_OR => _("Or"),
24: Whups_Query::TYPE_NOT => _("Not"));
25:
26: $this->addHidden(null, 'path', 'text', false, true);
27: $this->addVariable(
28: _("Branch Type"), 'type', 'enum', true, false, null, array($branchtypes));
29: }
30:
31: }
32: