Completed
Push — master ( 58f496...a833c2 )
by Adam
18:52
created
modules/AOR_Reports/Dashlets/AORReportsDashlet/AORReportsDashlet.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
     var $onlyCharts;
13 13
 
14 14
     function AORReportsDashlet($id, $def = array()) {
15
-		global $current_user, $app_strings;
15
+        global $current_user, $app_strings;
16 16
 
17 17
         parent::Dashlet($id);
18 18
         $this->isConfigurable = true;
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
         }
69 69
     }
70 70
 
71
-	function process() {
71
+    function process() {
72 72
     }
73 73
 
74 74
     public function displayOptions() {
Please login to merge, or discard this patch.
modules/AOR_Reports/Dashlets/AORReportsDashlet/AORReportsDashlet.meta.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,6 +3,6 @@
 block discarded – undo
3 3
 global $app_strings;
4 4
 
5 5
 $dashletMeta['AORReportsDashlet'] = array('module'		=> 'AOR_Reports',
6
-										  'title'       => translate('LBL_AOR_REPORTS_DASHLET', 'AOR_Reports'),
7
-                                          'description' => 'Displays Reports',
8
-                                          'category'    => 'Module Views');
6
+                                            'title'       => translate('LBL_AOR_REPORTS_DASHLET', 'AOR_Reports'),
7
+                                            'description' => 'Displays Reports',
8
+                                            'category'    => 'Module Views');
Please login to merge, or discard this patch.
modules/DynamicFields/DynamicField.php 1 patch
Indentation   +68 added lines, -68 removed lines patch added patch discarded remove patch
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
         $this->base_path = "custom/Extension/modules/{$this->module}/Ext/Vardefs";
52 52
     }
53 53
 
54
-   function getModuleName()
54
+    function getModuleName()
55 55
     {
56 56
         return $this->module ;
57 57
     }
@@ -69,11 +69,11 @@  discard block
 block discarded – undo
69 69
 
70 70
 
