@@ -86,8 +86,9 @@ discard block |
||
| 86 | 86 | |
| 87 | 87 | $form2 = "<table class='tabForm' width='100%' cellpadding='0' cellspacing='0' width='100%' border='0'>"; |
| 88 | 88 | $form2 .= $error_html; |
| 89 | - if(!$isAlive) |
|
| 90 | - $form2 .= "<tr><td><span id='span_display_html'>".$header_text."</span></td></tr>"; |
|
| 89 | + if(!$isAlive) { |
|
| 90 | + $form2 .= "<tr><td><span id='span_display_html'>".$header_text."</span></td></tr>"; |
|
| 91 | + } |
|
| 91 | 92 | $form2 .= "</table>"; |
| 92 | 93 | |
| 93 | 94 | $tree = null; |
@@ -101,14 +102,14 @@ discard block |
||
| 101 | 102 | $form2 .= "<tr><td></td><td align='left'>"; |
| 102 | 103 | if($isAlive){ |
| 103 | 104 | $form2 .= "<input type='button' id='modifCredentialsBtn' class='button' onClick='PackageManager.showLoginDialog(true);' value='".$mod_strings['LBL_MODIFY_CREDENTIALS']."'>"; |
| 104 | - }else{ |
|
| 105 | + } else{ |
|
| 105 | 106 | $form2 .= "<input type='button' id='modifCredentialsBtn' class='button' onClick='PackageManager.showLoginDialog(true);' value='".$mod_strings['LBL_MODIFY_CREDENTIALS']."'style='display:none;'>"; |
| 106 | 107 | } |
| 107 | 108 | $form2 .= "</td><td align='left'><div id='workingStatusDiv' style='display:none;'>".SugarThemeRegistry::current()->getImage("sqsWait","border='0' align='bottom'",null,null,'.gif',"Loading")."</div></td><td align='right'>"; |
| 108 | 109 | |
| 109 | 110 | if($isAlive){ |
| 110 | 111 | $form2 .= "<slot><a class=\"listViewTdToolsS1\" id='href_animate' onClick=\"PackageManager.toggleDiv('span_animate_server_div', 'catview');\"><span id='span_animate_server_div'><img src='".SugarThemeRegistry::current()->getImageURL('basic_search.gif')."' width='8' height='8' border='0'> Collapse</span></a></slot>"; |
| 111 | - }else{ |
|
| 112 | + } else{ |
|
| 112 | 113 | $form2 .= "<slot><a class=\"listViewTdToolsS1\" id='href_animate' onClick=\"PackageManager.toggleDiv('span_animate_server_div', 'catview');\"><span id='span_animate_server_div' style='display:none;'><img src='".SugarThemeRegistry::current()->getImageURL('basic_search.gif')."' width='8' height='8' border='0'> Collapse</span></a></slot>"; |
| 113 | 114 | } |
| 114 | 115 | $form2 .= "</td></tr></table>"; |
@@ -123,8 +124,7 @@ discard block |
||
| 123 | 124 | if (UploadStream::getSuhosinStatus() == false) |
| 124 | 125 | { |
| 125 | 126 | $ss->assign('ERR_SUHOSIN', true); |
| 126 | - } |
|
| 127 | - else |
|
| 127 | + } else |
|
| 128 | 128 | { |
| 129 | 129 | $ss->assign('scripts', PackageManagerDisplay::getDisplayScript($install)); |
| 130 | 130 | } |
@@ -168,8 +168,9 @@ discard block |
||
| 168 | 168 | $display = 'block'; |
| 169 | 169 | //} |
| 170 | 170 | $form2 = "<table class='tabForm' width='100%' cellpadding='0' cellspacing='0' width='100%' border='0'>"; |
| 171 | - if(!$isAlive) |
|
| 172 | - $form2 .= "<tr><td><span id='span_display_html'>".$header_text."</span></td></tr>"; |
|
| 171 | + if(!$isAlive) { |
|
| 172 | + $form2 .= "<tr><td><span id='span_display_html'>".$header_text."</span></td></tr>"; |
|
| 173 | + } |
|
| 173 | 174 | $form2 .= "</table>"; |
| 174 | 175 | $form2 .= "<table width='100%'><tr><td align='left'>"; |
| 175 | 176 | if($show_login){ |
@@ -182,8 +183,9 @@ discard block |
||
| 182 | 183 | $form2 .= "<div id='selectView' style='display:".$selectViewStyle."'>"; |
| 183 | 184 | $form2 .= " <div id='patch_downloads' class='ygrid-mso' style='height:205px; display: ".$display.";'></div>"; |
| 184 | 185 | $form2 .= "</div>"; |
| 185 | - if(!$show_login) |
|
| 186 | - $loginViewStyle = 'none'; |
|
| 186 | + if(!$show_login) { |
|
| 187 | + $loginViewStyle = 'none'; |
|
| 188 | + } |
|
| 187 | 189 | //$form2 .= "<div id='loginView' style='display:".$loginViewStyle."'>"; |
| 188 | 190 | //$form2 .= PackageManagerDisplay::buildLoginPanel($mod_strings, $isAlive); |
| 189 | 191 | //$form2 .= "</div>"; |
@@ -199,8 +201,9 @@ discard block |
||
| 199 | 201 | $type_str = '"'; |
| 200 | 202 | foreach($types as $type){ |
| 201 | 203 | $type_str .= "'".$type."'"; |
| 202 | - if($index < $count) |
|
| 203 | - $type_str .= ","; |
|
| 204 | + if($index < $count) { |
|
| 205 | + $type_str .= ","; |
|
| 206 | + } |
|
| 204 | 207 | $index++; |
| 205 | 208 | } |
| 206 | 209 | $type_str .= '"'; |
@@ -286,8 +289,9 @@ discard block |
||
| 286 | 289 | $output .= "</td></tr></table>"; |
| 287 | 290 | // } |
| 288 | 291 | $output .= "</div>"; |
| 289 | - if(!$show_login) |
|
| 290 | - $loginViewStyle = 'none'; |
|
| 292 | + if(!$show_login) { |
|
| 293 | + $loginViewStyle = 'none'; |
|
| 294 | + } |
|
| 291 | 295 | // $output .= "<div id='loginView' style='display:".$loginViewStyle."'>"; |
| 292 | 296 | // jchi ,#24296 :commented code because we are currently not using depot, in the future this may change so you can put this code back in. |
| 293 | 297 | //$output .= PackageManagerDisplay::buildLoginPanel($mod_strings, $display); |
@@ -307,8 +311,9 @@ discard block |
||
| 307 | 311 | static function buildTreeView($div_id, $isAlive = true){ |
| 308 | 312 | $tree = new Tree($div_id); |
| 309 | 313 | $nodes = array(); |
| 310 | - if($isAlive) |
|
| 311 | - $nodes = PackageManager::getCategories(''); |
|
| 314 | + if($isAlive) { |
|
| 315 | + $nodes = PackageManager::getCategories(''); |
|
| 316 | + } |
|
| 312 | 317 | |
| 313 | 318 | foreach($nodes as $arr_node){ |
| 314 | 319 | $node = new Node($arr_node['id'], $arr_node['label']); |
@@ -399,7 +404,7 @@ discard block |
||
| 399 | 404 | $patches = PackageManagerDisplay::createJavascriptPackageArray($releases); |
| 400 | 405 | $ss->assign('PATCHES', $patches); |
| 401 | 406 | $ss->assign('GRID_TYPE', implode(',', $types)); |
| 402 | - }else{ |
|
| 407 | + } else{ |
|
| 403 | 408 | $pm = new PackageManager(); |
| 404 | 409 | $releases = $pm->getPackagesInStaging(); |
| 405 | 410 | $patches = PackageManagerDisplay::createJavascriptModuleArray($releases); |
@@ -410,8 +415,9 @@ discard block |
||
| 410 | 415 | $ss->assign('UPGARDE_WIZARD_URL', 'index.php?module=UpgradeWizard&action=index'); |
| 411 | 416 | $ss->assign('module_load', 'true'); |
| 412 | 417 | } |
| 413 | - if(!empty($GLOBALS['ML_STATUS_MESSAGE'])) |
|
| 414 | - $ss->assign('ML_STATUS_MESSAGE',$GLOBALS['ML_STATUS_MESSAGE']); |
|
| 418 | + if(!empty($GLOBALS['ML_STATUS_MESSAGE'])) { |
|
| 419 | + $ss->assign('ML_STATUS_MESSAGE',$GLOBALS['ML_STATUS_MESSAGE']); |
|
| 420 | + } |
|
| 415 | 421 | |
| 416 | 422 | //Bug 24064. Checking and Defining labels since these might not be cached during Upgrade |
| 417 | 423 | if(!isset($mod_strings['LBL_ML_INSTALL']) || empty($mod_strings['LBL_ML_INSTALL'])){ |
@@ -467,8 +473,9 @@ discard block |
||
| 467 | 473 | $output .= "["; |
| 468 | 474 | $output .= "'".$release['description']."', '".$release['version']."', '".$release['build_number']."', '".$release['id']."'"; |
| 469 | 475 | $output .= "]"; |
| 470 | - if($index < $count) |
|
| 471 | - $output .= ","; |
|
| 476 | + if($index < $count) { |
|
| 477 | + $output .= ","; |
|
| 478 | + } |
|
| 472 | 479 | $index++; |
| 473 | 480 | } |
| 474 | 481 | } |
@@ -484,13 +491,15 @@ discard block |
||
| 484 | 491 | foreach($modules as $module){ |
| 485 | 492 | $output .= "["; |
| 486 | 493 | $output .= "'".$module['name']."', '".$module['file_install']."', '".$module['file']."', '"; |
| 487 | - if(!empty($module['enabled'])) |
|
| 488 | - $output .= $module['enabled'].'_'.$module['file']."', '"; |
|
| 494 | + if(!empty($module['enabled'])) { |
|
| 495 | + $output .= $module['enabled'].'_'.$module['file']."', '"; |
|
| 496 | + } |
|
| 489 | 497 | |
| 490 | 498 | $description = js_escape($module['description']); |
| 491 | 499 | $output .= $module['type']."', '".$module['version']."', '".$module['published_date']."', '".$module['uninstallable']."', '".$description."'".(isset($module['upload_file'])?" , '".$module['upload_file']."']":"]"); |
| 492 | - if($index < $count) |
|
| 493 | - $output .= ","; |
|
| 500 | + if($index < $count) { |
|
| 501 | + $output .= ","; |
|
| 502 | + } |
|
| 494 | 503 | $index++; |
| 495 | 504 | } |
| 496 | 505 | |
@@ -529,16 +538,15 @@ discard block |
||
| 529 | 538 | if(!function_exists('curl_init') && $show_login){ |
| 530 | 539 | $header_text = "<font color='red'><b>".$mod_strings['ERR_ENABLE_CURL']."</b></font>"; |
| 531 | 540 | $show_login = false; |
| 532 | - }else{ |
|
| 541 | + } else{ |
|
| 533 | 542 | $credentials = PackageManager::getCredentials(); |
| 534 | 543 | if(empty($credentials['username']) || empty($credentials['password'])){ |
| 535 | 544 | //$header_text = "<font color='red'><b>".$mod_strings['ERR_CREDENTIALS_MISSING']."</b></font>"; |
| 536 | - } |
|
| 537 | - else{ |
|
| 545 | + } else{ |
|
| 538 | 546 | $result = PackageManagerComm::login(); |
| 539 | 547 | if((is_array($result) && !empty($result['faultcode'])) || $result == false){ |
| 540 | 548 | $header_text = "<font color='red'><b>".$result['faultstring']."</b></font>"; |
| 541 | - }else{ |
|
| 549 | + } else{ |
|
| 542 | 550 | $header_text = PackageManager::getPromotion(); |
| 543 | 551 | $isAlive = true; |
| 544 | 552 | } |
@@ -576,8 +584,7 @@ discard block |
||
| 576 | 584 | && is_file($filename) && !empty($manifest['is_uninstallable'])) |
| 577 | 585 | { |
| 578 | 586 | $link = urlencode( $filename ); |
| 579 | - } |
|
| 580 | - else |
|
| 587 | + } else |
|
| 581 | 588 | { |
| 582 | 589 | $link = 'false'; |
| 583 | 590 | } |
@@ -607,8 +614,7 @@ discard block |
||
| 607 | 614 | $manifest_copy_files_from_dir = isset($manifest['copy_files']['from_dir']) ? clean_path($manifest['copy_files']['from_dir']) : ""; |
| 608 | 615 | $manifest_icon = clean_path($manifest['icon']); |
| 609 | 616 | $icon = "<img src=\"" . $manifest_copy_files_to_dir . ($manifest_copy_files_from_dir != "" ? substr($manifest_icon, strlen($manifest_copy_files_from_dir)+1) : $manifest_icon ) . "\">"; |
| 610 | - } |
|
| 611 | - else |
|
| 617 | + } else |
|
| 612 | 618 | { |
| 613 | 619 | $icon = getImageForType( $manifest['type'] ); |
| 614 | 620 | } |
@@ -107,25 +107,29 @@ discard block |
||
| 107 | 107 | require('sugar_version.php'); |
| 108 | 108 | require('config.php'); |
| 109 | 109 | $credentials = PackageManager::getCredentials(); |
| 110 | - if(empty($license))loadLicense(); |
|
| 110 | + if(empty($license)) { |
|
| 111 | + loadLicense(); |
|
| 112 | + } |
|
| 111 | 113 | $info = sugarEncode('2813', serialize(getSystemInfo(true))); |
| 112 | 114 | $pm = new PackageManager(); |
| 113 | 115 | $installed = $pm->buildInstalledReleases(); |
| 114 | 116 | $installed = base64_encode(serialize($installed)); |
| 115 | 117 | $params = array('installed_modules' => $installed, 'terms_checked' => $terms_checked, 'system_name' => $credentials['system_name']); |
| 116 | 118 | $terms_version = (!empty($_SESSION['SugarDepot_TermsVersion']) ? $_SESSION['SugarDepot_TermsVersion'] : ''); |
| 117 | - if(!empty($terms_version)) |
|
| 118 | - $params['terms_version'] = $terms_version; |
|
| 119 | + if(!empty($terms_version)) { |
|
| 120 | + $params['terms_version'] = $terms_version; |
|
| 121 | + } |
|
| 119 | 122 | |
| 120 | 123 | $result = $GLOBALS['SugarDepot']->call('depotLogin', array(array('user_name' => $credentials['username'], 'password' => $credentials['password']),'info'=>$info, 'params' => $params)); |
| 121 | 124 | PackageManagerComm::errorCheck(); |
| 122 | - if(!is_array($result)) |
|
| 123 | - $_SESSION['SugarDepotSessionID'] = $result; |
|
| 125 | + if(!is_array($result)) { |
|
| 126 | + $_SESSION['SugarDepotSessionID'] = $result; |
|
| 127 | + } |
|
| 124 | 128 | $GLOBALS['log']->debug("End SugarDepot Login"); |
| 125 | 129 | return $result; |
| 130 | + } else { |
|
| 131 | + return $_SESSION['SugarDepotSessionID']; |
|
| 126 | 132 | } |
| 127 | - else |
|
| 128 | - return $_SESSION['SugarDepotSessionID']; |
|
| 129 | 133 | } |
| 130 | 134 | |
| 131 | 135 | /** |
@@ -301,7 +305,7 @@ discard block |
||
| 301 | 305 | $status = $GLOBALS['SugarDepot']->call('sugarPing', array()); |
| 302 | 306 | if(empty($status) || $GLOBALS['SugarDepot']->getError() || $status != ACTIVE_STATUS){ |
| 303 | 307 | return false; |
| 304 | - }else{ |
|
| 308 | + } else{ |
|
| 305 | 309 | return true; |
| 306 | 310 | } |
| 307 | 311 | } |
@@ -1,5 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | - if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | + if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | + } |
|
| 3 | 5 | |
| 4 | 6 | $suitecrm_version = '7.5.1'; |
| 5 | 7 | $suitecrm_timestamp = '2015-01-26 17:00'; |
@@ -1,6 +1,8 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | - if(!defined('sugarEntry'))define('sugarEntry', true); |
|
| 3 | -/********************************************************************************* |
|
| 2 | + if(!defined('sugarEntry')) { |
|
| 3 | + define('sugarEntry', true); |
|
| 4 | + } |
|
| 5 | + /********************************************************************************* |
|
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
| 6 | 8 | |
@@ -193,8 +195,7 @@ discard block |
||
| 193 | 195 | $detectedType = exif_imagetype($_FILES['company_logo']['tmp_name']); |
| 194 | 196 | if(!in_array($detectedType, $allowedTypes)) { |
| 195 | 197 | $errors[] = $mod_strings['ERR_UPLOAD_FILETYPE']; |
| 196 | - } |
|
| 197 | - else { |
|
| 198 | + } else { |
|
| 198 | 199 | // uploaded image stored in the /custom path instead of put into the original theme directory.. |
| 199 | 200 | |
| 200 | 201 | mkdir_recursive('custom/' . SugarThemeRegistry::current()->getDefaultImagePath(), true); |
@@ -202,8 +203,7 @@ discard block |
||
| 202 | 203 | $destFile = 'custom/' . $tmpvar[0]; |
| 203 | 204 | if (!move_uploaded_file($_FILES['company_logo']['tmp_name'], $destFile)) { |
| 204 | 205 | $errors[] = $mod_strings['ERR_LANG_UPLOAD_1']; |
| 205 | - } |
|
| 206 | - else { |
|
| 206 | + } else { |
|
| 207 | 207 | $filepath = $destFile; |
| 208 | 208 | } |
| 209 | 209 | } |
@@ -253,7 +253,9 @@ discard block |
||
| 253 | 253 | |
| 254 | 254 | if(isset($_REQUEST['storeConfig']) && ($_REQUEST['storeConfig'])){ |
| 255 | 255 | // store configuration by form to session |
| 256 | - if(!isset($_SESSION)) session_start(); |
|
| 256 | + if(!isset($_SESSION)) { |
|
| 257 | + session_start(); |
|
| 258 | + } |
|
| 257 | 259 | $_SESSION = array_merge($_SESSION, $_POST); |
| 258 | 260 | |
| 259 | 261 | // TODO--low: don't forget the custom type install settings! validate here.. |
@@ -330,7 +332,7 @@ discard block |
||
| 330 | 332 | //define web root, which will be used as default for site_url |
| 331 | 333 | if($_SERVER['SERVER_PORT']=='80'){ |
| 332 | 334 | $web_root = $_SERVER['SERVER_NAME'].$_SERVER['PHP_SELF']; |
| 333 | -}else{ |
|
| 335 | +} else{ |
|
| 334 | 336 | $web_root = $_SERVER['SERVER_NAME'].':'.$_SERVER['SERVER_PORT'].$_SERVER['PHP_SELF']; |
| 335 | 337 | } |
| 336 | 338 | $web_root = str_replace("/install.php", "", $web_root); |
@@ -475,8 +477,7 @@ discard block |
||
| 475 | 477 | |
| 476 | 478 | <p>{$mod_strings['LBL_DISABLED_HELP_1']} <a href="{$mod_strings['LBL_DISABLED_HELP_LNK']}" target="_blank">{$mod_strings['LBL_DISABLED_HELP_2']}</a>.</p> |
| 477 | 479 | EOQ; |
| 478 | -} |
|
| 479 | -else{ |
|
| 480 | +} else{ |
|
| 480 | 481 | $validation_errors = array(); |
| 481 | 482 | // process the data posted |
| 482 | 483 | if($next_clicked) { |
@@ -562,27 +563,27 @@ discard block |
||
| 562 | 563 | $_SESSION['setup_site_custom_session_path'] = get_boolean_from_request('setup_site_custom_session_path'); |
| 563 | 564 | if($_SESSION['setup_site_custom_session_path']){ |
| 564 | 565 | $_SESSION['setup_site_session_path'] = $_REQUEST['setup_site_session_path']; |
| 565 | - }else{ |
|
| 566 | + } else{ |
|
| 566 | 567 | $_SESSION['setup_site_session_path'] = ''; |
| 567 | 568 | } |
| 568 | 569 | |
| 569 | 570 | $_SESSION['setup_site_custom_log_dir'] = get_boolean_from_request('setup_site_custom_log_dir'); |
| 570 | 571 | if($_SESSION['setup_site_custom_log_dir']){ |
| 571 | 572 | $_SESSION['setup_site_log_dir'] = $_REQUEST['setup_site_log_dir']; |
| 572 | - }else{ |
|
| 573 | + } else{ |
|
| 573 | 574 | $_SESSION['setup_site_log_dir'] = '.'; |
| 574 | 575 | } |
| 575 | 576 | |
| 576 | 577 | $_SESSION['setup_site_specify_guid'] = get_boolean_from_request('setup_site_specify_guid'); |
| 577 | 578 | if($_SESSION['setup_site_specify_guid']){ |
| 578 | 579 | $_SESSION['setup_site_guid'] = $_REQUEST['setup_site_guid']; |
| 579 | - }else{ |
|
| 580 | + } else{ |
|
| 580 | 581 | $_SESSION['setup_site_guid'] = ''; |
| 581 | 582 | } |
| 582 | 583 | $_SESSION['siteConfig_submitted'] = true; |
| 583 | 584 | if(isset($_REQUEST['setup_site_sugarbeet_anonymous_stats'])){ |
| 584 | 585 | $_SESSION['setup_site_sugarbeet_anonymous_stats'] = get_boolean_from_request('setup_site_sugarbeet_anonymous_stats'); |
| 585 | - }else{ |
|
| 586 | + } else{ |
|
| 586 | 587 | $_SESSION['setup_site_sugarbeet_anonymous_stats'] = 0; |
| 587 | 588 | } |
| 588 | 589 | |
@@ -597,13 +598,12 @@ discard block |
||
| 597 | 598 | |
| 598 | 599 | if($next_step == 9999) { |
| 599 | 600 | $the_file = 'SilentInstall'; |
| 600 | -}else if($next_step == 9191) { |
|
| 601 | +} else if($next_step == 9191) { |
|
| 601 | 602 | $_SESSION['oc_server_url'] = $_REQUEST['oc_server_url']; |
| 602 | 603 | $_SESSION['oc_username'] = $_REQUEST['oc_username']; |
| 603 | 604 | $_SESSION['oc_password'] = $_REQUEST['oc_password']; |
| 604 | 605 | $the_file = 'oc_convert.php'; |
| 605 | -} |
|
| 606 | -else{ |
|
| 606 | +} else{ |
|
| 607 | 607 | $the_file = $workflow[$next_step]; |
| 608 | 608 | |
| 609 | 609 | } |
@@ -1,5 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -1,5 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -1,5 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -1,5 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -1,5 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -61,8 +63,7 @@ discard block |
||
| 61 | 63 | if(!empty($defines['focus']->$value)) |
| 62 | 64 | { |
| 63 | 65 | $additionalFormFields[$key] = $defines['focus']->$value; |
| 64 | - } |
|
| 65 | - else |
|
| 66 | + } else |
|
| 66 | 67 | { |
| 67 | 68 | $additionalFormFields[$key] = ''; |
| 68 | 69 | } |
@@ -72,8 +73,7 @@ discard block |
||
| 72 | 73 | if(!empty($this->module)) |
| 73 | 74 | { |
| 74 | 75 | $defines['child_module_name'] = $this->module; |
| 75 | - } |
|
| 76 | - else |
|
| 76 | + } else |
|
| 77 | 77 | { |
| 78 | 78 | $defines['child_module_name'] = $defines['module']; |
| 79 | 79 | } |
@@ -109,8 +109,7 @@ discard block |
||
| 109 | 109 | { |
| 110 | 110 | if($defines['focus']->object_name=='Contact') { |
| 111 | 111 | $additionalFormFields['parent_type'] = 'Accounts'; |
| 112 | - } |
|
| 113 | - else { |
|
| 112 | + } else { |
|
| 114 | 113 | $additionalFormFields['parent_type'] = $defines['focus']->module_dir; |
| 115 | 114 | } |
| 116 | 115 | } |
@@ -119,8 +118,7 @@ discard block |
||
| 119 | 118 | if($defines['focus']->object_name=='Contact') { |
| 120 | 119 | $additionalFormFields['parent_name'] = $defines['focus']->account_name; |
| 121 | 120 | $additionalFormFields['account_name'] = $defines['focus']->account_name; |
| 122 | - } |
|
| 123 | - else { |
|
| 121 | + } else { |
|
| 124 | 122 | $additionalFormFields['parent_name'] = $defines['focus']->name; |
| 125 | 123 | } |
| 126 | 124 | } |
@@ -129,8 +127,7 @@ discard block |
||
| 129 | 127 | if($defines['focus']->object_name=='Contact') { |
| 130 | 128 | $additionalFormFields['parent_id'] = $defines['focus']->account_id; |
| 131 | 129 | $additionalFormFields['account_id'] = $defines['focus']->account_id; |
| 132 | - } |
|
| 133 | - else { |
|
| 130 | + } else { |
|
| 134 | 131 | $additionalFormFields['parent_id'] = $defines['focus']->id; |
| 135 | 132 | } |
| 136 | 133 | } |