2 if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
3 /*********************************************************************************
4 * SugarCRM 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',
65 'vname' => 'LBL_LOCATION',
68 'comment' => 'Meeting location'
73 'vname' => 'LBL_PASSWORD',
76 'comment' => 'Meeting password',
85 'comment' => 'Join URL',
87 'reportable' => false,
95 'comment' => 'Host URL',
97 'reportable' => false,
101 'name' => 'displayed_url',
102 'vname' => 'LBL_URL',
105 'comment' => 'Meeting URL',
111 'vname' => 'LBL_CREATOR',
114 'comment' => 'Meeting creator',
119 'name' => 'external_id',
120 'vname' => 'LBL_EXTERNALID',
123 'comment' => 'Meeting ID for external app API',
128 'name' => 'duration_hours',
129 'vname' => 'LBL_DURATION_HOURS',
132 'comment' => 'Duration (hours)',
133 'importable' => 'required',
136 'duration_minutes' =>
138 'name' => 'duration_minutes',
139 'vname' => 'LBL_DURATION_MINUTES',
141 'group'=>'duration_hours',
142 'function' => array('name'=>'getDurationMinutesOptions', 'returns'=>'html', 'include'=>'modules/Calls/CallHelper.php'),
144 'comment' => 'Duration (minutes)'
148 'name' => 'date_start',
149 'vname' => 'LBL_DATE',
150 'type' => 'datetimecombo',
151 'dbType' => 'datetime',
152 'comment' => 'Date of start of meeting',
153 'importable' => 'required',
155 'enable_range_search' => true,
160 'name' => 'date_end',
161 'vname' => 'LBL_DATE_END',
162 'type' => 'datetime',
164 'comment' => 'Date meeting ends',
165 'enable_range_search' => true,
169 'name' => 'parent_type',
170 'vname'=>'LBL_LIST_RELATED_TO',
171 'type' =>'parent_type',
172 'dbType' => 'varchar',
173 'group'=>'parent_name',
175 'comment' => 'Module meeting is associated with'
180 'vname' => 'LBL_STATUS',
183 'options' => 'meeting_status_dom',
184 'comment' => 'Meeting status (ex: Planned, Held, Not held)',
185 'default' => 'Planned',
190 'vname' => 'LBL_TYPE',
193 'function' => 'getMeetingsExternalApiDropDown',
194 'comment' => 'Meeting type (ex: WebEx, Other)',
195 'options' => 'eapm_list',
196 'default' => 'Sugar',
197 'massupdate' => false,
200 // Bug 24170 - Added only to allow the sidequickcreate form to work correctly
203 'name' => 'direction',
204 'vname' => 'LBL_DIRECTION',
207 'options' => 'call_direction_dom',
208 'comment' => 'Indicates whether call is inbound or outbound',
209 'source' => 'non-db',
210 'importable' => 'false',
217 'name' => 'parent_id',
218 'vname'=>'LBL_LIST_RELATED_TO',
220 'group'=>'parent_name',
222 'comment' => 'ID of item indicated by parent_type'
224 'reminder_checked'=>array(
225 'name' => 'reminder_checked',
226 'vname' => 'LBL_REMINDER',
228 'source' => 'non-db',
229 'comment' => 'checkbox indicating whether or not the reminder value is set (Meta-data only)',
235 'name' => 'reminder_time',
236 'vname' => 'LBL_REMINDER_TIME',
238 'function' => array('name'=>'getReminderTime', 'returns'=>'html', 'include'=>'modules/Calls/CallHelper.php', 'onListView'=>true ),
239 'reportable' => false,
241 'comment' => 'Specifies when a reminder alert should be issued; -1 means no alert; otherwise the number of seconds prior to the start'
245 'name' => 'outlook_id',
246 'vname' => 'LBL_OUTLOOK_ID',
249 'reportable' => false,
250 'comment' => 'When the Sugar Plug-in for Microsoft Outlook syncs an Outlook appointment, this is the Outlook appointment item ID'
255 'name' => 'contact_name',
256 'rname' => 'last_name',
257 'db_concat_fields'=> array(0=>'first_name', 1=>'last_name'),
258 'id_name' => 'contact_id',
259 'massupdate' => false,
260 'vname' => 'LBL_CONTACT_NAME',
263 'table' => 'contacts',
265 'module' => 'Contacts',
266 'join_name' => 'contacts',
267 'dbType' => 'varchar',
275 'name' => 'contacts',
277 'relationship' => 'meetings_contacts',
279 'vname'=>'LBL_CONTACTS',
283 'name'=> 'parent_name',
284 'parent_type'=>'record_type_display' ,
285 'type_name'=>'parent_type',
286 'id_name'=>'parent_id',
287 'vname'=>'LBL_LIST_RELATED_TO',
289 'group'=>'parent_name',
291 'options'=> 'parent_type_display',
297 'relationship' => 'meetings_users',
299 'vname'=>'LBL_USERS',
303 'name' => 'accounts',
305 'relationship' => 'account_meetings',
307 'vname'=>'LBL_ACCOUNT',
313 'relationship' => 'meetings_leads',
315 'vname'=>'LBL_LEADS',
319 'name' => 'opportunity',
321 'relationship' => 'opportunity_meetings',
323 'vname'=>'LBL_OPPORTUNITY',
329 'relationship' => 'case_meetings',
337 'relationship' => 'meetings_notes',
341 'vname'=>'LBL_NOTES',
343 'contact_id' => array(
344 'name' => 'contact_id',
346 'source' => 'non-db',
349 'relationships' => array (
350 'meetings_assigned_user' =>
351 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
352 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'assigned_user_id',
353 'relationship_type'=>'one-to-many')
355 ,'meetings_modified_user' =>
356 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
357 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'modified_user_id',
358 'relationship_type'=>'one-to-many')
360 ,'meetings_created_by' =>
361 array('lhs_module'=> 'Users', 'lhs_table'=> 'users', 'lhs_key' => 'id',
362 'rhs_module'=> 'Meetings', 'rhs_table'=> 'meetings', 'rhs_key' => 'created_by',
363 'relationship_type'=>'one-to-many')
365 ,'meetings_notes' => array('lhs_module'=> 'Meetings', 'lhs_table'=> 'meetings', 'lhs_key' => 'id',
366 'rhs_module'=> 'Notes', 'rhs_table'=> 'notes', 'rhs_key' => 'parent_id',
367 'relationship_type'=>'one-to-many', 'relationship_role_column'=>'parent_type',
368 'relationship_role_column_value'=>'Meetings')
371 , 'indices' => array (
372 array('name' =>'idx_mtg_name', 'type'=>'index', 'fields'=>array('name')),
373 array('name' =>'idx_meet_par_del', 'type'=>'index', 'fields'=>array('parent_id','parent_type','deleted')),
374 array('name' => 'idx_meet_stat_del', 'type' => 'index', 'fields'=> array('assigned_user_id', 'status', 'deleted')),
377 //This enables optimistic locking for Saves From EditView
378 ,'optimistic_locking'=>true,
381 VardefManager::createVardef('Meetings','Meeting', array('default', 'assignable',