]> CyberLeo.Net >> Repos - Github/sugarcrm.git/blob - modules/Meetings/metadata/quickcreatedefs.php
Release 6.5.16
[Github/sugarcrm.git] / modules / Meetings / metadata / quickcreatedefs.php
1 <?php
2 /*********************************************************************************
3  * SugarCRM Community Edition is a customer relationship management program developed by
4  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
5  * 
6  * This program is free software; you can redistribute it and/or modify it under
7  * the terms of the GNU Affero General Public License version 3 as published by the
8  * Free Software Foundation with the addition of the following permission added
9  * to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
10  * IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
11  * OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
12  * 
13  * This program is distributed in the hope that it will be useful, but WITHOUT
14  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
15  * FOR A PARTICULAR PURPOSE.  See the GNU Affero General Public License for more
16  * details.
17  * 
18  * You should have received a copy of the GNU Affero General Public License along with
19  * this program; if not, see http://www.gnu.org/licenses or write to the Free
20  * Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21  * 02110-1301 USA.
22  * 
23  * You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
24  * SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
25  * 
26  * The interactive user interfaces in modified source and object code versions
27  * of this program must display Appropriate Legal Notices, as required under
28  * Section 5 of the GNU Affero General Public License version 3.
29  * 
30  * In accordance with Section 7(b) of the GNU Affero General Public License version 3,
31  * these Appropriate Legal Notices must retain the display of the "Powered by
32  * SugarCRM" logo. If the display of the logo is not reasonably feasible for
33  * technical reasons, the Appropriate Legal Notices must display the words
34  * "Powered by SugarCRM".
35  ********************************************************************************/
36
37 $viewdefs ['Meetings'] =
38 array (
39   'QuickCreate' =>
40   array (
41     'templateMeta' =>
42     array (
43       'maxColumns' => '2',
44       'form' =>
45       array (
46         'hidden' =>
47         array (
48            '<input type="hidden" name="isSaveAndNew" value="false">',
49            '<input type="hidden" name="is_ajax_call" value="1">',
50         ),
51         'buttons' =>
52         array (
53
54           array (
55             'customCode' => '<input title="{$APP.LBL_SAVE_BUTTON_TITLE}" accessKey="{$APP.LBL_SAVE_BUTTON_KEY}" class="button" onclick="SUGAR.meetings.fill_invitees();this.form.action.value=\'Save\'; this.form.return_action.value=\'DetailView\'; {if isset($smarty.request.isDuplicate) && $smarty.request.isDuplicate eq "true"}this.form.return_id.value=\'\'; {/if}return check_form(\'EditView\');" type="submit" name="button" value="{$APP.LBL_SAVE_BUTTON_LABEL}">',
56           ),
57            'CANCEL',
58
59           array (
60             'customCode' => '<input title="{$MOD.LBL_SEND_BUTTON_TITLE}" class="button" onclick="this.form.send_invites.value=\'1\';SUGAR.meetings.fill_invitees();this.form.action.value=\'Save\';this.form.return_action.value=\'EditView\';this.form.return_module.value=\'{$smarty.request.return_module}\';return check_form(\'EditView\');" type="submit" name="button" value="{$MOD.LBL_SEND_BUTTON_LABEL}">',
61           ),
62
63           array (
64             'customCode' => '{if $fields.status.value != "Held"}<input title="{$APP.LBL_CLOSE_AND_CREATE_BUTTON_TITLE}" accessKey="{$APP.LBL_CLOSE_AND_CREATE_BUTTON_KEY}" class="button" onclick="SUGAR.meetings.fill_invitees(); this.form.status.value=\'Held\'; this.form.action.value=\'Save\'; this.form.return_module.value=\'Meetings\'; this.form.isDuplicate.value=true; this.form.isSaveAndNew.value=true; this.form.return_action.value=\'EditView\'; this.form.return_id.value=\'{$fields.id.value}\'; return check_form(\'EditView\');" type="submit" name="button" value="{$APP.LBL_CLOSE_AND_CREATE_BUTTON_LABEL}">{/if}',
65           ),
66         ),
67       ),
68       'widths' =>
69       array (
70
71         array (
72           'label' => '10',
73           'field' => '30',
74         ),
75
76         array (
77           'label' => '10',
78           'field' => '30',
79         ),
80       ),
81       'javascript' => '<script type="text/javascript">{$JSON_CONFIG_JAVASCRIPT}</script>
82 {sugar_getscript file="cache/include/javascript/sugar_grp_jsolait.js"}
83 <script>toggle_portal_flag();function toggle_portal_flag()  {literal} { {/literal} {$TOGGLE_JS} {literal} } {/literal} </script>',
84       'useTabs' => false,
85     ),
86     'panels' =>
87     array (
88       'default' =>
89       array (
90
91         array (
92
93           array (
94             'name' => 'name',
95             'displayParams' =>
96             array (
97               'required' => true,
98             ),
99           ),
100
101           array (
102             'name' => 'status',
103             'fields' =>
104             array (
105
106               array (
107                 'name' => 'status',
108               ),
109             ),
110           ),
111         ),
112         array (
113
114           array (
115             'name' => 'date_start',
116             'type' => 'datetimecombo',
117             'displayParams' =>
118             array (
119               'required' => true,
120               'updateCallback' => 'SugarWidgetScheduler.update_time();',
121             ),
122           ),
123
124           array (
125             'name' => 'parent_name',
126             'label' => 'LBL_LIST_RELATED_TO',
127           ),
128         ),
129         
130         array (
131           array (
132             'name' => 'date_end',
133             'type' => 'datetimecombo',
134             'displayParams' =>
135             array (
136               'required' => true,
137               'updateCallback' => 'SugarWidgetScheduler.update_time();',
138             ),
139           ),
140           array (
141             'name' => 'location',
142             'comment' => 'Meeting location',
143             'label' => 'LBL_LOCATION',
144           ),
145         ),
146         
147         array(        
148           array (
149             'name' => 'duration',
150             'customCode' => '
151                 @@FIELD@@
152                 <input id="duration_hours" name="duration_hours" type="hidden" value="{$fields.duration_hours.value}">
153                 <input id="duration_minutes" name="duration_minutes" type="hidden" value="{$fields.duration_minutes.value}">
154                 {sugar_getscript file="modules/Meetings/duration_dependency.js"}
155                 <script type="text/javascript">
156                     var date_time_format = "{$CALENDAR_FORMAT}";
157                     {literal}
158                     SUGAR.util.doWhen(function(){return typeof DurationDependency != "undefined" && typeof document.getElementById("duration") != "undefined"}, function(){
159                         var duration_dependency = new DurationDependency("date_start","date_end","duration",date_time_format);
160                         initEditView(YAHOO.util.Selector.query(\'select#duration\')[0].form);
161                     });
162                     {/literal}
163                 </script>            
164             ',
165           ),          
166           array (
167             'name' => 'reminder_time',
168             'customCode' => '{include file="modules/Meetings/tpls/reminders.tpl"}',
169             'label' => 'LBL_REMINDER',
170           ),
171        ),
172
173          array (
174                  array (
175             'name' => 'assigned_user_name',
176             'label' => 'LBL_ASSIGNED_TO_NAME',
177           ),
178
179         ),
180
181         array (
182
183           array (
184             'name' => 'description',
185             'comment' => 'Full text of the note',
186             'label' => 'LBL_DESCRIPTION',
187           ),
188         ),
189       ),
190     ),
191   ),
192 );
193 ?>