Test Failed
Push — CI ( 02428e...3e0292 )
by Adam
55:43
created
data/Relationships/RelationshipFactory.php 1 patch
Braces   +17 added lines, -13 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
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.
@@ -62,8 +64,9 @@  discard block
 block discarded – undo
62 64
      */
63 65
     public static function getInstance()
64 66
     {
65
-        if (is_null(self::$rfInstance))
66
-            self::$rfInstance = new SugarRelationshipFactory();
67
+        if (is_null(self::$rfInstance)) {
68
+                    self::$rfInstance = new SugarRelationshipFactory();
69
+        }
67 70
         return self::$rfInstance;
68 71
     }
69 72
 
@@ -114,8 +117,7 @@  discard block
 block discarded – undo
114 117
                 //If a relationship has no table or join keys, it must be bean based
115 118
                 if (empty($def['true_relationship_type']) || (empty($def['table']) && empty($def['join_table'])) || empty($def['join_key_rhs'])){
116 119
                     return new One2MBeanRelationship($def);
117
-                }
118
-                else {
120
+                } else {
119 121
                     return new One2MRelationship($def);
120 122
                 }
121 123
                 break;
@@ -123,8 +125,7 @@  discard block
 block discarded – undo
123 125
                 if (empty($def['true_relationship_type'])){
124 126
                     require_once("data/Relationships/One2OneBeanRelationship.php");
125 127
                     return new One2OneBeanRelationship($def);
126
-                }
127
-                else {
128
+                } else {
128 129
                     require_once("data/Relationships/One2OneRelationship.php");
129 130
                     return new One2OneRelationship($def);
130 131
                 }
@@ -161,13 +162,15 @@  discard block
 block discarded – undo
161 162
     protected function buildRelationshipCache()
