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.
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, 'full_text_search' => true, 'unified_search_default_enabled' => true,
40 'comment' => 'Meeting activities'
45 'vname' => 'LBL_SUBJECT',
48 'dbType' => 'varchar',
49 'unified_search' => true,
50 'full_text_search' => array('boost' => 3),
52 'comment' => 'Meeting name',
53 'importable' => 'required',
55 'accept_status' => array (
56 'name' => 'accept_status',
57 'vname' => 'LBL_ACCEPT_STATUS',
59 'dbType' => 'varchar',
64 'set_accept_links' => array (
65 'name' => 'accept_status',
66 'vname' => 'LBL_ACCEPT_LINK',
68 'dbType' => 'varchar',
75 'vname' => 'LBL_LOCATION',
78 'comment' => 'Meeting location'
83 'vname' => 'LBL_PASSWORD',
86 'comment' => 'Meeting password',
95 'comment' => 'Join URL',
97 'reportable' => false,
101 'name' => 'host_url',
102 'vname' => 'LBL_HOST_URL',
105 'comment' => 'Host URL',
107 'reportable' => false,
111 'name' => 'displayed_url',
112 'vname' => 'LBL_DISPLAYED_URL',
115 'comment' => 'Meeting URL',
121 'vname' => 'LBL_CREATOR',
124 'comment' => 'Meeting creator',
129 'name' => 'external_id',
130 'vname' => 'LBL_EXTERNALID',
133 'comment' => 'Meeting ID for external app API',
138 'name' => 'duration_hours',
139 'vname' => 'LBL_DURATION_HOURS',
143 'comment' => 'Duration (hours)',
144 'importable' => 'required',
148 'duration_minutes' =>
150 'name' => 'duration_minutes',
151 'vname' => 'LBL_DURATION_MINUTES',
155 'comment' => 'Duration (minutes)',
160 'name' => 'date_start',
161 'vname' => 'LBL_DATE',
162 'type' => 'datetimecombo',
163 'dbType' => 'datetime',
164 'comment' => 'Date of start of meeting',
165 'importable' => 'required',
167 'enable_range_search' => true,
168 'options' => 'date_range_search_dom',
169 'validation' => array('type' => 'isbefore', 'compareto' => 'date_end', 'blank' => false),
174 'name' => 'date_end',
175 'vname' => 'LBL_DATE_END',
176 'type' => 'datetimecombo',
177 'dbType' => 'datetime',
179 'comment' => 'Date meeting ends',
180 'enable_range_search' => true,
181 'options' => 'date_range_search_dom',
185 'name' => 'parent_type',
186 'vname'=>'LBL_PARENT_TYPE',
187 'type' =>'parent_type',
188 'dbType' => 'varchar',
189 'group'=>'parent_name',
190 'options'=> 'parent_type_display',
192 'comment' => 'Module meeting is associated with',
193 'studio' => array('searchview'=>false),
198 'vname' => 'LBL_STATUS',
201 'options' => 'meeting_status_dom',
202 'comment' => 'Meeting status (ex: Planned, Held, Not held)',
203 'default' => 'Planned',
208 'vname' => 'LBL_TYPE',
211 'function' => 'getMeetingsExternalApiDropDown',
212 'comment' => 'Meeting type (ex: WebEx, Other)',
213 'options' => 'eapm_list',
214 'default' => 'Sugar',
215 'massupdate' => false,
218 // Bug 24170 - Added only to allow the sidequickcreate form to work correctly
221 'name' => 'direction',
222 'vname' => 'LBL_DIRECTION',
225 'options' => 'call_direction_dom',
226 'comment' => 'Indicates whether call is inbound or outbound',
227 'source' => 'non-db',
228 'importable' => 'false',
235 'name' => 'parent_id',
236 'vname'=>'LBL_PARENT_ID',
238 'group'=>'parent_name',
240 'comment' => 'ID of item indicated by parent_type',
241 'studio' => array('searchview'=>false),
243 'reminder_checked' => array(
244 'name' => 'reminder_checked',
245 'vname' => 'LBL_REMINDER',
247 'source' => 'non-db',
248 'comment' => 'checkbox indicating whether or not the reminder value is set (Meta-data only)',
249 'massupdate' => false,
253 'name' => 'reminder_time',
254 'vname' => 'LBL_REMINDER_TIME',
257 'options' => 'reminder_time_options',
258 'reportable' => false,
259 'massupdate' => false,
261 'comment' => 'Specifies when a reminder alert should be issued; -1 means no alert; otherwise the number of seconds prior to the start'
263 'email_reminder_checked' => array(
264 'name' => 'email_reminder_checked',
265 'vname' => 'LBL_EMAIL_REMINDER',
267 'source' => 'non-db',
268 'comment' => 'checkbox indicating whether or not the email reminder value is set (Meta-data only)',
269 'massupdate' => false,
271 'email_reminder_time' =>
273 'name' => 'email_reminder_time',
274 'vname' => 'LBL_EMAIL_REMINDER_TIME',
277 'options' => 'reminder_time_options',
278 'reportable' => false,
279 'massupdate' => false,
281 'comment' => 'Specifies when a email reminder alert should be issued; -1 means no alert; otherwise the number of seconds prior to the start'
283 'email_reminder_sent' => array(
284 'name' => 'email_reminder_sent',
285 'vname' => 'LBL_EMAIL_REMINDER_SENT',
288 'comment' => 'Whether email reminder is already sent',
290 'massupdate'=> false,
294 'name' => 'outlook_id',
295 'vname' => 'LBL_OUTLOOK_ID',
298 'reportable' => false,
299 'comment' => 'When the Sugar Plug-in for Microsoft Outlook syncs an Outlook appointment, this is the Outlook appointment item ID'
303 'name' => 'sequence',
304 'vname' => 'LBL_SEQUENCE',
307 'reportable' => false,
309 'comment' => 'Meeting update sequence for meetings as per iCalendar standards',
314 'name' => 'contact_name',
315 'rname' => 'last_name',
316 'db_concat_fields'=> array(0=>'first_name', 1=>'last_name'),
317 'id_name' => 'contact_id',
318 'massupdate' => false,
319 'vname' => 'LBL_CONTACT_NAME',
322 'table' => 'contacts',
324 'module' => 'Contacts',
325 'join_name' => 'contacts',
326 'dbType' => 'varchar',
334 'name' => 'contacts',
336 'relationship' => 'meetings_contacts',
338 'vname'=>'LBL_CONTACTS',
342 'name'=> 'parent_name',
343 'parent_type'=>'record_type_display' ,
344 'type_name'=>'parent_type',
345 'id_name'=>'parent_id',
346 'vname'=>'LBL_LIST_RELATED_TO',
348 'group'=>'parent_name',
350 'options'=> 'parent_type_display',
356 'relationship' => 'meetings_users',
358 'vname'=>'LBL_USERS',
362 'name' => 'accounts',
364 'relationship' => 'account_meetings',
366 'vname'=>'LBL_ACCOUNT',
372 'relationship' => 'meetings_leads',
374 'vname'=>'LBL_LEADS',
378 'name' => 'opportunity',
380 'relationship' => 'opportunity_meetings',
382 'vname'=>'LBL_OPPORTUNITY',
388 'relationship' => 'case_meetings',
396 'relationship' => 'meetings_notes',
400 'vname'=>'LBL_NOTES',
402 'contact_id' => array(
403 'name' => 'contact_id',
405 'source' => 'non-db',
409 'name' => 'repeat_type',
410 'vname' => 'LBL_REPEAT_TYPE',
413 'options' => 'repeat_type_dom',
414 'comment' => 'Type of recurrence',
415 'importable' => 'false',
416 'massupdate' => false,
417 'reportable' => false,
422 'name' => 'repeat_interval',
423 'vname' => 'LBL_REPEAT_INTERVAL',
427 'comment' => 'Interval of recurrence',
428 'importable' => 'false',
429 'massupdate' => false,
430 'reportable' => false,
435 'name' => 'repeat_dow',
436 'vname' => 'LBL_REPEAT_DOW',
439 'comment' => 'Days of week in recurrence',
440 'importable' => 'false',
441 'massupdate' => false,
442 'reportable' => false,
447 'name' => 'repeat_until',
448 'vname' => 'LBL_REPEAT_UNTIL',
450 'comment' => 'Repeat until specified date',
451 'importable' => 'false',
452 'massupdate' => false,
453 'reportable' => false,
458 'name' => 'repeat_count',
459 'vname' => 'LBL_REPEAT_COUNT',
462 'comment' => 'Number of recurrence',
463 'importable' => 'false',
464 'massupdate' => false,
465 'reportable' => false,
468 'repeat_parent_id' =>
470 'name' => 'repeat_parent_id',
471 'vname' => 'LBL_REPEAT_PARENT_ID',
474 'comment' => 'Id of the first element of recurring records',
475 'importable' => 'false',
476 'massupdate' => false,
477 'reportable' => false,
480 'recurring_source' =>
482 'name' => 'recurring_source',
483 'vname' => 'LBL_RECURRING_SOURCE',
486 'comment' => 'Source of recurring meeting',
487 'importable' => false,
488 'massupdate' => false,
489 'reportable' => false,
494 'name' => 'duration',
495 'vname' => 'LBL_DURATION',
497 'options' => 'duration_dom',
498 'source' => 'non-db',
499 'comment' => 'Duration handler dropdown',
500 'massupdate' => false,
501 'reportable' => false,
502 'importable' => false,
505 'relationships' => array (
506 'meetings_assigned_user' =>
507 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
508 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'assigned_user_id',
509 'relationship_type'=>'one-to-many')
511 ,'meetings_modified_user' =>
512 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
513 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'modified_user_id',
514 'relationship_type'=>'one-to-many')
516 ,'meetings_created_by' =>
517 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
518 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'created_by',
519 'relationship_type'=>'one-to-many')
521 ,'meetings_notes' => array('lhs_module'=> 'Meetings', 'lhs_table'=> 'meetings', 'lhs_key' => 'id',
522 'rhs_module'=> 'Notes', 'rhs_table'=> 'notes', 'rhs_key' => 'parent_id',
523 'relationship_type'=>'one-to-many', 'relationship_role_column'=>'parent_type',
524 'relationship_role_column_value'=>'Meetings')
527 , 'indices' => array (
528 array('name' =>'idx_mtg_name', 'type'=>'index', 'fields'=>array('name')),
529 array('name' =>'idx_meet_par_del', 'type'=>'index', 'fields'=>array('parent_id','parent_type','deleted')),
530 array('name' => 'idx_meet_stat_del', 'type' => 'index', 'fields'=> array('assigned_user_id', 'status', 'deleted')),
531 array('name' => 'idx_meet_date_start', 'type' => 'index', 'fields'=> array('date_start')),
534 //This enables optimistic locking for Saves From EditView
535 ,'optimistic_locking'=>true,
538 VardefManager::createVardef('Meetings','Meeting', array('default', 'assignable',