]> CyberLeo.Net >> Repos - Github/sugarcrm.git/blob - modules/InboundEmail/vardefs.php
Release 6.5.0
[Github/sugarcrm.git] / modules / InboundEmail / vardefs.php
1 <?php
2 if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
3 /*********************************************************************************
4  * SugarCRM Community Edition is a customer relationship management program developed by
5  * SugarCRM, Inc. Copyright (C) 2004-2012 SugarCRM Inc.
6  * 
7  * This program is free software; you can redistribute it and/or modify it under
8  * the terms of the GNU Affero General Public License version 3 as published by the
9  * Free Software Foundation with the addition of the following permission added
10  * to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
11  * IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
12  * OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
13  * 
14  * This program is distributed in the hope that it will be useful, but WITHOUT
15  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
16  * FOR A PARTICULAR PURPOSE.  See the GNU Affero General Public License for more
17  * details.
18  * 
19  * You should have received a copy of the GNU Affero General Public License along with
20  * this program; if not, see http://www.gnu.org/licenses or write to the Free
21  * Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
22  * 02110-1301 USA.
23  * 
24  * You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
25  * SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
26  * 
27  * The interactive user interfaces in modified source and object code versions
28  * of this program must display Appropriate Legal Notices, as required under
29  * Section 5 of the GNU Affero General Public License version 3.
30  * 
31  * In accordance with Section 7(b) of the GNU Affero General Public License version 3,
32  * these Appropriate Legal Notices must retain the display of the "Powered by
33  * SugarCRM" logo. If the display of the logo is not reasonably feasible for
34  * technical reasons, the Appropriate Legal Notices must display the words
35  * "Powered by SugarCRM".
36  ********************************************************************************/
37
38 $dictionary['InboundEmail'] = array('table' => 'inbound_email', 'comment' => 'Inbound email parameters',
39         'fields' => array (
40                 'id' => array (
41                         'name' => 'id',
42                         'vname' => 'LBL_ID',
43                         'type' => 'id',
44                         'dbType' => 'varchar',
45                         'len' => 36,
46                         'required' => true,
47                         'reportable'=>false,
48                         'comment' => 'Unique identifier'
49                 ),
50                 'deleted' => array (
51                         'name' => 'deleted',
52                         'vname' => 'LBL_DELETED',
53                         'type' => 'bool',
54                         'required' => false,
55                         'default' => '0',
56                         'reportable'=>false,
57                         'comment' => 'Record deltion indicator'
58                 ),
59                 'date_entered' => array (
60                         'name' => 'date_entered',
61                         'vname' => 'LBL_DATE_ENTERED',
62                         'type' => 'datetime',
63                         'required' => true,
64                         'comment' => 'Date record created'
65                 ),
66                 'date_modified' => array (
67                         'name' => 'date_modified',
68                         'vname' => 'LBL_DATE_MODIFIED',
69                         'type' => 'datetime',
70                         'required' => true,
71                         'comment' => 'Date record last modified'
72                 ),
73                 'modified_user_id' => array (
74                         'name' => 'modified_user_id',
75                         'rname' => 'user_name',
76                         'id_name' => 'modified_user_id',
77                         'vname' => 'LBL_MODIFIED_BY',
78                         'type' => 'modified_user_name',
79                         'table' => 'users',
80                         'isnull' => false,
81                         'dbType' => 'id',
82                         'reportable'=>true,
83                         'comment' => 'User who last modified record'
84                 ),
85                 'modified_user_id_link' => array (
86                         'name' => 'modified_user_id_link',
87                         'type' => 'link',
88                         'relationship' => 'inbound_email_modified_user_id',
89                         'vname' => 'LBL_MODIFIED_BY_USER',
90                         'link_type' => 'one',
91                         'module' => 'Users',
92                         'bean_name' => 'User',
93                         'source' => 'non-db',
94                 ),
95                 'created_by' => array (
96                         'name' => 'created_by',
97                         'rname' => 'user_name',
98                         'id_name' => 'modified_user_id',
99                         'vname' => 'LBL_ASSIGNED_TO',
100                         'type' => 'assigned_user_name',
101                         'table' => 'users',
102                         'isnull' => false,
103                         'dbType' => 'id',
104                         'comment' => 'User who created record'
105                 ),
106                 'created_by_link' => array (
107                         'name' => 'created_by_link',
108                         'type' => 'link',
109                         'relationship' => 'inbound_email_created_by',
110                         'vname' => 'LBL_CREATED_BY_USER',
111                         'link_type' => 'one',
112                         'module' => 'Users',
113                         'bean_name' => 'User',
114                         'source' => 'non-db',
115                 ),
116                 'name' => array (
117                         'name' => 'name',
118                         'vname' => 'LBL_NAME',
119                         'type' => 'varchar',
120                         'len' => '255',
121                         'required' => false,
122                         'reportable' => false,
123                         'comment' => 'Name given to the inbound email mailbox'
124                 ),
125                 'status' => array (
126                         'name' => 'status',
127                         'vname' => 'LBL_STATUS',
128                         'type' => 'varchar',
129                         'len' => 100,
130                         'default' => 'Active',
131                         'required' => true,
132                         'reportable' => false,
133                         'comment' => 'Status of the inbound email mailbox (ex: Active or Inactive)'
134                 ),
135                 'server_url' => array (
136                         'name' => 'server_url',
137                         'vname' => 'LBL_SERVER_URL',
138                         'type' => 'varchar',
139                         'len' => '100',
140                         'required' => true,
141                         'reportable' => false,
142                         'comment' => 'Mail server URL',
143                         'importable' => 'required',
144                 ),
145                 'email_user' => array (
146                         'name' => 'email_user',
147                         'vname' => 'LBL_LOGIN',
148                         'type' => 'varchar',
149                         'len' => '100',
150                         'required' => true,
151                         'reportable' => false,
152                         'comment' => 'User name allowed access to mail server'
153                 ),
154                 'email_password' => array (
155                         'name' => 'email_password',
156                         'vname' => 'LBL_PASSWORD',
157                         'type' => 'varchar',
158                         'len' => '100',
159                         'required' => true,
160                         'reportable' => false,
161                         'comment' => 'Password of user identified by email_user'
162                 ),
163                 'port' => array (
164                         'name' => 'port',
165                         'vname' => 'LBL_SERVER_TYPE',
166                         'type' => 'int',
167                         'len' => '5',
168                         'required' => true,
169                         'reportable' => false,
170                         'validation' => array ('type' => 'range', 'min' => '110', 'max' => '65535'),
171                         'comment' => 'Port used to access mail server'
172                 ),
173                 'service' => array (
174                         'name' => 'service',
175                         'vname' => 'LBL_SERVICE',
176                         'type' => 'varchar',
177                         'len' => '50',
178                         'required' => true,
179                         'reportable' => false,
180                         'comment' => '',
181                         'importable' => 'required',
182                 ),
183                 'mailbox' => array (
184                         'name' => 'mailbox',
185                         'vname' => 'LBL_MAILBOX',
186                         'type' => 'text',
187                         'required' => true,
188                         'reportable' => false,
189                         'comment' => ''
190                 ),
191                 'delete_seen' => array (
192                         'name' => 'delete_seen',
193                         'vname' => 'LBL_DELETE_SEEN',
194                         'type' => 'bool',
195                         'default' => '0',
196                         'reportable' => false,
197                         'massupdate' => '',
198                         'comment' => 'Delete email from server once read (seen)'
199                 ),
200                 'mailbox_type' => array (
201                         'name' => 'mailbox_type',
202                         'vname' => 'LBL_MAILBOX_TYPE',
203                         'type' => 'varchar',
204                         'len' => '10',
205                         'reportable' => false,
206                         'comment' => ''
207                 ),
208                 'template_id' => array (
209                         'name' => 'template_id',
210                         'vname' => 'LBL_AUTOREPLY',
211                         'type' => 'id',
212                         'len' => '36',
213                         'reportable' => false,
214                         'comment' => 'Template used for auto-reply'
215                 ),
216                 'stored_options' => array (
217                         'name' => 'stored_options',
218                         'vname' => 'LBL_STORED_OPTIONS',
219                         'type' => 'text',
220                         'reportable' => false,
221                         'comment' => ''
222                 ),
223                 'group_id' => array (
224                         'name' => 'group_id',
225                         'vname' => 'LBL_GROUP_ID',
226                         'type' => 'id',
227                         'reportable' => false,
228                         'comment' => 'Group ID (unused)'
229                 ),
230                 'is_personal' => array (
231                         'name' => 'is_personal',
232                         'vname' => 'LBL_IS_PERSONAL',
233                         'type' => 'bool',
234                         'required' => true,
235                         'default' => '0',
236                         'reportable'=>false,
237                         'massupdate' => '',
238                         'comment' => 'Personal account flag'
239                 ),
240                 'groupfolder_id' => array (
241                         'name' => 'groupfolder_id',
242                         'vname' => 'LBL_GROUPFOLDER_ID',
243                         'type' => 'id',
244                         'required' => false,
245                         'reportable'=>false,
246                         'comment' => 'Unique identifier'
247                 ),
248         ), /* end fields() */
249         'indices' => array (
250                 array(
251                         'name' =>'inbound_emailpk',
252                         'type' =>'primary',
253                         'fields' => array(
254                                 'id'
255                         )
256                 ),
257         ), /* end indices */
258         'relationships' => array (
259                 'inbound_email_created_by' => array(
260                         'lhs_module'=> 'Users',
261                         'lhs_table' => 'users',
262                         'lhs_key' => 'id',
263                         'rhs_module'=> 'InboundEmail',
264                         'rhs_table'=> 'inbound_email',
265                         'rhs_key' => 'created_by',
266                         'relationship_type' => 'one-to-one'
267                 ),
268                 'inbound_email_modified_user_id' => array (
269                         'lhs_module' => 'Users',
270                         'lhs_table' => 'users',
271                         'lhs_key' => 'id',
272                         'rhs_module'=> 'InboundEmail',
273                         'rhs_table'=> 'inbound_email',
274                         'rhs_key' => 'modified_user_id',
275                         'relationship_type' => 'one-to-one'
276                 ),
277         ), /* end relationships */
278 );
279
280
281 VardefManager::createVardef('InboundEmail','InboundEmail', array(
282 ));
283
284 ?>