162 163
     {
163 164
         global $beanList, $dictionary, $buildingRelCache;
164
-        if ($buildingRelCache)
165
-            return;
165
+        if ($buildingRelCache) {
166
+                    return;
167
+        }
166 168
         $buildingRelCache = true;
167 169
         include("modules/TableDictionary.php");
168 170
 
169
-        if (empty($beanList))
170
-            include("include/modules.php");
171
+        if (empty($beanList)) {
172
+                    include("include/modules.php");
173
+        }
171 174
         //Reload ALL the module vardefs....
172 175
         foreach($beanList as $moduleName => $beanName)
173 176
         {
@@ -186,9 +189,10 @@  discard block
 block discarded – undo
186 189
             {
187 190
                 foreach($def['relationships'] as $relKey => $relDef)
188 191
                 {
189
-                    if ($key == $relKey) //Relationship only entry, we need to capture everything
192
+                    if ($key == $relKey) {
193
+                        //Relationship only entry, we need to capture everything
190 194
                         $relationships[$key] = array_merge(array('name' => $key), (array)$def, (array)$relDef);
191
-                    else {
195
+                    } else {
192 196
                         $relationships[$relKey] = array_merge(array('name' => $relKey), (array)$relDef);
193 197
                         if(!empty($relationships[$relKey]['join_table']) && empty($relationships[$relKey]['fields'])
194 198
                             && isset($dictionary[$relationships[$relKey]['join_table']]['fields'])) {
Please login to merge, or discard this patch.
data/Relationships/EmailAddressRelationship.php 1 patch
Braces   +15 added lines, -9 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
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.
@@ -65,8 +67,9 @@  discard block
 block discarded – undo
65 67
             return false;
66 68
         }
67 69
 
68
-            if ($lhs->$lhsLinkName->beansAreLoaded())
69
-                $lhs->$lhsLinkName->addBean($rhs);
70
+            if ($lhs->$lhsLinkName->beansAreLoaded()) {
71
+                            $lhs->$lhsLinkName->addBean($rhs);
72
+            }
70 73
 
71 74
             $this->callBeforeAdd($lhs, $rhs, $lhsLinkName);
72 75
 
@@ -75,11 +78,13 @@  discard block
 block discarded – undo
75 78
 
76 79
         $this->addRow($dataToInsert);
77 80
 
78
-        if ($this->self_referencing)
79
-            $this->addSelfReferencing($lhs, $rhs, $additionalFields);
81
+        if ($this->self_referencing) {
82
+                    $this->addSelfReferencing($lhs, $rhs, $additionalFields);
83
+        }
80 84
 
81
-            if ($lhs->$lhsLinkName->beansAreLoaded())
82
-                $lhs->$lhsLinkName->addBean($rhs);
85
+            if ($lhs->$lhsLinkName->beansAreLoaded()) {
86
+                            $lhs->$lhsLinkName->addBean($rhs);
87
+            }
83 88
 
84 89
             $this->callAfterAdd($lhs, $rhs, $lhsLinkName);
85 90
 
@@ -120,8 +125,9 @@  discard block
 block discarded – undo
120 125
 
121 126
         $this->removeRow($dataToRemove);
122 127
 
123
-        if ($this->self_referencing)
124
-            $this->removeSelfReferencing($lhs, $rhs);
128
+        if ($this->self_referencing) {
129
+                    $this->removeSelfReferencing($lhs, $rhs);
130
+        }
125 131
 
126 132
         if (empty($_SESSION['disable_workflow']) || $_SESSION['disable_workflow'] != "Yes")
127 133
         {
Please login to merge, or discard this patch.
themes/SuiteR/css/colourSelector.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,9 @@
 block discarded – undo
10 10
     require_once('../../../config_override.php');
11 11
 }
12 12
 
13
-if(!isset($sugar_config['theme_settings']['SuiteR'])) return;
13
+if(!isset($sugar_config['theme_settings']['SuiteR'])) {
14
+    return;
15
+}
14 16
 
15 17
 //set file type back to css from php
16 18
 header("Content-type: text/css; charset: UTF-8");
Please login to merge, or discard this patch.
themes/Suite7/css/colourSelector.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,9 @@
 block discarded – undo
10 10
     require_once('../../../config_override.php');
11 11
 }
12 12
 
13
-if(!isset($sugar_config['theme_settings']['Suite7'])) return;
13
+if(!isset($sugar_config['theme_settings']['Suite7'])) {
14
+    return;
15
+}
14 16
 
15 17
 //set file type back to css from php
16 18
 header("Content-type: text/css; charset: UTF-8");
Please login to merge, or discard this patch.
soap.php 1 patch
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,8 @@
 block discarded – undo
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
 
Please login to merge, or discard this patch.
modules/Connectors/InstallDefaultConnectors.php 1 patch
Braces   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
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.
@@ -94,8 +96,7 @@  discard block
 block discarded – undo
94 96
             if(!empty($default_modules_sources[$module])){
95 97
                 $merged = array_merge($modules_sources[$module], $default_modules_sources[$module]);
96 98
                 $default_modules_sources[$module] = $merged;
97
-            }
98
-            else{
99
+            } else{
99 100
                 $default_modules_sources[$module] = $modules_sources[$module];
100 101
             }
101 102
         }
Please login to merge, or discard this patch.
modules/Prospects/ProspectFormBase.php 1 patch
Braces   +53 added lines, -26 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
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.
@@ -60,20 +62,20 @@  discard block
 block discarded – undo
60 62
 	$baseQuery = 'select id,first_name, last_name, title, email1, email2  from prospects where deleted!=1 and (';
61 63
 	if(!empty($_POST[$prefix.'first_name']) && !empty($_POST[$prefix.'last_name'])){
62 64
 		$query = $baseQuery ."  (first_name like '". $_POST[$prefix.'first_name'] . "%' and last_name = '". $_POST[$prefix.'last_name'] ."')";
63
-	}else{
65
+	} else{
64 66
 			$query = $baseQuery ."  last_name = '". $_POST[$prefix.'last_name'] ."'";
65 67
 	}
66 68
 	if(!empty($_POST[$prefix.'email1'])){
67 69
 		if(empty($query)){
68 70
 		$query = $baseQuery. "  email1='". $_POST[$prefix.'email1'] . "' or email2 = '". $_POST[$prefix.'email1'] ."'";
69
-		}else {
71
+		} else {
70 72
 			$query .= "or email1='". $_POST[$prefix.'email1'] . "' or email2 = '". $_POST[$prefix.'email1'] ."'";
71 73
 		}
72 74
 	}
73 75
 	if(!empty($_POST[$prefix.'email2'])){
74 76
 		if(empty($query))	{
75 77
 			$query = $baseQuery. "  email1='". $_POST[$prefix.'email2'] . "' or email2 = '". $_POST[$prefix.'email2'] ."'";
76
-		}else{
78
+		} else{
77 79
 			$query .= "or email1='". $_POST[$prefix.'email2'] . "' or email2 = '". $_POST[$prefix.'email2'] ."'";
78 80
 		}
79 81
 
@@ -87,7 +89,9 @@  discard block
 block discarded – undo
87 89
         while($row = $db->fetchByAssoc($result)) {
88 90
             $rows[] = $row;
89 91
 		}
90
-		if(count($rows) > 0) return $rows;
92
+		if(count($rows) > 0) {
93
+		    return $rows;
94
+		}
91 95
 		}
92 96
 	return null;
93 97
 }
@@ -98,15 +102,16 @@  discard block
 block discarded – undo
98 102
 	if(!empty($mod)){
99 103
 	global $current_language;
100 104
 	$mod_strings = return_module_language($current_language, $mod);
101
-	}else global $mod_strings;
105
+	} else {
106
+	    global $mod_strings;
107
+	}
102 108
 	global $app_strings;
103 109
 	$cols = sizeof($rows[0]) * 2 + 1;
104 110
 	if ($action != 'ShowDuplicates') 
105 111
 	{
106 112
 		$form = '<table width="100%"><tr><td>'.$mod_strings['MSG_DUPLICATE']. '</td></tr><tr><td height="20"></td></tr></table>';
107 113
 		$form .= "<form action='index.php' method='post' name='dupProspects'><input type='hidden' name='selectedProspect' value=''>";
108
-	}
109
-	else 
114
+	} else 
110 115
 	{
111 116
 		$form = '<table width="100%"><tr><td>'.$mod_strings['MSG_SHOW_DUPLICATES']. '</td></tr><tr><td height="20"></td></tr></table>';
112 117
 	}
@@ -132,8 +137,9 @@  discard block
 block discarded – undo
132 137
 	foreach($rows as $row){
133 138
 
134 139
 		$form .= "<tr class='$rowColor'>";
135
-		if ($action != 'ShowDuplicates') 
136
-			$form .= "<td width='1%' nowrap='nowrap' ><a href='#' onClick=\"document.dupProspects.selectedProspect.value='${row['id']}';document.dupProspects.submit() \">[${app_strings['LBL_SELECT_BUTTON_LABEL']}]</a>&nbsp;&nbsp;</td>\n";
140
+		if ($action != 'ShowDuplicates') {
141
+					$form .= "<td width='1%' nowrap='nowrap' ><a href='#' onClick=\"document.dupProspects.selectedProspect.value='${row['id']}';document.dupProspects.submit() \">[${app_strings['LBL_SELECT_BUTTON_LABEL']}]</a>&nbsp;&nbsp;</td>\n";
142
+		}
137 143
 		
138 144
 		$wasSet = false;
139 145
 
@@ -142,8 +148,7 @@  discard block
 block discarded – undo
142 148
                 if(!$wasSet) {
143 149
                     $form .= "<td scope='row' ><a target='_blank' href='index.php?module=Prospects&action=DetailView&record=${row['id']}'>$value</a></td>\n";
144 150
                     $wasSet = true;
145
-                }
146
-                else {
151
+                } else {
147 152
                     $form .= "<td><a target='_blank' href='index.php?module=Prospects&action=DetailView&record=${row['id']}'>$value</a></td>\n";
148 153
                 }
149 154
             }
@@ -151,7 +156,7 @@  discard block
 block discarded – undo
151 156
 
152 157
 		if($rowColor == 'evenListRowS1'){
153 158
 			$rowColor = 'oddListRowS1';
154
-		}else{
159
+		} else{
155 160
 			 $rowColor = 'evenListRowS1';
156 161
 		}
157 162
 		$form .= "</tr>";
@@ -374,7 +379,9 @@  discard block
 block discarded – undo
374 379
 if(!empty($mod)){
375 380
 	global $current_language;
376 381
 	$mod_strings = return_module_language($current_language, $mod);
377
-}else global $mod_strings;
382
+} else {
383
+    global $mod_strings;
384
+}
378 385
 global $app_strings;
