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-2011 SugarCRM Inc.
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.
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
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
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.
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.
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 ********************************************************************************/
38 $dictionary['Meeting'] = array('table' => 'meetings',
39 'unified_search' => true, 'unified_search_default_enabled' => true,
40 'comment' => 'Meeting activities'
45 'vname' => 'LBL_SUBJECT',
48 'dbType' => 'varchar',
49 'unified_search' => true,
51 'comment' => 'Meeting name',
52 'importable' => 'required',
54 'accept_status' => array (
55 'name' => 'accept_status',
56 'vname' => 'LBL_SUBJECT',
58 'dbType' => 'varchar',
63 'set_accept_links' => array (
64 'name' => 'accept_status',
65 'vname' => 'LBL_SUBJECT',
67 'dbType' => 'varchar',
74 'vname' => 'LBL_LOCATION',
77 'comment' => 'Meeting location'
82 'vname' => 'LBL_PASSWORD',
85 'comment' => 'Meeting password',
94 'comment' => 'Join URL',
96 'reportable' => false,
100 'name' => 'host_url',
101 'vname' => 'LBL_URL',
104 'comment' => 'Host URL',
106 'reportable' => false,
110 'name' => 'displayed_url',
111 'vname' => 'LBL_URL',
114 'comment' => 'Meeting URL',
120 'vname' => 'LBL_CREATOR',
123 'comment' => 'Meeting creator',
128 'name' => 'external_id',
129 'vname' => 'LBL_EXTERNALID',
132 'comment' => 'Meeting ID for external app API',
137 'name' => 'duration_hours',
138 'vname' => 'LBL_DURATION_HOURS',
141 'comment' => 'Duration (hours)',
142 'importable' => 'required',
145 'duration_minutes' =>
147 'name' => 'duration_minutes',
148 'vname' => 'LBL_DURATION_MINUTES',
150 'group'=>'duration_hours',
151 'function' => array('name'=>'getDurationMinutesOptions', 'returns'=>'html', 'include'=>'modules/Calls/CallHelper.php'),
153 'comment' => 'Duration (minutes)'
157 'name' => 'date_start',
158 'vname' => 'LBL_DATE',
159 'type' => 'datetimecombo',
160 'dbType' => 'datetime',
161 'comment' => 'Date of start of meeting',
162 'importable' => 'required',
164 'enable_range_search' => true,
169 'name' => 'date_end',
170 'vname' => 'LBL_DATE_END',
171 'type' => 'datetime',
173 'comment' => 'Date meeting ends',
174 'enable_range_search' => true,
178 'name' => 'parent_type',
179 'vname'=>'LBL_LIST_RELATED_TO',
180 'type' =>'parent_type',
181 'dbType' => 'varchar',
182 'group'=>'parent_name',
184 'comment' => 'Module meeting is associated with'
189 'vname' => 'LBL_STATUS',
192 'options' => 'meeting_status_dom',
193 'comment' => 'Meeting status (ex: Planned, Held, Not held)',
194 'default' => 'Planned',
199 'vname' => 'LBL_TYPE',
202 'function' => 'getMeetingsExternalApiDropDown',
203 'comment' => 'Meeting type (ex: WebEx, Other)',
204 'options' => 'eapm_list',
205 'default' => 'Sugar',
206 'massupdate' => false,
209 // Bug 24170 - Added only to allow the sidequickcreate form to work correctly
212 'name' => 'direction',
213 'vname' => 'LBL_DIRECTION',
216 'options' => 'call_direction_dom',
217 'comment' => 'Indicates whether call is inbound or outbound',
218 'source' => 'non-db',
219 'importable' => 'false',
226 'name' => 'parent_id',
227 'vname'=>'LBL_LIST_RELATED_TO',
229 'group'=>'parent_name',
231 'comment' => 'ID of item indicated by parent_type'
233 'reminder_checked'=>array(
234 'name' => 'reminder_checked',
235 'vname' => 'LBL_REMINDER',
237 'source' => 'non-db',
238 'comment' => 'checkbox indicating whether or not the reminder value is set (Meta-data only)',
244 'name' => 'reminder_time',
245 'vname' => 'LBL_REMINDER_TIME',
247 'function' => array('name'=>'getReminderTime', 'returns'=>'html', 'include'=>'modules/Calls/CallHelper.php', 'onListView'=>true ),
248 'reportable' => false,
250 'comment' => 'Specifies when a reminder alert should be issued; -1 means no alert; otherwise the number of seconds prior to the start'
254 'name' => 'outlook_id',
255 'vname' => 'LBL_OUTLOOK_ID',
258 'reportable' => false,
259 'comment' => 'When the Sugar Plug-in for Microsoft Outlook syncs an Outlook appointment, this is the Outlook appointment item ID'
264 'name' => 'contact_name',
265 'rname' => 'last_name',
266 'db_concat_fields'=> array(0=>'first_name', 1=>'last_name'),
267 'id_name' => 'contact_id',
268 'massupdate' => false,
269 'vname' => 'LBL_CONTACT_NAME',
272 'table' => 'contacts',
274 'module' => 'Contacts',
275 'join_name' => 'contacts',
276 'dbType' => 'varchar',
284 'name' => 'contacts',
286 'relationship' => 'meetings_contacts',
288 'vname'=>'LBL_CONTACTS',
292 'name'=> 'parent_name',
293 'parent_type'=>'record_type_display' ,
294 'type_name'=>'parent_type',
295 'id_name'=>'parent_id',
296 'vname'=>'LBL_LIST_RELATED_TO',
298 'group'=>'parent_name',
300 'options'=> 'parent_type_display',
306 'relationship' => 'meetings_users',
308 'vname'=>'LBL_USERS',
312 'name' => 'accounts',
314 'relationship' => 'account_meetings',
316 'vname'=>'LBL_ACCOUNT',
322 'relationship' => 'meetings_leads',
324 'vname'=>'LBL_LEADS',
328 'name' => 'opportunity',
330 'relationship' => 'opportunity_meetings',
332 'vname'=>'LBL_OPPORTUNITY',
338 'relationship' => 'case_meetings',
346 'relationship' => 'meetings_notes',
350 'vname'=>'LBL_NOTES',
352 'contact_id' => array(
353 'name' => 'contact_id',
355 'source' => 'non-db',
358 'relationships' => array (
359 'meetings_assigned_user' =>
360 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
361 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'assigned_user_id',
362 'relationship_type'=>'one-to-many')
364 ,'meetings_modified_user' =>
365 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
366 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'modified_user_id',
367 'relationship_type'=>'one-to-many')
369 ,'meetings_created_by' =>
370 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
371 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'created_by',
372 'relationship_type'=>'one-to-many')
374 ,'meetings_notes' => array('lhs_module'=> 'Meetings', 'lhs_table'=> 'meetings', 'lhs_key' => 'id',
375 'rhs_module'=> 'Notes', 'rhs_table'=> 'notes', 'rhs_key' => 'parent_id',
376 'relationship_type'=>'one-to-many', 'relationship_role_column'=>'parent_type',
377 'relationship_role_column_value'=>'Meetings')
380 , 'indices' => array (
381 array('name' =>'idx_mtg_name', 'type'=>'index', 'fields'=>array('name')),
382 array('name' =>'idx_meet_par_del', 'type'=>'index', 'fields'=>array('parent_id','parent_type','deleted')),
383 array('name' => 'idx_meet_stat_del', 'type' => 'index', 'fields'=> array('assigned_user_id', 'status', 'deleted')),
386 //This enables optimistic locking for Saves From EditView
387 ,'optimistic_locking'=>true,
390 VardefManager::createVardef('Meetings','Meeting', array('default', 'assignable',