@@ -5,7 +5,7 @@ discard block |
||
5 | 5 | |
6 | 6 | class ContactsListViewSmarty extends ListViewSmarty { |
7 | 7 | |
8 | - function __construct(){ |
|
8 | + function __construct() { |
|
9 | 9 | |
10 | 10 | parent::__construct(); |
11 | 11 | $this->targetList = true; |
@@ -15,9 +15,9 @@ discard block |
||
15 | 15 | /** |
16 | 16 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
17 | 17 | */ |
18 | - function ContactsListViewSmarty(){ |
|
18 | + function ContactsListViewSmarty() { |
|
19 | 19 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
20 | - if(isset($GLOBALS['log'])) { |
|
20 | + if (isset($GLOBALS['log'])) { |
|
21 | 21 | $GLOBALS['log']->deprecated($deprecatedMessage); |
22 | 22 | } |
23 | 23 | else { |
@@ -30,25 +30,25 @@ discard block |
||
30 | 30 | function process($file, $data, $htmlVar) { |
31 | 31 | parent::process($file, $data, $htmlVar); |
32 | 32 | |
33 | - if(!ACLController::checkAccess($this->seed->module_dir,'export',true) || !$this->export) { |
|
33 | + if (!ACLController::checkAccess($this->seed->module_dir, 'export', true) || !$this->export) { |
|
34 | 34 | $this->ss->assign('exportLink', $this->buildExportLink()); |
35 | 35 | } |
36 | 36 | } |
37 | 37 | |
38 | - function buildExportLink($id = 'export_link'){ |
|
38 | + function buildExportLink($id = 'export_link') { |
|
39 | 39 | global $app_strings; |
40 | 40 | global $sugar_config; |
41 | 41 | |
42 | 42 | $script = ""; |
43 | - if(ACLController::checkAccess($this->seed->module_dir,'export',true)) { |
|
44 | - if($this->export) { |
|
43 | + if (ACLController::checkAccess($this->seed->module_dir, 'export', true)) { |
|
44 | + if ($this->export) { |
|
45 | 45 | $script = parent::buildExportLink($id); |
46 | 46 | } |
47 | 47 | } |
48 | 48 | |
49 | - $script .= "<a href='javascript:void(0)' id='map_listview_top' " . |
|
50 | - " onclick=\"return sListView.send_form(true, 'jjwg_Maps', " . |
|
51 | - "'index.php?entryPoint=jjwg_Maps&display_module={$_REQUEST['module']}', " . |
|
49 | + $script .= "<a href='javascript:void(0)' id='map_listview_top' ". |
|
50 | + " onclick=\"return sListView.send_form(true, 'jjwg_Maps', ". |
|
51 | + "'index.php?entryPoint=jjwg_Maps&display_module={$_REQUEST['module']}', ". |
|
52 | 52 | "'{$app_strings['LBL_LISTVIEW_NO_SELECTED']}')\">{$app_strings['LBL_MAP']}</a>"; |
53 | 53 | |
54 | 54 | return formLetter::LVSmarty().$script; |
@@ -23,8 +23,7 @@ |
||
23 | 23 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
24 | 24 | if(isset($GLOBALS['log'])) { |
25 | 25 | $GLOBALS['log']->deprecated($deprecatedMessage); |
26 | - } |
|
27 | - else { |
|
26 | + } else { |
|
28 | 27 | trigger_error($deprecatedMessage, E_USER_DEPRECATED); |
29 | 28 | } |
30 | 29 | self::__construct($seed, $module, $subPanel, $options); |
@@ -48,16 +48,16 @@ |
||
48 | 48 | |
49 | 49 | class ContactsViewContactAddressPopup extends SugarView { |
50 | 50 | |
51 | - function __construct(){ |
|
51 | + function __construct() { |
|
52 | 52 | parent::__construct(); |
53 | 53 | } |
54 | 54 | |
55 | 55 | /** |
56 | 56 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
57 | 57 | */ |
58 | - function ContactsViewContactAddressPopup(){ |
|
58 | + function ContactsViewContactAddressPopup() { |
|
59 | 59 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
60 | - if(isset($GLOBALS['log'])) { |
|
60 | + if (isset($GLOBALS['log'])) { |
|
61 | 61 | $GLOBALS['log']->deprecated($deprecatedMessage); |
62 | 62 | } |
63 | 63 | else { |
@@ -23,8 +23,7 @@ |
||
23 | 23 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
24 | 24 | if(isset($GLOBALS['log'])) { |
25 | 25 | $GLOBALS['log']->deprecated($deprecatedMessage); |
26 | - } |
|
27 | - else { |
|
26 | + } else { |
|
28 | 27 | trigger_error($deprecatedMessage, E_USER_DEPRECATED); |
29 | 28 | } |
30 | 29 | self::__construct($seed, $module, $subPanel, $options); |
@@ -52,44 +52,44 @@ discard block |
||
52 | 52 | |
53 | 53 | // Contact is used to store customer information. |
54 | 54 | class ContactOpportunityRelationship extends SugarBean { |
55 | - // Stored fields |
|
56 | - var $id; |
|
57 | - var $contact_id; |
|
58 | - var $contact_role; |
|
59 | - var $opportunity_id; |
|
60 | - |
|
61 | - // Related fields |
|
62 | - var $contact_name; |
|
63 | - var $opportunity_name; |
|
64 | - |
|
65 | - var $table_name = "opportunities_contacts"; |
|
66 | - var $object_name = "ContactOpportunityRelationship"; |
|
67 | - var $column_fields = Array("id" |
|
68 | - ,"contact_id" |
|
69 | - ,"opportunity_id" |
|
70 | - ,"contact_role" |
|
71 | - ,'date_modified' |
|
72 | - ); |
|
73 | - |
|
74 | - var $new_schema = true; |
|
75 | - |
|
76 | - var $additional_column_fields = Array(); |
|
77 | - var $field_defs = array ( |
|
78 | - 'id'=>array('name' =>'id', 'type' =>'char', 'len'=>'36', 'default'=>'') |
|
79 | - , 'contact_id'=>array('name' =>'contact_id', 'type' =>'char', 'len'=>'36', ) |
|
80 | - , 'opportunity_id'=>array('name' =>'opportunity_id', 'type' =>'char', 'len'=>'36',) |
|
81 | - , 'contact_role'=>array('name' =>'contact_role', 'type' =>'char', 'len'=>'50') |
|
82 | - , 'date_modified'=>array ('name' => 'date_modified','type' => 'datetime') |
|
83 | - , 'deleted'=>array('name' =>'deleted', 'type' =>'bool', 'len'=>'1', 'default'=>'0', 'required'=>true) |
|
84 | - ); |
|
85 | - function __construct() { |
|
55 | + // Stored fields |
|
56 | + var $id; |
|
57 | + var $contact_id; |
|
58 | + var $contact_role; |
|
59 | + var $opportunity_id; |
|
60 | + |
|
61 | + // Related fields |
|
62 | + var $contact_name; |
|
63 | + var $opportunity_name; |
|
64 | + |
|
65 | + var $table_name = "opportunities_contacts"; |
|
66 | + var $object_name = "ContactOpportunityRelationship"; |
|
67 | + var $column_fields = Array("id" |
|
68 | + ,"contact_id" |
|
69 | + ,"opportunity_id" |
|
70 | + ,"contact_role" |
|
71 | + ,'date_modified' |
|
72 | + ); |
|
73 | + |
|
74 | + var $new_schema = true; |
|
75 | + |
|
76 | + var $additional_column_fields = Array(); |
|
77 | + var $field_defs = array ( |
|
78 | + 'id'=>array('name' =>'id', 'type' =>'char', 'len'=>'36', 'default'=>'') |
|
79 | + , 'contact_id'=>array('name' =>'contact_id', 'type' =>'char', 'len'=>'36', ) |
|
80 | + , 'opportunity_id'=>array('name' =>'opportunity_id', 'type' =>'char', 'len'=>'36',) |
|
81 | + , 'contact_role'=>array('name' =>'contact_role', 'type' =>'char', 'len'=>'50') |
|
82 | + , 'date_modified'=>array ('name' => 'date_modified','type' => 'datetime') |
|
83 | + , 'deleted'=>array('name' =>'deleted', 'type' =>'bool', 'len'=>'1', 'default'=>'0', 'required'=>true) |
|
84 | + ); |
|
85 | + function __construct() { |
|
86 | 86 | parent::__construct(); |
87 | - $this->db = DBManagerFactory::getInstance(); |
|
87 | + $this->db = DBManagerFactory::getInstance(); |
|
88 | 88 | $this->dbManager = DBManagerFactory::getInstance(); |
89 | 89 | |
90 | - $this->disable_row_level_security =true; |
|
90 | + $this->disable_row_level_security =true; |
|
91 | 91 | |
92 | - } |
|
92 | + } |
|
93 | 93 | |
94 | 94 | /** |
95 | 95 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
@@ -106,36 +106,36 @@ discard block |
||
106 | 106 | } |
107 | 107 | |
108 | 108 | |
109 | - function fill_in_additional_detail_fields() |
|
110 | - { |
|
111 | - global $locale; |
|
112 | - if(isset($this->contact_id) && $this->contact_id != "") |
|
113 | - { |
|
114 | - $query = "SELECT first_name, last_name from contacts where id='$this->contact_id' AND deleted=0"; |
|
115 | - $result =$this->db->query($query,true," Error filling in additional detail fields: "); |
|
116 | - // Get the id and the name. |
|
117 | - $row = $this->db->fetchByAssoc($result); |
|
118 | - |
|
119 | - if($row != null) |
|
120 | - { |
|
121 | - $this->contact_name = $locale->getLocaleFormattedName($row['first_name'], $row['last_name']); |
|
122 | - } |
|
123 | - } |
|
124 | - |
|
125 | - if(isset($this->opportunity_id) && $this->opportunity_id != "") |
|
126 | - { |
|
127 | - $query = "SELECT name from opportunities where id='$this->opportunity_id' AND deleted=0"; |
|
128 | - $result =$this->db->query($query,true," Error filling in additional detail fields: "); |
|
129 | - // Get the id and the name. |
|
130 | - $row = $this->db->fetchByAssoc($result); |
|
131 | - |
|
132 | - if($row != null) |
|
133 | - { |
|
134 | - $this->opportunity_name = $row['name']; |
|
135 | - } |
|
136 | - } |
|
137 | - |
|
138 | - } |
|
109 | + function fill_in_additional_detail_fields() |
|
110 | + { |
|
111 | + global $locale; |
|
112 | + if(isset($this->contact_id) && $this->contact_id != "") |
|
113 | + { |
|
114 | + $query = "SELECT first_name, last_name from contacts where id='$this->contact_id' AND deleted=0"; |
|
115 | + $result =$this->db->query($query,true," Error filling in additional detail fields: "); |
|
116 | + // Get the id and the name. |
|
117 | + $row = $this->db->fetchByAssoc($result); |
|
118 | + |
|
119 | + if($row != null) |
|
120 | + { |
|
121 | + $this->contact_name = $locale->getLocaleFormattedName($row['first_name'], $row['last_name']); |
|
122 | + } |
|
123 | + } |
|
124 | + |
|
125 | + if(isset($this->opportunity_id) && $this->opportunity_id != "") |
|
126 | + { |
|
127 | + $query = "SELECT name from opportunities where id='$this->opportunity_id' AND deleted=0"; |
|
128 | + $result =$this->db->query($query,true," Error filling in additional detail fields: "); |
|
129 | + // Get the id and the name. |
|
130 | + $row = $this->db->fetchByAssoc($result); |
|
131 | + |
|
132 | + if($row != null) |
|
133 | + { |
|
134 | + $this->opportunity_name = $row['name']; |
|
135 | + } |
|
136 | + } |
|
137 | + |
|
138 | + } |
|
139 | 139 | } |
140 | 140 | |
141 | 141 |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
2 | +if (!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
3 | 3 | /********************************************************************************* |
4 | 4 | * SugarCRM Community Edition is a customer relationship management program developed by |
5 | 5 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -74,12 +74,12 @@ discard block |
||
74 | 74 | var $new_schema = true; |
75 | 75 | |
76 | 76 | var $additional_column_fields = Array(); |
77 | - var $field_defs = array ( |
|
77 | + var $field_defs = array( |
|
78 | 78 | 'id'=>array('name' =>'id', 'type' =>'char', 'len'=>'36', 'default'=>'') |
79 | - , 'contact_id'=>array('name' =>'contact_id', 'type' =>'char', 'len'=>'36', ) |
|
79 | + , 'contact_id'=>array('name' =>'contact_id', 'type' =>'char', 'len'=>'36',) |
|
80 | 80 | , 'opportunity_id'=>array('name' =>'opportunity_id', 'type' =>'char', 'len'=>'36',) |
81 | 81 | , 'contact_role'=>array('name' =>'contact_role', 'type' =>'char', 'len'=>'50') |
82 | - , 'date_modified'=>array ('name' => 'date_modified','type' => 'datetime') |
|
82 | + , 'date_modified'=>array('name' => 'date_modified', 'type' => 'datetime') |
|
83 | 83 | , 'deleted'=>array('name' =>'deleted', 'type' =>'bool', 'len'=>'1', 'default'=>'0', 'required'=>true) |
84 | 84 | ); |
85 | 85 | function __construct() { |
@@ -87,16 +87,16 @@ discard block |
||
87 | 87 | $this->db = DBManagerFactory::getInstance(); |
88 | 88 | $this->dbManager = DBManagerFactory::getInstance(); |
89 | 89 | |
90 | - $this->disable_row_level_security =true; |
|
90 | + $this->disable_row_level_security = true; |
|
91 | 91 | |
92 | 92 | } |
93 | 93 | |
94 | 94 | /** |
95 | 95 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
96 | 96 | */ |
97 | - function ContactOpportunityRelationship(){ |
|
97 | + function ContactOpportunityRelationship() { |
|
98 | 98 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
99 | - if(isset($GLOBALS['log'])) { |
|
99 | + if (isset($GLOBALS['log'])) { |
|
100 | 100 | $GLOBALS['log']->deprecated($deprecatedMessage); |
101 | 101 | } |
102 | 102 | else { |
@@ -109,27 +109,27 @@ discard block |
||
109 | 109 | function fill_in_additional_detail_fields() |
110 | 110 | { |
111 | 111 | global $locale; |
112 | - if(isset($this->contact_id) && $this->contact_id != "") |
|
112 | + if (isset($this->contact_id) && $this->contact_id != "") |
|
113 | 113 | { |
114 | 114 | $query = "SELECT first_name, last_name from contacts where id='$this->contact_id' AND deleted=0"; |
115 | - $result =$this->db->query($query,true," Error filling in additional detail fields: "); |
|
115 | + $result = $this->db->query($query, true, " Error filling in additional detail fields: "); |
|
116 | 116 | // Get the id and the name. |
117 | 117 | $row = $this->db->fetchByAssoc($result); |
118 | 118 | |
119 | - if($row != null) |
|
119 | + if ($row != null) |
|
120 | 120 | { |
121 | 121 | $this->contact_name = $locale->getLocaleFormattedName($row['first_name'], $row['last_name']); |
122 | 122 | } |
123 | 123 | } |
124 | 124 | |
125 | - if(isset($this->opportunity_id) && $this->opportunity_id != "") |
|
125 | + if (isset($this->opportunity_id) && $this->opportunity_id != "") |
|
126 | 126 | { |
127 | 127 | $query = "SELECT name from opportunities where id='$this->opportunity_id' AND deleted=0"; |
128 | - $result =$this->db->query($query,true," Error filling in additional detail fields: "); |
|
128 | + $result = $this->db->query($query, true, " Error filling in additional detail fields: "); |
|
129 | 129 | // Get the id and the name. |
130 | 130 | $row = $this->db->fetchByAssoc($result); |
131 | 131 | |
132 | - if($row != null) |
|
132 | + if ($row != null) |
|
133 | 133 | { |
134 | 134 | $this->opportunity_name = $row['name']; |
135 | 135 | } |
@@ -43,7 +43,9 @@ discard block |
||
43 | 43 | * Date: 06/03/15 |
44 | 44 | * Comments |
45 | 45 | */ |
46 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
46 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
47 | + die('Not A Valid Entry Point'); |
|
48 | +} |
|
47 | 49 | |
48 | 50 | class CasesController extends SugarController { |
49 | 51 | |
@@ -90,8 +92,7 @@ discard block |
||
90 | 92 | $count++; |
91 | 93 | } |
92 | 94 | echo '</table>'; |
93 | - } |
|
94 | - else { |
|
95 | + } else { |
|
95 | 96 | echo $mod_strings['LBL_NO_SUGGESTIONS']; |
96 | 97 | } |
97 | 98 | die(); |
@@ -80,9 +80,9 @@ discard block |
||
80 | 80 | /** |
81 | 81 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
82 | 82 | */ |
83 | - function AOR_Field(){ |
|
83 | + function AOR_Field() { |
|
84 | 84 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
85 | - if(isset($GLOBALS['log'])) { |
|
85 | + if (isset($GLOBALS['log'])) { |
|
86 | 86 | $GLOBALS['log']->deprecated($deprecatedMessage); |
87 | 87 | } |
88 | 88 | else { |
@@ -97,11 +97,11 @@ discard block |
||
97 | 97 | |
98 | 98 | require_once('modules/AOW_WorkFlow/aow_utils.php'); |
99 | 99 | |
100 | - $line_count = count($post_data[$key . 'field']); |
|
100 | + $line_count = count($post_data[$key.'field']); |
|
101 | 101 | for ($i = 0; $i < $line_count; ++$i) { |
102 | 102 | |
103 | - if ($post_data[$key . 'deleted'][$i] == 1) { |
|
104 | - $this->mark_deleted($post_data[$key . 'id'][$i]); |
|
103 | + if ($post_data[$key.'deleted'][$i] == 1) { |
|
104 | + $this->mark_deleted($post_data[$key.'id'][$i]); |
|
105 | 105 | } else { |
106 | 106 | $field = new AOR_Field(); |
107 | 107 | $field->group_display = false; |
@@ -117,22 +117,22 @@ discard block |
||
117 | 117 | |
118 | 118 | foreach ($this->field_defs as $field_def) { |
119 | 119 | $field_name = $field_def['name']; |
120 | - if (is_array($post_data[$key . $field_name])) { |
|
121 | - if ($field_name != 'group_display' && isset($post_data[$key . $field_name][$i])) { |
|
122 | - if (is_array($post_data[$key . $field_name][$i])) { |
|
123 | - $post_data[$key . $field_name][$i] = base64_encode(serialize($post_data[$key . $field_name][$i])); |
|
120 | + if (is_array($post_data[$key.$field_name])) { |
|
121 | + if ($field_name != 'group_display' && isset($post_data[$key.$field_name][$i])) { |
|
122 | + if (is_array($post_data[$key.$field_name][$i])) { |
|
123 | + $post_data[$key.$field_name][$i] = base64_encode(serialize($post_data[$key.$field_name][$i])); |
|
124 | 124 | } else if ($field_name == 'value') { |
125 | - $post_data[$key . $field_name][$i] = fixUpFormatting($_REQUEST['report_module'], $field->field, $post_data[$key . $field_name][$i]); |
|
125 | + $post_data[$key.$field_name][$i] = fixUpFormatting($_REQUEST['report_module'], $field->field, $post_data[$key.$field_name][$i]); |
|
126 | 126 | } |
127 | 127 | if ($field_name == 'module_path') { |
128 | - $post_data[$key . $field_name][$i] = base64_encode(serialize(explode(":", $post_data[$key . $field_name][$i]))); |
|
128 | + $post_data[$key.$field_name][$i] = base64_encode(serialize(explode(":", $post_data[$key.$field_name][$i]))); |
|
129 | 129 | } |
130 | - $field->$field_name = $post_data[$key . $field_name][$i]; |
|
130 | + $field->$field_name = $post_data[$key.$field_name][$i]; |
|
131 | 131 | } |
132 | - } else if (is_null($post_data[$key . $field_name])) { |
|
132 | + } else if (is_null($post_data[$key.$field_name])) { |
|
133 | 133 | // do nothing |
134 | 134 | } else { |
135 | - throw new Exception('illegal type in post data at key ' . $key . $field_name . ' ' . gettype($post_data[$key . $field_name])); |
|
135 | + throw new Exception('illegal type in post data at key '.$key.$field_name.' '.gettype($post_data[$key.$field_name])); |
|
136 | 136 | } |
137 | 137 | |
138 | 138 | } |
@@ -23,8 +23,7 @@ |
||
23 | 23 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
24 | 24 | if(isset($GLOBALS['log'])) { |
25 | 25 | $GLOBALS['log']->deprecated($deprecatedMessage); |
26 | - } |
|
27 | - else { |
|
26 | + } else { |
|
28 | 27 | trigger_error($deprecatedMessage, E_USER_DEPRECATED); |
29 | 28 | } |
30 | 29 | self::__construct($seed, $module, $subPanel, $options); |
@@ -14,9 +14,9 @@ |
||
14 | 14 | /** |
15 | 15 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
16 | 16 | */ |
17 | - function CasesJjwg_MapsLogicHook(){ |
|
17 | + function CasesJjwg_MapsLogicHook() { |
|
18 | 18 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
19 | - if(isset($GLOBALS['log'])) { |
|
19 | + if (isset($GLOBALS['log'])) { |
|
20 | 20 | $GLOBALS['log']->deprecated($deprecatedMessage); |
21 | 21 | } |
22 | 22 | else { |
@@ -1,7 +1,8 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -if (!defined('sugarEntry') || !sugarEntry) |
|
3 | +if (!defined('sugarEntry') || !sugarEntry) { |
|
4 | 4 | die('Not A Valid Entry Point'); |
5 | +} |
|
5 | 6 | |
6 | 7 | class OpportunitiesJjwg_MapsLogicHook { |
7 | 8 | |
@@ -17,8 +18,7 @@ discard block |
||
17 | 18 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
18 | 19 | if(isset($GLOBALS['log'])) { |
19 | 20 | $GLOBALS['log']->deprecated($deprecatedMessage); |
20 | - } |
|
21 | - else { |
|
21 | + } else { |
|
22 | 22 | trigger_error($deprecatedMessage, E_USER_DEPRECATED); |
23 | 23 | } |
24 | 24 | self::__construct(); |
@@ -77,9 +77,9 @@ discard block |
||
77 | 77 | /** |
78 | 78 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
79 | 79 | */ |
80 | - function AOR_Condition(){ |
|
80 | + function AOR_Condition() { |
|
81 | 81 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
82 | - if(isset($GLOBALS['log'])) { |
|
82 | + if (isset($GLOBALS['log'])) { |
|
83 | 83 | $GLOBALS['log']->deprecated($deprecatedMessage); |
84 | 84 | } |
85 | 85 | else { |
@@ -94,40 +94,40 @@ discard block |
||
94 | 94 | |
95 | 95 | require_once('modules/AOW_WorkFlow/aow_utils.php'); |
96 | 96 | |
97 | - $line_count = count($post_data[$key . 'field']); |
|
97 | + $line_count = count($post_data[$key.'field']); |
|
98 | 98 | $j = 0; |
99 | 99 | for ($i = 0; $i < $line_count; ++$i) { |
100 | 100 | |
101 | - if ($post_data[$key . 'deleted'][$i] == 1) { |
|
102 | - $this->mark_deleted($post_data[$key . 'id'][$i]); |
|
101 | + if ($post_data[$key.'deleted'][$i] == 1) { |
|
102 | + $this->mark_deleted($post_data[$key.'id'][$i]); |
|
103 | 103 | } else { |
104 | 104 | $condition = new AOR_Condition(); |
105 | 105 | foreach ($this->field_defs as $field_def) { |
106 | 106 | $field_name = $field_def['name']; |
107 | - if (isset($post_data[$key . $field_name][$i])) { |
|
108 | - if (is_array($post_data[$key . $field_name][$i])) { |
|
107 | + if (isset($post_data[$key.$field_name][$i])) { |
|
108 | + if (is_array($post_data[$key.$field_name][$i])) { |
|
109 | 109 | |
110 | 110 | switch ($condition->value_type) { |
111 | 111 | case 'Date': |
112 | - $post_data[$key . $field_name][$i] = base64_encode(serialize($post_data[$key . $field_name][$i])); |
|
112 | + $post_data[$key.$field_name][$i] = base64_encode(serialize($post_data[$key.$field_name][$i])); |
|
113 | 113 | break; |
114 | 114 | default: |
115 | - $post_data[$key . $field_name][$i] = encodeMultienumValue($post_data[$key . $field_name][$i]); |
|
115 | + $post_data[$key.$field_name][$i] = encodeMultienumValue($post_data[$key.$field_name][$i]); |
|
116 | 116 | } |
117 | - } else if ($field_name == 'value' && $post_data[$key . 'value_type'][$i] === 'Value') { |
|
118 | - $post_data[$key . $field_name][$i] = fixUpFormatting($_REQUEST['report_module'], $condition->field, $post_data[$key . $field_name][$i]); |
|
117 | + } else if ($field_name == 'value' && $post_data[$key.'value_type'][$i] === 'Value') { |
|
118 | + $post_data[$key.$field_name][$i] = fixUpFormatting($_REQUEST['report_module'], $condition->field, $post_data[$key.$field_name][$i]); |
|
119 | 119 | } else if ($field_name == 'parameter') { |
120 | - $post_data[$key . $field_name][$i] = isset($post_data[$key . $field_name][$i]); |
|
120 | + $post_data[$key.$field_name][$i] = isset($post_data[$key.$field_name][$i]); |
|
121 | 121 | } else if ($field_name == 'module_path') { |
122 | - $post_data[$key . $field_name][$i] = base64_encode(serialize(explode(":", $post_data[$key . $field_name][$i]))); |
|
122 | + $post_data[$key.$field_name][$i] = base64_encode(serialize(explode(":", $post_data[$key.$field_name][$i]))); |
|
123 | 123 | } |
124 | - if ($field_name == 'parenthesis' && $post_data[$key . $field_name][$i] == 'END') { |
|
124 | + if ($field_name == 'parenthesis' && $post_data[$key.$field_name][$i] == 'END') { |
|
125 | 125 | if (!isset($lastParenthesisStartConditionId)) { |
126 | 126 | throw new Exception('a closure parenthesis has no starter pair'); |
127 | 127 | } |
128 | 128 | $condition->parenthesis = $lastParenthesisStartConditionId; |
129 | 129 | } else { |
130 | - $condition->$field_name = $post_data[$key . $field_name][$i]; |
|
130 | + $condition->$field_name = $post_data[$key.$field_name][$i]; |
|
131 | 131 | } |
132 | 132 | } else if ($field_name == 'parameter') { |
133 | 133 | $condition->$field_name = 0; |
@@ -23,8 +23,7 @@ |
||
23 | 23 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
24 | 24 | if(isset($GLOBALS['log'])) { |
25 | 25 | $GLOBALS['log']->deprecated($deprecatedMessage); |
26 | - } |
|
27 | - else { |
|
26 | + } else { |
|
28 | 27 | trigger_error($deprecatedMessage, E_USER_DEPRECATED); |
29 | 28 | } |
30 | 29 | self::__construct($seed, $module, $subPanel, $options); |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
3 | +if (!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
4 | 4 | |
5 | 5 | class Jjwg_MapsViewQuick_Radius_Display extends SugarView { |
6 | 6 | |
@@ -11,9 +11,9 @@ discard block |
||
11 | 11 | /** |
12 | 12 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
13 | 13 | */ |
14 | - function Jjwg_MapsViewQuick_Radius_Display(){ |
|
14 | + function Jjwg_MapsViewQuick_Radius_Display() { |
|
15 | 15 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
16 | - if(isset($GLOBALS['log'])) { |
|
16 | + if (isset($GLOBALS['log'])) { |
|
17 | 17 | $GLOBALS['log']->deprecated($deprecatedMessage); |
18 | 18 | } |
19 | 19 | else { |
@@ -43,7 +43,9 @@ discard block |
||
43 | 43 | * Date: 06/03/15 |
44 | 44 | * Comments |
45 | 45 | */ |
46 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
46 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
47 | + die('Not A Valid Entry Point'); |
|
48 | +} |
|
47 | 49 | |
48 | 50 | class CasesController extends SugarController { |
49 | 51 | |
@@ -90,8 +92,7 @@ discard block |
||
90 | 92 | $count++; |
91 | 93 | } |
92 | 94 | echo '</table>'; |
93 | - } |
|
94 | - else { |
|
95 | + } else { |
|
95 | 96 | echo $mod_strings['LBL_NO_SUGGESTIONS']; |
96 | 97 | } |
97 | 98 | die(); |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
3 | +if (!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
4 | 4 | |
5 | 5 | class Jjwg_MapsViewGeocoded_Counts extends SugarView { |
6 | 6 | |
@@ -11,9 +11,9 @@ discard block |
||
11 | 11 | /** |
12 | 12 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
13 | 13 | */ |
14 | - function Jjwg_MapsViewGeocoded_Counts(){ |
|
14 | + function Jjwg_MapsViewGeocoded_Counts() { |
|
15 | 15 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
16 | - if(isset($GLOBALS['log'])) { |
|
16 | + if (isset($GLOBALS['log'])) { |
|
17 | 17 | $GLOBALS['log']->deprecated($deprecatedMessage); |
18 | 18 | } |
19 | 19 | else { |
@@ -43,7 +43,9 @@ discard block |
||
43 | 43 | * Date: 06/03/15 |
44 | 44 | * Comments |
45 | 45 | */ |
46 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
46 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
47 | + die('Not A Valid Entry Point'); |
|
48 | +} |
|
47 | 49 | |
48 | 50 | class CasesController extends SugarController { |
49 | 51 | |
@@ -90,8 +92,7 @@ discard block |
||
90 | 92 | $count++; |
91 | 93 | } |
92 | 94 | echo '</table>'; |
93 | - } |
|
94 | - else { |
|
95 | + } else { |
|
95 | 96 | echo $mod_strings['LBL_NO_SUGGESTIONS']; |
96 | 97 | } |
97 | 98 | die(); |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
3 | +if (!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
4 | 4 | |
5 | 5 | class Jjwg_MapsViewQuick_Radius extends SugarView { |
6 | 6 | |
@@ -11,9 +11,9 @@ discard block |
||
11 | 11 | /** |
12 | 12 | * @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead |
13 | 13 | */ |
14 | - function Jjwg_MapsViewQuick_Radius(){ |
|
14 | + function Jjwg_MapsViewQuick_Radius() { |
|
15 | 15 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
16 | - if(isset($GLOBALS['log'])) { |
|
16 | + if (isset($GLOBALS['log'])) { |
|
17 | 17 | $GLOBALS['log']->deprecated($deprecatedMessage); |
18 | 18 | } |
19 | 19 | else { |
@@ -1,6 +1,8 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
3 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
4 | + die('Not A Valid Entry Point'); |
|
5 | +} |
|
4 | 6 | |
5 | 7 | class Jjwg_MapsViewQuick_Radius extends SugarView { |
6 | 8 | |
@@ -15,8 +17,7 @@ discard block |
||
15 | 17 | $deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code'; |
16 | 18 | if(isset($GLOBALS['log'])) { |
17 | 19 | $GLOBALS['log']->deprecated($deprecatedMessage); |
18 | - } |
|
19 | - else { |
|
20 | + } else { |
|
20 | 21 | trigger_error($deprecatedMessage, E_USER_DEPRECATED); |
21 | 22 | } |
22 | 23 | self::__construct(); |
@@ -25,8 +26,10 @@ discard block |
||
25 | 26 | |
26 | 27 | function display() { |
27 | 28 | |
28 | - if (!isset($_REQUEST['quick_address'])) $_REQUEST['quick_address'] = ''; |
|
29 | -?> |
|
29 | + if (!isset($_REQUEST['quick_address'])) { |
|
30 | + $_REQUEST['quick_address'] = ''; |
|
31 | + } |
|
32 | + ?> |
|
30 | 33 | |
31 | 34 | <div class="moduleTitle"><h2><?php echo $GLOBALS['mod_strings']['LBL_MAP_QUICK_RADIUS']; ?><div class="clear"></div></h2></div> |
32 | 35 | <div class="clear"></div> |
@@ -53,7 +56,9 @@ discard block |
||
53 | 56 | <select id="display_module" tabindex="111" title="<?php echo $GLOBALS['mod_strings']['LBL_MODULE_TYPE']; ?>" name="display_module"> |
54 | 57 | <?php foreach ($GLOBALS['jjwg_config']['valid_geocode_modules'] as $module) { ?> |
55 | 58 | <option value="<?php echo htmlspecialchars($module); ?>" <?php |
56 | - if (!empty($_REQUEST['display_module']) && $module == $_REQUEST['display_module']) echo 'selected="selected"'; |
|
59 | + if (!empty($_REQUEST['display_module']) && $module == $_REQUEST['display_module']) { |
|
60 | + echo 'selected="selected"'; |
|
61 | + } |
|
57 | 62 | ?>><?php echo htmlspecialchars($GLOBALS['app_list_strings']['moduleList'][$module]); ?> |
58 | 63 | <?php } ?> |
59 | 64 | </select> |
@@ -69,7 +74,9 @@ discard block |
||
69 | 74 | <select id="unit_type" tabindex="131" title="<?php echo $GLOBALS['mod_strings']['LBL_DISTANCE']; ?>" name="unit_type"> |
70 | 75 | <?php foreach ($GLOBALS['app_list_strings']['map_unit_type_list'] as $key=>$value) { ?> |
71 | 76 | <option value="<?php echo htmlspecialchars($key); ?>" <?php |
72 | - if ($key == $_REQUEST['unit_type']) echo 'selected="selected"'; |
|
77 | + if ($key == $_REQUEST['unit_type']) { |
|
78 | + echo 'selected="selected"'; |
|
79 | + } |
|
73 | 80 | ?>><?php echo htmlspecialchars($value); ?> |
74 | 81 | <?php } ?> |
75 | 82 | </select> |