379 386
 
380 387
 $lbl_save_button_title = $app_strings['LBL_SAVE_BUTTON_TITLE'];
@@ -423,10 +430,16 @@  discard block
 block discarded – undo
423 430
 	if(!$focus->ACLAccess('Save')){
424 431
 		return null;
425 432
 	}
426
-	if (!isset($GLOBALS['check_notify'])) $GLOBALS['check_notify']=false;
433
+	if (!isset($GLOBALS['check_notify'])) {
434
+	    $GLOBALS['check_notify']=false;
435
+	}
427 436
 	
428
-	if (!isset($_POST[$prefix.'email_opt_out'])) $focus->email_opt_out = 0;
429
-	if (!isset($_POST[$prefix.'do_not_call'])) $focus->do_not_call = 0;
437
+	if (!isset($_POST[$prefix.'email_opt_out'])) {
438
+	    $focus->email_opt_out = 0;
439
+	}
440
+	if (!isset($_POST[$prefix.'do_not_call'])) {
441
+	    $focus->do_not_call = 0;
442
+	}
430 443
 	
431 444
 	if (empty($_POST['record']) && empty($_POST['dup_checked'])) {
432 445
 		/*
@@ -482,15 +495,29 @@  discard block
 block discarded – undo
482 495
 	$GLOBALS['log']->debug("Saved record with id of ".$return_id);
483 496
     if(isset($_POST['popup']) && $_POST['popup'] == 'true') {
484 497
         $get = '&module=';
485
-        if(!empty($_POST['return_module'])) $get .= $_POST['return_module'];
486
-        else $get .= 'Prospects';
498
+        if(!empty($_POST['return_module'])) {
499
+            $get .= $_POST['return_module'];
500
+        } else {
501
+            $get .= 'Prospects';
502
+        }
487 503
         $get .= '&action=';
488
-        if(!empty($_POST['return_action'])) $get .= $_POST['return_action'];
489
-        else $get .= 'Popup';
490
-        if(!empty($_POST['return_id'])) $get .= '&return_id='.$_POST['return_id'];
491
-        if(!empty($_POST['popup'])) $get .= '&popup='.$_POST['popup'];
492
-        if(!empty($_POST['create'])) $get .= '&create='.$_POST['create'];
493
-        if(!empty($_POST['to_pdf'])) $get .= '&to_pdf='.$_POST['to_pdf'];
504
+        if(!empty($_POST['return_action'])) {
505
+            $get .= $_POST['return_action'];
506
+        } else {
507
+            $get .= 'Popup';
508
+        }
509
+        if(!empty($_POST['return_id'])) {
510
+            $get .= '&return_id='.$_POST['return_id'];
511
+        }
512
+        if(!empty($_POST['popup'])) {
513
+            $get .= '&popup='.$_POST['popup'];
514
+        }
515
+        if(!empty($_POST['create'])) {
516
+            $get .= '&create='.$_POST['create'];
517
+        }
518
+        if(!empty($_POST['to_pdf'])) {
519
+            $get .= '&to_pdf='.$_POST['to_pdf'];
520
+        }
494 521
         $get .= '&first_name=' . $focus->first_name;
495 522
         $get .= '&last_name=' . $focus->last_name;
496 523
         $get .= '&query=true';
@@ -500,7 +527,7 @@  discard block
 block discarded – undo
500 527
 	if($redirect){
501 528
 	    require_once('include/formbase.php');
502 529
 	    handleRedirect($return_id, 'Prospects');
503
-	}else{
530
+	} else{
504 531
 		return $focus;
505 532
 	}
506 533
 }
Please login to merge, or discard this patch.
modules/Prospects/metadata/additionalDetails.php 1 patch
Braces   +51 added lines, -21 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
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.
@@ -48,42 +50,70 @@  discard block
 block discarded – undo
48 50
 		
49 51
 	$overlib_string = '';
50 52
 	
51
-	if(!empty($fields['ACCOUNT_NAME'])) $overlib_string .= '<b>'. $mod_strings['LBL_EDIT_ACCOUNT_NAME'] . '</b> ' . $fields['ACCOUNT_NAME'] . '<br>';
53
+	if(!empty($fields['ACCOUNT_NAME'])) {
54
+	    $overlib_string .= '<b>'. $mod_strings['LBL_EDIT_ACCOUNT_NAME'] . '</b> ' . $fields['ACCOUNT_NAME'] . '<br>';
55
+	}
52 56
 	if(!empty($fields['PRIMARY_ADDRESS_STREET']) || !empty($fields['PRIMARY_ADDRESS_CITY']) ||
53 57
 		!empty($fields['PRIMARY_ADDRESS_STATE']) || !empty($fields['PRIMARY_ADDRESS_POSTALCODE']) ||
54
-		!empty($fields['PRIMARY_ADDRESS_COUNTRY']))
55
-			$overlib_string .= '<b>' . $mod_strings['LBL_PRIMARY_ADDRESS'] . '</b><br>';
56
-	if(!empty($fields['PRIMARY_ADDRESS_STREET'])) $overlib_string .= $fields['PRIMARY_ADDRESS_STREET'] . '<br>';
57
-	if(!empty($fields['PRIMARY_ADDRESS_STREET_2'])) $overlib_string .= $fields['PRIMARY_ADDRESS_STREET_2'] . '<br>';
58
-	if(!empty($fields['PRIMARY_ADDRESS_STREET_3'])) $overlib_string .= $fields['PRIMARY_ADDRESS_STREET_3'] . '<br>';
59
-	if(!empty($fields['PRIMARY_ADDRESS_CITY'])) $overlib_string .= $fields['PRIMARY_ADDRESS_CITY'] . ', ';
60
-	if(!empty($fields['PRIMARY_ADDRESS_STATE'])) $overlib_string .= $fields['PRIMARY_ADDRESS_STATE'] . ' ';
61
-	if(!empty($fields['PRIMARY_ADDRESS_POSTALCODE'])) $overlib_string .= $fields['PRIMARY_ADDRESS_POSTALCODE'] . ' ';
62
-	if(!empty($fields['PRIMARY_ADDRESS_COUNTRY'])) $overlib_string .= $fields['PRIMARY_ADDRESS_COUNTRY'] . '<br>';
63
-	if(strlen($overlib_string) > 0 && !(strrpos($overlib_string, '<br>') == strlen($overlib_string) - 4)) 
64
-		$overlib_string .= '<br>';  
65
-	if(!empty($fields['PHONE_MOBILE'])) $overlib_string .= '<b>'. $mod_strings['LBL_MOBILE_PHONE'] . '</b> <span class="phone">' . $fields['PHONE_MOBILE'] . '</span><br>';
66
-	if(!empty($fields['PHONE_HOME'])) $overlib_string .= '<b>'. $mod_strings['LBL_HOME_PHONE'] . '</b> <span class="phone">' . $fields['PHONE_HOME'] . '</span><br>';
67
-	if(!empty($fields['PHONE_OTHER'])) $overlib_string .= '<b>'. $mod_strings['LBL_OTHER_PHONE'] . '</b> <span class="phone">' . $fields['PHONE_OTHER'] . '</span><br>';
58
+		!empty($fields['PRIMARY_ADDRESS_COUNTRY'])) {
59
+				$overlib_string .= '<b>' . $mod_strings['LBL_PRIMARY_ADDRESS'] . '</b><br>';
60
+	}
61
+	if(!empty($fields['PRIMARY_ADDRESS_STREET'])) {
62
+	    $overlib_string .= $fields['PRIMARY_ADDRESS_STREET'] . '<br>';
63
+	}
64
+	if(!empty($fields['PRIMARY_ADDRESS_STREET_2'])) {
65
+	    $overlib_string .= $fields['PRIMARY_ADDRESS_STREET_2'] . '<br>';
66
+	}
67
+	if(!empty($fields['PRIMARY_ADDRESS_STREET_3'])) {
68
+	    $overlib_string .= $fields['PRIMARY_ADDRESS_STREET_3'] . '<br>';
69
+	}
70
+	if(!empty($fields['PRIMARY_ADDRESS_CITY'])) {
71
+	    $overlib_string .= $fields['PRIMARY_ADDRESS_CITY'] . ', ';
72
+	}
73
+	if(!empty($fields['PRIMARY_ADDRESS_STATE'])) {
74
+	    $overlib_string .= $fields['PRIMARY_ADDRESS_STATE'] . ' ';
75
+	}
76
+	if(!empty($fields['PRIMARY_ADDRESS_POSTALCODE'])) {
77
+	    $overlib_string .= $fields['PRIMARY_ADDRESS_POSTALCODE'] . ' ';
78
+	}
79
+	if(!empty($fields['PRIMARY_ADDRESS_COUNTRY'])) {
80
+	    $overlib_string .= $fields['PRIMARY_ADDRESS_COUNTRY'] . '<br>';
81
+	}
82
+	if(strlen($overlib_string) > 0 && !(strrpos($overlib_string, '<br>') == strlen($overlib_string) - 4)) {
83
+			$overlib_string .= '<br>';
84
+	}
85
+	if(!empty($fields['PHONE_MOBILE'])) {
86
+	    $overlib_string .= '<b>'. $mod_strings['LBL_MOBILE_PHONE'] . '</b> <span class="phone">' . $fields['PHONE_MOBILE'] . '</span><br>';
87
+	}
88
+	if(!empty($fields['PHONE_HOME'])) {
89
+	    $overlib_string .= '<b>'. $mod_strings['LBL_HOME_PHONE'] . '</b> <span class="phone">' . $fields['PHONE_HOME'] . '</span><br>';
90
+	}
91
+	if(!empty($fields['PHONE_OTHER'])) {
92
+	    $overlib_string .= '<b>'. $mod_strings['LBL_OTHER_PHONE'] . '</b> <span class="phone">' . $fields['PHONE_OTHER'] . '</span><br>';
93
+	}
68 94
 
69
-	if(!empty($fields['EMAIL1'])) 
70
-		$overlib_string .= '<b>'. $mod_strings['LBL_EMAIL_ADDRESS'] . '</b> ' . 
95
+	if(!empty($fields['EMAIL1'])) {
96
+			$overlib_string .= '<b>'. $mod_strings['LBL_EMAIL_ADDRESS'] . '</b> ' . 
71 97
 								 "<a href=index.php?module=Emails&action=Compose&contact_id={$fields['ID']}&" .
72 98
 								 "parent_type=Contacts&parent_id={$fields['ID']}&to_addrs_ids={$fields['ID']}&to_addrs_names" .
73 99
 								 "={$fields['FIRST_NAME']}&nbsp;{$fields['LAST_NAME']}&to_addrs_emails={$fields['EMAIL1']}&" .
74 100
 								 "to_email_addrs=" . urlencode("{$fields['FIRST_NAME']} {$fields['LAST_NAME']} <{$fields['EMAIL1']}>") .
75 101
 								 "&return_module=Contacts&return_action=ListView'>{$fields['EMAIL1']}</a><br>";
76
-	if(!empty($fields['EMAIL2'])) 
77
-		$overlib_string .= '<b>'. $mod_strings['LBL_OTHER_EMAIL_ADDRESS'] . '</b> ' . 
102
+	}
103
+	if(!empty($fields['EMAIL2'])) {
104
+			$overlib_string .= '<b>'. $mod_strings['LBL_OTHER_EMAIL_ADDRESS'] . '</b> ' . 
78 105
 								 "<a href=index.php?module=Emails&action=Compose&contact_id={$fields['ID']}&" .
79 106
 								 "parent_type=Contacts&parent_id={$fields['ID']}&to_addrs_ids={$fields['ID']}&to_addrs_names" .
80 107
 								 "={$fields['FIRST_NAME']}&nbsp;{$fields['LAST_NAME']}&to_addrs_emails={$fields['EMAIL2']}&" .
81 108
 								 "to_email_addrs=" . urlencode("{$fields['FIRST_NAME']} {$fields['LAST_NAME']} <{$fields['EMAIL2']}>") .
82 109
 								 "&return_module=Contacts&return_action=ListView'>{$fields['EMAIL2']}</a><br>";
110
+	}
83 111
 	
84 112
 	if(!empty($fields['DESCRIPTION'])) { 
85 113
 		$overlib_string .= '<b>'. $mod_strings['LBL_DESCRIPTION'] . '</b> ' . substr($fields['DESCRIPTION'], 0, 300);
86
-		if(strlen($fields['DESCRIPTION']) > 300) $overlib_string .= '...';
114
+		if(strlen($fields['DESCRIPTION']) > 300) {
115
+		    $overlib_string .= '...';
116
+		}
87 117
 	}	
88 118
 	
89 119
 	return array('fieldToAddTo' => 'FULL_NAME', 
Please login to merge, or discard this patch.
modules/Reminders/Reminder.php 1 patch
Braces   +8 added lines, -6 removed lines patch added patch discarded remove patch
@@ -91,8 +91,7 @@  discard block
 block discarded – undo
91 91
         $reminderData = json_decode($remindersDataJson);
92 92
         if(!json_last_error()) {
93 93
             Reminder::saveRemindersData($eventModule, $eventModuleId, $reminderData);
94
-        }
95
-        else {
94
+        } else {
96 95
             throw new Exception(json_last_error_msg());
97 96
         }
98 97
     }
@@ -100,7 +99,9 @@  discard block
 block discarded – undo
100 99
     private static function saveRemindersData($eventModule, $eventModuleId, $remindersData) {
101 100
         $savedReminderIds = array();
102 101
         foreach($remindersData as $reminderData) {
103
-			if(isset($_POST['isDuplicate']) && $_POST['isDuplicate']) $reminderData->id = '';
102
+			if(isset($_POST['isDuplicate']) && $_POST['isDuplicate']) {
103
+			    $reminderData->id = '';
104
+			}
104 105
             $reminderBean = BeanFactory::getBean('Reminders', $reminderData->id);
105 106
             $reminderBean->popup = $reminderData->popup;
106 107
             $reminderBean->email = $reminderData->email;
@@ -342,8 +343,7 @@  discard block
 block discarded – undo
342 343
 								if(!$time) {
343 344
 									$time = $app_strings['MSG_JS_ALERT_MTG_REMINDER_NO_START_DATE'];
344 345
 								}
345
-							}
346
-							else {
346
+							} else {
347 347
 								$time = $app_strings['MSG_JS_ALERT_MTG_REMINDER_NO_START_DATE'];
348 348
 							}
349 349
 
@@ -366,7 +366,9 @@  discard block
 block discarded – undo
366 366
 	private static function unQuoteTime($timestr) {
367 367
 		$ret = '';
368 368
 		for($i=0; $i<strlen($timestr); $i++) {
369
-			if($timestr[$i]!="'") $ret .= $timestr[$i];
369
+			if($timestr[$i]!="'") {
370
+			    $ret .= $timestr[$i];
371
+			}
370 372
 		}
371 373
 		return $ret;
372 374
 	}
Please login to merge, or discard this patch.