2 /*********************************************************************************
3 * SugarCRM Community Edition is a customer relationship management program developed by
4 * SugarCRM, Inc. Copyright (C) 2004-2012 SugarCRM Inc.
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.
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
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
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.
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.
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 ********************************************************************************/
41 <script type="text/javascript" src="{sugar_getjspath file='modules/Emails/javascript/vars.js'}"></script>
42 <script type="text/javascript" src="{sugar_getjspath file='cache/include/javascript/sugar_grp_emails.js'}"></script>
43 <link rel="stylesheet" type="text/css" href="{sugar_getjspath file='modules/Users/PasswordRequirementBox.css'}">
44 <script type="text/javascript" src="{sugar_getjspath file='cache/include/javascript/sugar_grp_yui_widgets.js'}"></script>
45 <script type='text/javascript' src='{sugar_getjspath file='include/SubPanel/SubPanelTiles.js'}'></script>
46 <script type='text/javascript'>
47 var ERR_RULES_NOT_MET = '{$MOD.ERR_RULES_NOT_MET}';
48 var ERR_ENTER_OLD_PASSWORD = '{$MOD.ERR_ENTER_OLD_PASSWORD}';
49 var ERR_ENTER_NEW_PASSWORD = '{$MOD.ERR_ENTER_NEW_PASSWORD}';
50 var ERR_ENTER_CONFIRMATION_PASSWORD = '{$MOD.ERR_ENTER_CONFIRMATION_PASSWORD}';
51 var ERR_REENTER_PASSWORDS = '{$MOD.ERR_REENTER_PASSWORDS}';
53 <script type='text/javascript' src='{sugar_getjspath file='modules/Users/User.js'}'></script>
54 <script type='text/javascript' src='{sugar_getjspath file='modules/Users/UserEditView.js'}'></script>
55 <script type='text/javascript' src='{sugar_getjspath file='modules/Users/PasswordRequirementBox.js'}'></script>
57 <!-- This is here for the external API forms -->
58 <form name="DetailView" id="DetailView" method="POST" action="index.php">
59 <input type="hidden" name="record" id="record" value="{$ID}">
60 <input type="hidden" name="module" value="Users">
61 <input type="hidden" name="return_module" value="Users">
62 <input type="hidden" name="return_id" value="{$RETURN_ID}">
63 <input type="hidden" name="return_action" value="EditView">
66 <form name="EditView" enctype="multipart/form-data" id="EditView" method="POST" action="index.php">
67 <input type="hidden" name="display_tabs_def">
68 <input type="hidden" name="hide_tabs_def">
69 <input type="hidden" name="remove_tabs_def">
70 <input type="hidden" name="module" value="Users">
71 <input type="hidden" name="record" id="record" value="{$ID}">
72 <input type="hidden" name="action">
73 <input type="hidden" name="page" value="EditView">
74 <input type="hidden" name="return_module" value="{$RETURN_MODULE}">
75 <input type="hidden" name="return_id" value="{$RETURN_ID}">
76 <input type="hidden" name="return_action" value="{$RETURN_ACTION}">
77 <input type="hidden" name="password_change" id="password_change" value="false">
78 <input type="hidden" name="required_password" id="required_password" value='{$REQUIRED_PASSWORD}' >
79 <input type="hidden" name="old_user_name" value="{$USER_NAME}">
80 <input type="hidden" name="type" value="{$REDIRECT_EMAILS_TYPE}">
81 <input type="hidden" id="is_group" name="is_group" value='{$IS_GROUP}' {$IS_GROUP_DISABLED}>
82 <input type="hidden" id='portal_only' name='portal_only' value='{$IS_PORTALONLY}' {$IS_PORTAL_ONLY_DISABLED}>
83 <input type="hidden" name="is_admin" id="is_admin" value='{$IS_FOCUS_ADMIN}' {$IS_ADMIN_DISABLED} >
84 <input type="hidden" name="is_current_admin" id="is_current_admin" value='{$IS_ADMIN}' >
85 <input type="hidden" name="edit_self" id="edit_self" value='{$EDIT_SELF}' >
86 <input type="hidden" name="required_email_address" id="required_email_address" value='{$REQUIRED_EMAIL_ADDRESS}' >
87 <input type="hidden" name="isDuplicate" id="isDuplicate" value="{$isDuplicate}">
88 <div id="popup_window"></div>
90 <script type="text/javascript">
91 var EditView_tabs = new YAHOO.widget.TabView("EditView_tabs");
94 //Override so we do not force submit, just simulate the 'save button' click
95 SUGAR.EmailAddressWidget.prototype.forceSubmit = function() { document.getElementById('Save').click();}
97 EditView_tabs.on('contentReady', function(e){
101 var eapmTabIndex = 4;
102 {/literal}{if !$SHOW_THEMES}{literal}eapmTabIndex = 3;{/literal}{/if}{literal}
103 EditView_tabs.getTab(eapmTabIndex).set('dataSrc','index.php?sugar_body_only=1&module=Users&subpanel=eapm&action=SubPanelViewer&inline=1&record={/literal}{$ID}{literal}&layout_def_key=UserEAPM&inline=1&ajaxSubpanel=true');
104 EditView_tabs.getTab(eapmTabIndex).set('cacheData',true);
105 EditView_tabs.getTab(eapmTabIndex).on('dataLoadedChange',function(){
106 //reinit action menus
107 $("ul.clickMenu").each(function(index, node){
108 $(node).sugarActionMenu();
112 if ( document.location.hash == '#tab5' ) {
113 EditView_tabs.selectTab(eapmTabIndex);
120 <table width="100%" cellpadding="0" cellspacing="0" border="0" class="actionsContainer">
123 {sugar_action_menu id="userEditActions" class="clickMenu fancymenu" buttons=$ACTION_BUTTON_HEADER flat=true}
125 <td align="right" nowrap>
126 <span class="required">{$APP.LBL_REQUIRED_SYMBOL}</span> {$APP.NTC_REQUIRED}
131 <div id="EditView_tabs" class="yui-navset">
133 <li class="selected"><a id="tab1" href="#tab1"><em>{$MOD.LBL_USER_INFORMATION}</em></a></li>
134 <li {if $CHANGE_PWD == 0}style='display:none'{/if}><a id="tab2" href="#tab2"><em>{$MOD.LBL_CHANGE_PASSWORD_TITLE}</em></a></li>
136 <li><a id="tab3" href="#tab3" style='display:{$HIDE_FOR_GROUP_AND_PORTAL};'><em>{$MOD.LBL_THEME}</em></a></li>
138 <li><a id="tab4" href="#tab4" style='display:{$HIDE_FOR_GROUP_AND_PORTAL};'><em>{$MOD.LBL_ADVANCED}</em></a></li>
140 <li><a id="tab5" href="#tab5" style='display:{$HIDE_FOR_GROUP_AND_PORTAL};'><em>{$MOD.LBL_EAPM_SUBPANEL_TITLE}</em></a></li>
143 <div class="yui-content">
145 <!-- BEGIN METADATA GENERATED CONTENT -->