1+ <?php
2+
3+ /*
4+ Form Definition
5+
6+ Tabledefinition
7+
8+ Datatypes:
9+ - INTEGER (Forces the input to Int)
10+ - DOUBLE
11+ - CURRENCY (Formats the values to currency notation)
12+ - VARCHAR (no format check, maxlength: 255)
13+ - TEXT (no format check)
14+ - DATE (Dateformat, automatic conversion to timestamps)
15+
16+ Formtype:
17+ - TEXT (Textfield)
18+ - TEXTAREA (Textarea)
19+ - PASSWORD (Password textfield, input is not shown when edited)
20+ - SELECT (Select option field)
21+ - RADIO
22+ - CHECKBOX
23+ - CHECKBOXARRAY
24+ - FILE
25+
26+ VALUE:
27+ - Wert oder Array
28+
29+ Hint:
30+ The ID field of the database table is not part of the datafield definition.
31+ The ID field must be always auto incement (int or bigint).
32+
33+
34+ */
35+
36+ $ form ["title " ] = "Email filter " ;
37+ $ form ["description " ] = "" ;
38+ $ form ["name " ] = "mail_user_filter " ;
39+ $ form ["action " ] = "mail_user_filter_edit.php " ;
40+ $ form ["db_table " ] = "mail_user_filter " ;
41+ $ form ["db_table_idx " ] = "filter_id " ;
42+ $ form ["db_history " ] = "yes " ;
43+ $ form ["tab_default " ] = "filter " ;
44+ $ form ["list_default " ] = "mail_user_filter_list.php " ;
45+ $ form ["auth " ] = 'yes ' ; // yes / no
46+
47+ $ form ["auth_preset " ]["userid " ] = 0 ; // 0 = id of the user, > 0 id must match with id of current user
48+ $ form ["auth_preset " ]["groupid " ] = 0 ; // 0 = default groupid of the user, > 0 id must match with groupid of current user
49+ $ form ["auth_preset " ]["perm_user " ] = 'riud ' ; //r = read, i = insert, u = update, d = delete
50+ $ form ["auth_preset " ]["perm_group " ] = 'riud ' ; //r = read, i = insert, u = update, d = delete
51+ $ form ["auth_preset " ]["perm_other " ] = '' ; //r = read, i = insert, u = update, d = delete
52+
53+ $ form ["tabs " ]['filter ' ] = array (
54+ 'title ' => "Filter " ,
55+ 'width ' => 100 ,
56+ 'template ' => "templates/mail_user_filter_edit.htm " ,
57+ 'fields ' => array (
58+ ##################################
59+ # Begin Datatable fields
60+ ##################################
61+ 'mailuser_id ' => array (
62+ 'datatype ' => 'INTEGER ' ,
63+ 'formtype ' => 'TEXT ' ,
64+ 'default ' => @intval ($ _REQUEST ["mailuser_id " ]),
65+ 'value ' => '' ,
66+ 'width ' => '30 ' ,
67+ 'maxlength ' => '255 '
68+ ),
69+ 'rulename ' => array (
70+ 'datatype ' => 'VARCHAR ' ,
71+ 'formtype ' => 'TEXT ' ,
72+ 'validators ' => array ( 0 => array ( 'type ' => 'NOTEMPTY ' ,
73+ 'errmsg ' => 'rulename_error_empty ' ),
74+ ),
75+ 'default ' => '' ,
76+ 'value ' => '' ,
77+ 'width ' => '30 ' ,
78+ 'maxlength ' => '255 '
79+ ),
80+ 'source ' => array (
81+ 'datatype ' => 'VARCHAR ' ,
82+ 'formtype ' => 'SELECT ' ,
83+ 'default ' => '' ,
84+ 'value ' => array ('Subject ' => 'Subject ' ,'From ' =>'From ' ,'To ' =>'To ' ,'Header ' =>'Custom Header ' )
85+ ),
86+ 'op ' => array (
87+ 'datatype ' => 'VARCHAR ' ,
88+ 'formtype ' => 'SELECT ' ,
89+ 'default ' => '' ,
90+ 'value ' => array ('contains ' =>'Contains ' ,'is ' => 'Is ' ,'begins ' =>'Begins with ' ,'ends ' =>'Ends with ' )
91+ ),
92+ 'searchterm ' => array (
93+ 'datatype ' => 'VARCHAR ' ,
94+ 'formtype ' => 'TEXT ' ,
95+ 'validators ' => array ( 0 => array ( 'type ' => 'NOTEMPTY ' ,
96+ 'errmsg ' => 'searchterm_is_empty ' ),
97+ ),
98+ 'default ' => '' ,
99+ 'value ' => '' ,
100+ 'width ' => '30 ' ,
101+ 'maxlength ' => '255 '
102+ ),
103+ 'action ' => array (
104+ 'datatype ' => 'VARCHAR ' ,
105+ 'formtype ' => 'SELECT ' ,
106+ 'default ' => '' ,
107+ 'value ' => array ('move ' => 'Move to ' ,'delete ' =>'Delete ' )
108+ ),
109+ 'target ' => array (
110+ 'datatype ' => 'VARCHAR ' ,
111+ 'formtype ' => 'TEXT ' ,
112+ 'default ' => '' ,
113+ 'value ' => '' ,
114+ 'width ' => '30 ' ,
115+ 'maxlength ' => '255 '
116+ ),
117+ 'active ' => array (
118+ 'datatype ' => 'VARCHAR ' ,
119+ 'formtype ' => 'CHECKBOX ' ,
120+ 'default ' => 'y ' ,
121+ 'value ' => array (0 => 'n ' ,1 => 'y ' )
122+ ),
123+ ##################################
124+ # ENDE Datatable fields
125+ ##################################
126+ )
127+ );
128+
129+
130+
131+ ?>
0 commit comments