]> CyberLeo.Net >> Repos - Github/sugarcrm.git/blob - modules/Calls/metadata/quickcreatedefs.php
Release 6.2.2
[Github/sugarcrm.git] / modules / Calls / metadata / quickcreatedefs.php
1 <?php
2 /*********************************************************************************
3  * SugarCRM Community Edition is a customer relationship management program developed by
4  * SugarCRM, Inc. Copyright (C) 2004-2011 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 ['Calls'] = 
38 array (
39   'QuickCreate' => 
40   array (
41     'templateMeta' => 
42     array (
43       'maxColumns' => '2',
44       'form' => 
45       array (
46         'hidden' => 
47         array (
48           0 => '<input type="hidden" name="isSaveAndNew" value="false">',
49           1 => '<input type="hidden" name="send_invites">',
50           2 => '<input type="hidden" name="user_invitees">',
51           3 => '<input type="hidden" name="lead_invitees">',
52           4 => '<input type="hidden" name="contact_invitees">',
53         ),
54         'buttons' => 
55         array (
56           0 => 
57           array (
58             'customCode' => '<input title="{$APP.LBL_SAVE_BUTTON_TITLE}" accessKey="{$APP.LBL_SAVE_BUTTON_KEY}" class="button" onclick="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\') && isValidDuration();" type="submit" name="button" value="{$APP.LBL_SAVE_BUTTON_LABEL}">',
59           ),
60           1 => 'CANCEL',
61           2 => 
62           array (
63             'customCode' => '<input title="{$MOD.LBL_SEND_BUTTON_TITLE}" class="button" onclick="this.form.send_invites.value=\'1\';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\') && isValidDuration();" type="submit" name="button" value="{$MOD.LBL_SEND_BUTTON_LABEL}">',
64           ),
65           3 => 
66           array (
67             '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="fill_invitees(); this.form.status.value=\'Held\'; this.form.action.value=\'Save\'; this.form.return_module.value=\'Calls\'; 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\') && isValidDuration();" type="submit" name="button" value="{$APP.LBL_CLOSE_AND_CREATE_BUTTON_LABEL}">{/if}',
68           ),
69         ),
70         'footerTpl' => 'modules/Calls/tpls/footer.tpl',
71       ),
72       'widths' => 
73       array (
74         0 => 
75         array (
76           'label' => '10',
77           'field' => '30',
78         ),
79         1 => 
80         array (
81           'label' => '10',
82           'field' => '30',
83         ),
84       ),
85       'javascript' => '<script type="text/javascript">{$JSON_CONFIG_JAVASCRIPT}</script>
86 <script type="text/javascript" src="include/javascript/jsclass_base.js?s={$SUGAR_VERSION}&c={$JS_CUSTOM_VERSION}"></script>
87 <script type="text/javascript" src="include/javascript/jsclass_async.js?s={$SUGAR_VERSION}&c={$JS_CUSTOM_VERSION}"></script>
88 <script type="text/javascript" src="modules/Meetings/jsclass_scheduler.js?s={$SUGAR_VERSION}&c={$JS_CUSTOM_VERSION}"></script>
89 <script>toggle_portal_flag();function toggle_portal_flag()  {literal} { {/literal} {$TOGGLE_JS} {literal} } {/literal} </script>',
90
91       'useTabs' => false,
92     ),
93     'panels' => 
94     array (
95       'default' => 
96       array (
97         array (
98           array (
99             'name' => 'name',
100             'displayParams' => 
101             array (
102               'required' => true,
103             ),
104           ),
105           array (
106             'name' => 'status',
107             'displayParams' => 
108             array (
109               'required' => true,
110             ),
111             'fields' => 
112             array (
113               array (
114                 'name' => 'direction',
115               ),
116               array (
117                 'name' => 'status',
118               ),
119             ),
120           ),
121         ),
122
123         array (
124           array (
125             'name' => 'date_start',
126             'type' => 'datetimecombo',
127             'displayParams' => 
128             array (
129               'required' => true,
130               'updateCallback' => 'SugarWidgetScheduler.update_time();',
131             ),
132             'label' => 'LBL_DATE_TIME',
133           ),
134           array (
135             'name' => 'parent_name',
136             'label' => 'LBL_LIST_RELATED_TO',
137           ),
138         ),
139
140         array (
141           array (
142             'name' => 'duration_hours',
143             'label' => 'LBL_DURATION',
144             'customCode' => '{literal}<script type="text/javascript">function isValidDuration() { form = document.getElementById(\'EditView\'); if ( form.duration_hours.value + form.duration_minutes.value <= 0 ) { alert(\'{/literal}{$MOD.NOTICE_DURATION_TIME}{literal}\'); return false; } return true; }</script>{/literal}<input id="duration_hours" name="duration_hours" tabindex="1" size="2" maxlength="2" type="text" value="{$fields.duration_hours.value}" onkeyup="SugarWidgetScheduler.update_time();"/>{$fields.duration_minutes.value}&nbsp;<span class="dateFormat">{$MOD.LBL_HOURS_MINUTES}',
145             'displayParams' => 
146             array (
147               'required' => true,
148             ),
149           ),
150           array (
151             'name' => 'reminder_time',
152             'customCode' => '{if $fields.reminder_checked.value == "1"}{assign var="REMINDER_TIME_DISPLAY" value="inline"}{assign var="REMINDER_CHECKED" value="checked"}{else}{assign var="REMINDER_TIME_DISPLAY" value="none"}{assign var="REMINDER_CHECKED" value=""}{/if}<input name="reminder_checked" type="hidden" value="0"><input name="reminder_checked" onclick=\'toggleDisplay("should_remind_list");\' type="checkbox" class="checkbox" value="1" {$REMINDER_CHECKED}><div id="should_remind_list" style="display:{$REMINDER_TIME_DISPLAY}">{$fields.reminder_time.value}</div>',
153             'label' => 'LBL_REMINDER',
154           ),
155           
156         ),
157         
158         array (
159           array (
160             'name' => 'assigned_user_name',
161             'label' => 'LBL_ASSIGNED_TO_NAME',
162           ),
163         ),
164
165         array (
166           array (
167             'name' => 'description',
168             'comment' => 'Full text of the note',
169             'label' => 'LBL_DESCRIPTION',
170           ),
171         ),
172       ),
173     ),
174   ),
175 );
176 ?>