71 71
     /**
72
-    * This will add the bean as a reference in this object as well as building the custom field cache if it has not been built
73
-    * LOADS THE BEAN IF THE BEAN IS NOT BEING PASSED ALONG IN SETUP IT SHOULD BE SET PRIOR TO SETUP
74
-    *
75
-    * @param SUGARBEAN $bean
76
-    */
72
+     * This will add the bean as a reference in this object as well as building the custom field cache if it has not been built
73
+     * LOADS THE BEAN IF THE BEAN IS NOT BEING PASSED ALONG IN SETUP IT SHOULD BE SET PRIOR TO SETUP
74
+     *
75
+     * @param SUGARBEAN $bean
76
+     */
77 77
     function setup($bean = null) {
78 78
         if ($bean) {
79 79
             $this->bean = $bean;
@@ -95,12 +95,12 @@  discard block
 block discarded – undo
95 95
     }
96 96
 
97 97
     /**
98
-    * Builds the cache for custom fields based on the vardefs
99
-    *
100
-    * @param STRING $module
101
-    * @param boolean saveCache Boolean value indicating whether or not to pass saveCache value to saveToVardef, defaults to true
102
-    * @return unknown
103
-    */
98
+     * Builds the cache for custom fields based on the vardefs
99
+     *
100
+     * @param STRING $module
101
+     * @param boolean saveCache Boolean value indicating whether or not to pass saveCache value to saveToVardef, defaults to true
102
+     * @return unknown
103
+     */
104 104
     function buildCache($module = false, $saveCache=true) {
105 105
         //We can't build the cache while installing as the required database tables may not exist.
106 106
         if (!empty($GLOBALS['installing']) && $GLOBALS['installing'] == true|| empty($GLOBALS['db']))
@@ -161,8 +161,8 @@  discard block
 block discarded – undo
161 161
     }
162 162
 
163 163
     /**
164
-    * Returns the widget for a custom field from the fields_meta_data table.
165
-    */
164
+     * Returns the widget for a custom field from the fields_meta_data table.
165
+     */
166 166
     function getFieldWidget($module, $fieldName) {
167 167
         if (empty($module) || empty($fieldName)){
168 168
             sugar_die("Unable to load widget for '$module' : '$fieldName'");
@@ -179,12 +179,12 @@  discard block
 block discarded – undo
179 179
 
180 180
 
181 181
     /**
182
-    * Updates the cached vardefs with the custom field information stored in result
183
-    *
184
-    * @param string $module
185
-    * @param array $result
186
-    * @param boolean saveCache Boolean value indicating whether or not to call VardefManager::saveCache, defaults to true
187
-    */
182
+     * Updates the cached vardefs with the custom field information stored in result
183
+     *
184
+     * @param string $module
185
+     * @param array $result
186
+     * @param boolean saveCache Boolean value indicating whether or not to call VardefManager::saveCache, defaults to true
187
+     */
188 188
     function saveToVardef($module,$result,$saveCache=true) {
189 189
 
190 190
 
@@ -248,14 +248,14 @@  discard block
 block discarded – undo
248 248
     }
249 249
 
250 250
     /**
251
-    * returns either false or an array containing the select and join parameter for a query using custom fields
252
-    * @param $expandedList boolean	If true, return a list of all fields with source=custom_fields in the select instead of the standard _cstm.*
253
-    *     This is required for any downstream construction of a SQL statement where we need to manipulate the select list,
254
-    *     for example, listviews with custom relate fields where the value comes from join rather than from the custom table
255
-    *
256
-    * @return array select=>select columns, join=>prebuilt join statement
257
-    */
258
-  function getJOIN( $expandedList = false , $includeRelates = false, &$where = false){
251
+     * returns either false or an array containing the select and join parameter for a query using custom fields
252
+     * @param $expandedList boolean	If true, return a list of all fields with source=custom_fields in the select instead of the standard _cstm.*
253
+     *     This is required for any downstream construction of a SQL statement where we need to manipulate the select list,
254
+     *     for example, listviews with custom relate fields where the value comes from join rather than from the custom table
255
+     *
256
+     * @return array select=>select columns, join=>prebuilt join statement
257
+     */
258
+    function getJOIN( $expandedList = false , $includeRelates = false, &$where = false){
259 259
         if(!$this->bean->hasCustomFields()){
260 260
             return array(
261 261
                 'select' => '',
@@ -308,7 +308,7 @@  discard block
 block discarded – undo
308 308
 
309 309
     }
310 310
 
311
-   function getRelateJoin($field_def, $joinTableAlias, $withIdName = true) {
311
+    function getRelateJoin($field_def, $joinTableAlias, $withIdName = true) {
312 312
         if (empty($field_def['type']) || $field_def['type'] != "relate") {
313 313
             return false;
314 314
         }
@@ -346,13 +346,13 @@  discard block
 block discarded – undo
346 346
         $ret_array['from'] = " LEFT JOIN $rel_table $joinTableAlias ON $tableName.$relID = $joinTableAlias.id"
347 347
                             . " AND $joinTableAlias.deleted=0 ";
348 348
         return $ret_array;
349
-   }
349
+    }
350 350
 
351
-   /**
352
-    * Fills in all the custom fields of type relate relationships for an object
353
-    *
354
-    */
355
-   function fill_relationships(){
351
+    /**
352
+     * Fills in all the custom fields of type relate relationships for an object
353
+     *
354
+     */
355
+    function fill_relationships(){
356 356
         global $beanList, $beanFiles;
357 357
         if(!empty($this->bean->relDepth)) {
358 358
             if($this->bean->relDepth > 1)return;
@@ -387,7 +387,7 @@  discard block
 block discarded – undo
387 387
      *
388 388
      * @param boolean $isUpdate
389 389
      */
390
-     function save($isUpdate){
390
+        function save($isUpdate){
391 391
 
392 392
         if($this->bean->hasCustomFields() && isset($this->bean->id)){
393 393
 
@@ -422,8 +422,8 @@  discard block
 block discarded – undo
422 422
                     }
423 423
 
424 424
                     $val = $this->bean->$name;
425
-					if(($field['type'] == 'date' || $field['type'] == 'datetimecombo') && (empty($this->bean->$name )|| $this->bean->$name == '1900-01-01')){
426
-                    	$quote = '';
425
+                    if(($field['type'] == 'date' || $field['type'] == 'datetimecombo') && (empty($this->bean->$name )|| $this->bean->$name == '1900-01-01')){
426
+                        $quote = '';
427 427
                         $val = 'NULL';
428 428
                         $this->bean->$name = ''; // do not set it to string 'NULL'
429 429
                     }
@@ -571,11 +571,11 @@  discard block
 block discarded – undo
571 571
         if($field){
572 572
             if(!$is_update){
573 573
                 //Do two SQL calls here in this case
574
-            	//The first is to create the column in the custom table without the default value
575
-            	//The second is to modify the column created in the custom table to set the default value
576
-            	//We do this so that the existing entries in the custom table don't have the default value set
577
-            	$field->default = '';
578
-            	$field->default_value = '';
574
+                //The first is to create the column in the custom table without the default value
575
+                //The second is to modify the column created in the custom table to set the default value
576
+                //We do this so that the existing entries in the custom table don't have the default value set
577
+                $field->default = '';
578
+                $field->default_value = '';
579 579
                 // resetting default and default_value does not work for multienum and causes trouble for mssql
580 580
                 // so using a temporary variable here to indicate that we don't want default for this query
581 581
                 $field->no_default = 1;
@@ -583,19 +583,19 @@  discard block
 block discarded – undo
583 583
                 // unsetting temporary member variable
584 584
                 unset($field->no_default);
585 585
                 if(!empty($query)){
586
-                	$GLOBALS['db']->query($query, true, "Cannot create column");
587
-	                $field->default = $fmd->default_value;
588
-	                $field->default_value = $fmd->default_value;
589
-	                $query = $field->get_db_modify_alter_table($this->bean->table_name . '_cstm');
590
-	                if(!empty($query)){
591
-	                	$GLOBALS['db']->query($query, true, "Cannot set default");
592
-	            	}
586
+                    $GLOBALS['db']->query($query, true, "Cannot create column");
587
+                    $field->default = $fmd->default_value;
588
+                    $field->default_value = $fmd->default_value;
589
+                    $query = $field->get_db_modify_alter_table($this->bean->table_name . '_cstm');
590
+                    if(!empty($query)){
591
+                        $GLOBALS['db']->query($query, true, "Cannot set default");
592
+                    }
593 593
                 }
594 594
             }else{
595 595
                 $query = $field->get_db_modify_alter_table($this->bean->table_name . '_cstm');
596 596
                 if(!empty($query)){
597
-                	$GLOBALS['db']->query($query, true, "Cannot modify field");
598
-            	}
597
+                    $GLOBALS['db']->query($query, true, "Cannot modify field");
598
+                }
599 599
             }
600 600
             $fmd->save();
601 601
             $this->buildCache($this->module);
@@ -761,12 +761,12 @@  discard block
 block discarded – undo
761 761
                 )
762 762
             );
763 763
             $ididx = array(
764
-       			'id'=>array(
765
-       				'name' =>$this->bean->table_name."_cstm_pk",
766
-       				'type' =>'primary',
767
-       				'fields'=>array('id_c')
764
+                    'id'=>array(
765
+                        'name' =>$this->bean->table_name."_cstm_pk",
766
+                        'type' =>'primary',
767
+                        'fields'=>array('id_c')
768 768
                 ),
769
-           );
769
+            );
770 770
 
771 771
             $query = $GLOBALS['db']->createTableSQLParams($this->bean->table_name."_cstm", $iddef, $ididx);
772 772
             if(!$GLOBALS['db']->supports("inline_keys")) {
@@ -798,14 +798,14 @@  discard block
 block discarded – undo
798 798
      *
799 799
      */
800 800
     function add_existing_custom_fields($execute = true){
801
-    	$out = "";
801
+        $out = "";
802 802
         if($this->bean->hasCustomFields()){
803
-	        foreach($this->bean->field_defs as $name=>$data){
804
-	        	if(empty($data['source']) || $data['source'] != 'custom_fields')
803
+            foreach($this->bean->field_defs as $name=>$data){
804
+                if(empty($data['source']) || $data['source'] != 'custom_fields')
805 805
                     continue;
806
-	            $out .= $this->add_existing_custom_field($data, $execute);
807
-	        }
808
-    	}
806
+                $out .= $this->add_existing_custom_field($data, $execute);
807
+            }
808
+        }
809 809
         return $out;
810 810
     }
811 811
 
@@ -959,7 +959,7 @@  discard block
 block discarded – undo
959 959
 
960 960
     }
961 961
 
962
-   function populateXTPL($xtpl, $view) {
962
+    function populateXTPL($xtpl, $view) {
963 963
 
964 964
         if($this->bean->hasCustomFields()){
965 965
             $results = $this->getAllFieldsView($view, 'xtpl');
@@ -984,12 +984,12 @@  discard block
 block discarded – undo
984 984
     }
985 985
 
986 986
     function getAllFieldsView($view, $type){
987
-         require_once ('modules/DynamicFields/FieldCases.php');
988
-         $results = array();
989
-         foreach($this->bean->field_defs as $name=>$data){
987
+            require_once ('modules/DynamicFields/FieldCases.php');
988
+            $results = array();
989
+            foreach($this->bean->field_defs as $name=>$data){
990 990
             if(empty($data['source']) || $data['source'] != 'custom_fields')
991 991
             {
992
-            	continue;
992
+                continue;
993 993
             }
994 994
             $field = get_widget ( $data ['type'] );
995 995
             $field->populateFromRow($data);
Please login to merge, or discard this patch.
modules/DynamicFields/UpgradeFields.php 1 patch
Indentation   +74 added lines, -74 removed lines patch added patch discarded remove patch
@@ -40,95 +40,95 @@  discard block
 block discarded – undo
40 40
 
41 41
 require_once('modules/DynamicFields/FieldCases.php');
42 42
 require_once('modules/DynamicFields/DynamicField.php');
43
- global $db;
44
- if(!isset($db)){
45
- 	$db = DBManagerFactory::getInstance();
46
- }
47
- $result = $db->query( 'SELECT * FROM fields_meta_data WHERE deleted = 0 ORDER BY custom_module');
48
- $modules = array();
49
- /*
43
+    global $db;
44
+    if(!isset($db)){
45
+        $db = DBManagerFactory::getInstance();
46
+    }
47
+    $result = $db->query( 'SELECT * FROM fields_meta_data WHERE deleted = 0 ORDER BY custom_module');
48
+    $modules = array();
49
+    /*
50 50
   * get the real field_meta_data
51 51
   */
52
- while($row = $db->fetchByAssoc($result)){
53
- 	$the_modules = $row['custom_module'];
54
- 	if(!isset($modules[$the_modules])){
55
- 		$modules[$the_modules] = array();	
56
- 	}
57
- 	$modules[$the_modules][$row['name']] = $row['name'];
58
- }
52
+    while($row = $db->fetchByAssoc($result)){
53
+        $the_modules = $row['custom_module'];
54
+        if(!isset($modules[$the_modules])){
55
+            $modules[$the_modules] = array();	
56
+        }
57
+        $modules[$the_modules][$row['name']] = $row['name'];
58
+    }
59 59
  	
60
- $simulate = false;
61
- if(!isset($_REQUEST['run'])){
62
- 	$simulate = true;
63
- 	echo "SIMULATION MODE - NO CHANGES WILL BE MADE EXCEPT CLEARING CACHE";
64
- }	
60
+    $simulate = false;
61
+    if(!isset($_REQUEST['run'])){
62
+        $simulate = true;
63
+        echo "SIMULATION MODE - NO CHANGES WILL BE MADE EXCEPT CLEARING CACHE";
64
+    }	
65 65
 
66
- foreach($modules as $the_module=>$fields){
67
-         if(isset($beanList[$the_module]))
68
-         {
69
- 	$class_name = $beanList[$the_module];
70
- 	echo "<br><br>Scanning $the_module <br>";
66
+    foreach($modules as $the_module=>$fields){
67
+            if(isset($beanList[$the_module]))
68
+            {
69
+        $class_name = $beanList[$the_module];
70
+        echo "<br><br>Scanning $the_module <br>";
71 71
 		
72
-		require_once($beanFiles[$class_name]);
73
-		$mod = new $class_name();
74
-		if(!$db->tableExists($mod->table_name . "_cstm")){
75
-			$mod->custom_fields = new DynamicField();
76
-			$mod->custom_fields->setup($mod);
77
-		$mod->custom_fields->createCustomTable();
78
-		}
72
+        require_once($beanFiles[$class_name]);
73
+        $mod = new $class_name();
74
+        if(!$db->tableExists($mod->table_name . "_cstm")){
75
+            $mod->custom_fields = new DynamicField();
76
+            $mod->custom_fields->setup($mod);
77
+        $mod->custom_fields->createCustomTable();
78
+        }
79 79
 
80
-		$result = $db->query("DESCRIBE $mod->table_name" . "_cstm");
80
+        $result = $db->query("DESCRIBE $mod->table_name" . "_cstm");
81 81
 		
82
-		while($row = $db->fetchByAssoc($result)){
82
+        while($row = $db->fetchByAssoc($result)){
83 83
 			
84 84
 			
85
-			$col = $row['Field'];
86
-			$type = $row['Type'];
87
-			$fieldDef = $mod->getFieldDefinition($col);
88
-			$the_field = get_widget($fieldDef['type']);
89
-			$the_field->set($fieldDef);
85
+            $col = $row['Field'];
86
+            $type = $row['Type'];
87
+            $fieldDef = $mod->getFieldDefinition($col);
88
+            $the_field = get_widget($fieldDef['type']);
89
+            $the_field->set($fieldDef);
90 90
 				
91
-				if(!isset($fields[$col]) && $col != 'id_c'){
92
-					if(!$simulate)$db->query("ALTER TABLE $mod->table_name" . "_cstm DROP COLUMN $col");
93
-					unset($fields[$col]);
94
-					echo "Dropping Column $col from $mod->table_name" . "_cstm for module $the_module<br>";
95
-				}	else{
96
-					if($col != 'id_c'){
97
-					if(trim($the_field->get_db_type()) != trim($type)){
91
+                if(!isset($fields[$col]) && $col != 'id_c'){
92
+                    if(!$simulate)$db->query("ALTER TABLE $mod->table_name" . "_cstm DROP COLUMN $col");
93
+                    unset($fields[$col]);
94
+                    echo "Dropping Column $col from $mod->table_name" . "_cstm for module $the_module<br>";
95
+                }	else{
96
+                    if($col != 'id_c'){
97
+                    if(trim($the_field->get_db_type()) != trim($type)){
98 98
 						
99
-					echo "Fixing Column Type for $col changing $type to ". $the_field->get_db_type() . "<br>";
100
-					if(!$simulate)$db->query($the_field->get_db_modify_alter_table($mod->table_name . '_cstm'));		
101
-					}
102
-					}
99
+                    echo "Fixing Column Type for $col changing $type to ". $the_field->get_db_type() . "<br>";
100
+                    if(!$simulate)$db->query($the_field->get_db_modify_alter_table($mod->table_name . '_cstm'));		
101
+                    }
102
+                    }
103 103
 					
104
-					unset($fields[$col]);
105
-				}
104
+                    unset($fields[$col]);
105
+                }
106 106
 			
107
-		}
107
+        }
108 108
 			
109
-			echo sizeof($fields) . " field(s) missing from $mod->table_name" . "_cstm<br>";
110
-			foreach($fields as $field){
111
-				echo "Adding Column $field to $mod->table_name" . "_cstm<br>";
112
-				if(!$simulate){
113
-					$the_field = $mod->getFieldDefinition($field);
114
-					$field = get_widget($the_field['type']);
115
-					$field->set($the_field);
116
-					$query = $field->get_db_add_alter_table($mod->table_name . '_cstm');
117
-					echo $query;
118
-            		if(!empty($query)){
119
-                		$mod->db->query($query);
120
-            		}
121
-				}
122
-			}
123
-         }
124
-	}
109
+            echo sizeof($fields) . " field(s) missing from $mod->table_name" . "_cstm<br>";
110
+            foreach($fields as $field){
111
+                echo "Adding Column $field to $mod->table_name" . "_cstm<br>";
112
+                if(!$simulate){
113
+                    $the_field = $mod->getFieldDefinition($field);
114
+                    $field = get_widget($the_field['type']);
115
+                    $field->set($the_field);
116
+                    $query = $field->get_db_add_alter_table($mod->table_name . '_cstm');
117
+                    echo $query;
118
+                    if(!empty($query)){
119
+                        $mod->db->query($query);
120
+                    }
121
+                }
122
+            }
123
+            }
124
+    }
125 125
 	
126 126
 	
127
-	DynamicField::deleteCache();	
128
-	echo '<br>Done<br>';
129
-	if($simulate){
130
-		echo '<a href="index.php?module=Administration&action=UpgradeFields&run=true">Execute non-simulation mode</a>';	
131
-	}
127
+    DynamicField::deleteCache();	
128
+    echo '<br>Done<br>';
129
+    if($simulate){
130
+        echo '<a href="index.php?module=Administration&action=UpgradeFields&run=true">Execute non-simulation mode</a>';	
131
+    }
132 132
 		
133 133
 		
134 134
  
@@ -137,4 +137,4 @@  discard block
 block discarded – undo
137 137
  
138 138
  
139 139
  
140
- ?>
141 140
\ No newline at end of file
141
+    ?>
142 142
\ No newline at end of file
Please login to merge, or discard this patch.
modules/Relationships/field_arrays.php 1 patch
Indentation   +32 added lines, -32 removed lines patch added patch discarded remove patch
@@ -46,39 +46,39 @@
 block discarded – undo
46 46
  * Contributor(s): ______________________________________..
47 47
  ********************************************************************************/
48 48
 $fields_array['Relationship'] = array ('column_fields' => Array(
49
-		'id',
50
-		'relationship_name',
51
-		'lhs_module',
52
-		'lhs_table',
53
-		'lhs_key',
54
-		'rhs_module',
55
-		'rhs_table',
56
-		'rhs_key',
57
-		'join_table',
58
-		'join_key_lhs',
59
-		'join_key_rhs',
60
-		'relationship_type',
61
-		'relationship_role_column',
62
-		'relationship_role_column_value',
63
-		'reverse',
64
-	),
49
+        'id',
50
+        'relationship_name',
51
+        'lhs_module',
52
+        'lhs_table',
53
+        'lhs_key',
54
+        'rhs_module',
55
+        'rhs_table',
56
+        'rhs_key',
57
+        'join_table',
58
+        'join_key_lhs',
59
+        'join_key_rhs',
60
+        'relationship_type',
61
+        'relationship_role_column',
62
+        'relationship_role_column_value',
63
+        'reverse',
64
+    ),
65 65
         'list_fields' =>  Array(
66
-		'id',
67
-		'relationship_name',
68
-		'lhs_module',
69
-		'lhs_table',
70
-		'lhs_key',
71
-		'rhs_module',
72
-		'rhs_table',
73
-		'rhs_key',
74
-		'join_table',
75
-		'join_key_lhs',
76
-		'join_key_rhs',
77
-		'relationship_type',
78
-		'relationship_role_column',
79
-		'relationship_role_column_value',
80
-		'reverse',
81
-	),
66
+        'id',
67
+        'relationship_name',
68
+        'lhs_module',
69
+        'lhs_table',
70
+        'lhs_key',
71
+        'rhs_module',
72
+        'rhs_table',
73
+        'rhs_key',
74
+        'join_table',
75
+        'join_key_lhs',
76
+        'join_key_rhs',
77
+        'relationship_type',
78
+        'relationship_role_column',
79
+        'relationship_role_column_value',
80
+        'reverse',
81
+    ),
82 82
     'required_fields' =>   array("relationship_name"=>1),
83 83
 );
84 84
 ?>
85 85
\ No newline at end of file
Please login to merge, or discard this patch.
modules/jjwg_Maps/jjwg_Maps_Router.php 1 patch
Indentation   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -11,21 +11,21 @@  discard block
 block discarded – undo
11 11
 
12 12
 if (!empty($_REQUEST['cron'])) {
13 13
   
14
-  require_once('modules/jjwg_Maps/jjwg_Maps.php');
15
-  require_once('modules/jjwg_Maps/controller.php');
16
-  /*
14
+    require_once('modules/jjwg_Maps/jjwg_Maps.php');
15
+    require_once('modules/jjwg_Maps/controller.php');
16
+    /*
17 17
    * This script can be used as an entry point for a cron
18 18
    * job to run the address geocoding on a regular basis.
19 19
    * index.php?module=jjwg_Maps&entryPoint=jjwg_Maps&cron=1&limit=2500
20 20
    */
21
-  $controller = new jjwg_MapsController();
22
-  $controller->action_geocode_addresses();
21
+    $controller = new jjwg_MapsController();
22
+    $controller->action_geocode_addresses();
23 23
   
24
-  exit;
24
+    exit;
25 25
 
26 26
 } else {
27 27
   
28
-  /*
28
+    /*
29 29
    * This script is also used to pass selected records from 
30 30
    * a module list view to the Maps Module (jjwg_Maps).
31 31
    *
@@ -45,25 +45,25 @@  discard block
 block discarded – undo
45 45
    * 4.) Parameter Search - Checked Records - Map
46 46
    *     Uses 'uid'(s) parameter to define search
47 47
    */
48
-  //echo 'Test:<pre>'."\n";
49
-  //foreach (array_keys($_REQUEST) as $key) {
50
-  //  echo 'Name: '.htmlspecialchars($key).'  Value: '.htmlspecialchars($_REQUEST[$key])."\n";
51
-  //}
48
+    //echo 'Test:<pre>'."\n";
49
+    //foreach (array_keys($_REQUEST) as $key) {
50
+    //  echo 'Name: '.htmlspecialchars($key).'  Value: '.htmlspecialchars($_REQUEST[$key])."\n";
51
+    //}
52 52
   
53
-  // Redirect parameters to view/action using Javascript form post.
54
-  echo '<html><head></head><body>';
55
-  echo '<form name="redirect" action="index.php" method="POST">'."\n";
56
-  echo '<input type="hidden" name="module" value="jjwg_Maps">'."\n";
57
-  echo '<input type="hidden" name="action" value="map_display">'."\n";
58
-  foreach (array_keys($_REQUEST) as $key) {
53
+    // Redirect parameters to view/action using Javascript form post.
54
+    echo '<html><head></head><body>';
55
+    echo '<form name="redirect" action="index.php" method="POST">'."\n";
56
+    echo '<input type="hidden" name="module" value="jjwg_Maps">'."\n";
57
+    echo '<input type="hidden" name="action" value="map_display">'."\n";
58
+    foreach (array_keys($_REQUEST) as $key) {
59 59
     if (!in_array($key, array('action','module','entryPoint','display_module', 'quick_address'))) {
60
-      echo '<input type="hidden" name="'.htmlspecialchars($key).'" value="'.htmlspecialchars($_REQUEST[$key]).'">'."\n";
60
+        echo '<input type="hidden" name="'.htmlspecialchars($key).'" value="'.htmlspecialchars($_REQUEST[$key]).'">'."\n";
61 61
     }
62
-  }
63
-  echo '<input type="hidden" name="display_module" value="'.htmlspecialchars($_REQUEST['display_module']).'">'."\n";
64
-  echo '</form>'."\n";
65
-  echo '<script language="javascript" type="text/javascript">document.redirect.submit();</script>'."\n"; 
66
-  echo '</body></html>';
62
+    }
63
+    echo '<input type="hidden" name="display_module" value="'.htmlspecialchars($_REQUEST['display_module']).'">'."\n";
64
+    echo '</form>'."\n";
65
+    echo '<script language="javascript" type="text/javascript">document.redirect.submit();</script>'."\n"; 
66
+    echo '</body></html>';
67 67
   
68
-  exit;
68
+    exit;
69 69
 }
Please login to merge, or discard this patch.
modules/SecurityGroups/VersionCheck.php 1 patch
Indentation   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -4,30 +4,30 @@  discard block
 block discarded – undo
4 4
 
5 5
 class VersionCheck {
6 6
 
7
-	function version_check($event, $arguments)
8
-	{
9
-		global $current_user;
7
+    function version_check($event, $arguments)
8
+    {
9
+        global $current_user;
10 10
 	
11
-		require_once('include/utils.php');
12
-		if(is_admin($current_user) && empty($_REQUEST['to_pdf']) && empty($_REQUEST['sugar_body_only'])) {
13
-			//require_once('modules/SecurityGroups/SecurityGroup.php');
11
+        require_once('include/utils.php');
12
+        if(is_admin($current_user) && empty($_REQUEST['to_pdf']) && empty($_REQUEST['sugar_body_only'])) {
13
+            //require_once('modules/SecurityGroups/SecurityGroup.php');
14 14
 			
15
-			//check to see if the securitysuite version
16
-			//matches the sugar version. If not then display an error messag
15
+            //check to see if the securitysuite version
16
+            //matches the sugar version. If not then display an error messag
17 17
 			
18
-			global $sugar_config;
19
-			if(empty($sugar_config['securitysuite_version'])
20
-				|| $sugar_config['securitysuite_version'] != $sugar_config['sugar_version']
21
-			) {
22
-				$securitysuite_warning = "Warning! SecuritySuite no longer matches the version of Sugar that you are running. "
23
-					. "SecuritySuite will not work correctly until updated to ".$sugar_config['sugar_version'].". "
24
-					. "Upgrade now to  ";
18
+            global $sugar_config;
19
+            if(empty($sugar_config['securitysuite_version'])
20
+                || $sugar_config['securitysuite_version'] != $sugar_config['sugar_version']
21
+            ) {
22
+                $securitysuite_warning = "Warning! SecuritySuite no longer matches the version of Sugar that you are running. "
23
+                    . "SecuritySuite will not work correctly until updated to ".$sugar_config['sugar_version'].". "
24
+                    . "Upgrade now to  ";
25 25
 					
26
-				global $sugar_config;
27
-				$upgrade_url = "http://www.eggsurplus.com/version.php?version=".$sugar_config['sugar_version'];
28
-				$upgrade_text = "SecuritySuite for ".$sugar_config['sugar_version'];
29
-				$GLOBALS['log']->fatal($securitysuite_warning."<a href='$upgrade_url'>$upgrade_text</a>");
30
-				//echo $display_warning;
26
+                global $sugar_config;
27
+                $upgrade_url = "http://www.eggsurplus.com/version.php?version=".$sugar_config['sugar_version'];
28
+                $upgrade_text = "SecuritySuite for ".$sugar_config['sugar_version'];
29
+                $GLOBALS['log']->fatal($securitysuite_warning."<a href='$upgrade_url'>$upgrade_text</a>");
30
+                //echo $display_warning;
31 31
 
32 32
 
33 33
 ?>
@@ -50,10 +50,10 @@  discard block
 block discarded – undo
50 50
 </script>
51 51
 <?php
52 52
 
53
-			}
53
+            }
54 54
 		
55
-		} //end if admin
56
-	} 
55
+        } //end if admin
56
+    } 
57 57
 
58 58
 
59 59
 }
Please login to merge, or discard this patch.
modules/SecurityGroups/SecurityGroup.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
                     and secr.module = '$module'
55 55
                 where secg.deleted = 0
56 56
             )";
57
-        */
57
+         */
58 58
 
59 59
             //and secr.record_id = $table_name.id //not needed as the in clause takes care of this check
60 60
         }
@@ -376,7 +376,7 @@  discard block
 block discarded – undo
376 376
             //if(empty($parent_type) || empty($parent_id)) {
377 377
                 foreach($focus->field_name_map as $name=>$def) {
378 378
 
379
-                   if($def['type']=='relate' && isset($def['id_name'])
379
+                    if($def['type']=='relate' && isset($def['id_name'])
380 380
                         && isset($def['module']) && strtolower($def['module']) != "users" ) {
381 381
 
382 382
                         if(isset($_REQUEST[$def['id_name']])) {
@@ -390,7 +390,7 @@  discard block
 block discarded – undo
390 390
 
391 391
                             SecurityGroup::inherit_parentQuery($focus, $relate_parent_type, $relate_parent_id, $focus_id, $focus_module_dir);
392 392
                         }
393
-                   }
393
+                    }
394 394
                 }
395 395
             //}
396 396
 
Please login to merge, or discard this patch.
modules/SecurityGroups/SecurityGroupUserRelationship.php 1 patch
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -32,14 +32,14 @@
 block discarded – undo
32 32
     
33 33
     var $additional_column_fields = Array();
34 34
         var $field_defs = array (
35
-       'id'=>array('name' =>'id', 'type' =>'char', 'len'=>'36', 'default'=>'')
36
-      , 'securitygroup_id'=>array('name' =>'securitygroup_id', 'type' =>'char', 'len'=>'36', )
37
-      , 'user_id'=>array('name' =>'user_id', 'type' =>'char', 'len'=>'36',)
38
-      , 'noninheritable'=>array('name' =>'noninheritable', 'type' =>'bool', 'len'=>'1')
39
-      , 'primary_group'=>array('name' =>'primary_group', 'type' =>'bool', 'len'=>'1')
40
-      , 'date_modified'=>array ('name' => 'date_modified','type' => 'datetime')
41
-      , 'deleted'=>array('name' =>'deleted', 'type' =>'bool', 'len'=>'1', 'default'=>'0', 'required'=>true)
42
-      );
35
+        'id'=>array('name' =>'id', 'type' =>'char', 'len'=>'36', 'default'=>'')
36
+        , 'securitygroup_id'=>array('name' =>'securitygroup_id', 'type' =>'char', 'len'=>'36', )
37
+        , 'user_id'=>array('name' =>'user_id', 'type' =>'char', 'len'=>'36',)
38
+        , 'noninheritable'=>array('name' =>'noninheritable', 'type' =>'bool', 'len'=>'1')
39
+        , 'primary_group'=>array('name' =>'primary_group', 'type' =>'bool', 'len'=>'1')
40
+        , 'date_modified'=>array ('name' => 'date_modified','type' => 'datetime')
41
+        , 'deleted'=>array('name' =>'deleted', 'type' =>'bool', 'len'=>'1', 'default'=>'0', 'required'=>true)
42
+        );
43 43
     function SecurityGroupUserRelationship() {
44 44
         $this->db = DBManagerFactory::getInstance();
45 45
         $this->dbManager = DBManagerFactory::getInstance();
Please login to merge, or discard this patch.