Passed
Push — develop ( a502d1...3b05d1 )
by Mykola
08:37
created
administration/controller/design/custommenu.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
 
126 126
         foreach ($custommenus as $id => $custommenu) {
127 127
             $rent_custommenu[] = array(
128
-                'name'          => $custommenu['name'] ,
128
+                'name'          => $custommenu['name'],
129 129
                 'custommenu_id'       => $custommenu['custommenu_id'],
130 130
                 'custommenu_type'     => $custommenu['custommenu_type'],
131 131
                 'status'        => $custommenu['status'],
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
         $html  = '<li id="custommenu-item-' . $custommenu['custommenu_id'] . '" class="custommenu-item custommenu-item-depth-0 custommenu-item-page custommenu-item-edit-inactive pending">';
227 227
         $html .= '	<dl class="custommenu-item-bar">';
228 228
         $html .= '		<dt class="custommenu-item-handle">';
229
-        $html .= '			<span class="item-title"><span class="custommenu-item-title">' . $custommenu['name'] .'</span> <span class="is-subcustommenu" style="display: none;">' . $this->language->get('text_sub_item') . '</span></span>';
229
+        $html .= '			<span class="item-title"><span class="custommenu-item-title">' . $custommenu['name'] . '</span> <span class="is-subcustommenu" style="display: none;">' . $this->language->get('text_sub_item') . '</span></span>';
230 230
         $html .= '          <span class="item-controls">';
231 231
         $html .= '			<span class="item-type">' . ucwords($custommenu['custommenu_type']) . '</span>';
232 232
         $html .= '				<a class="item-edit opencustommenuItem ' . $custommenu['custommenu_type'] . '" id="edit-' . $custommenu['custommenu_id'] . '" title="">';
@@ -243,7 +243,7 @@  discard block
 block discarded – undo
243 243
 
244 244
         foreach ($languages as $language) {
245 245
             $html .= '<div class="input-group"><span class="input-group-addon"><img src="language/' . $language["code"] . '/' . $language["code"] . '.png' . '" title="' . $language["name"] . '"/></span>';
246
-            $html .= '   <input type="text" name="custommenu_name[' . $language['language_id'] . ']" value="' . $custommenu_desc[$custommenu['custommenu_id']][$language['language_id']]['name']. '" placeholder="' . $this->language->get('text_custommenu_name') . '" class="form-control" />';
246
+            $html .= '   <input type="text" name="custommenu_name[' . $language['language_id'] . ']" value="' . $custommenu_desc[$custommenu['custommenu_id']][$language['language_id']]['name'] . '" placeholder="' . $this->language->get('text_custommenu_name') . '" class="form-control" />';
247 247
             $html .= '</div>';
248 248
         }
249 249
         $html .= '<br>';
@@ -266,15 +266,15 @@  discard block
 block discarded – undo
266 266
         $html .= '</div>';
267 267
         $html .= '<br>';
268 268
         $html .= '<div class="pull-right">';
269
-        $html .= ' <a id="disablecustommenu-'. $count . '" onclick="statuscustommenu(\'disable\', \'' . $custommenu['custommenu_id'] . '\', \'custommenu-item-' . $custommenu['custommenu_id'] . '\', \'disablecustommenu-' . $count .'\')" data-type="iframe" style="top:2px!important;font-size:1.2em !important;" title="' . $this->language->get('button_disable') . '" class="btn btn-danger btn-xs btn-edit btn-group"><i class="fa fa-times-circle"></i></a>';
269
+        $html .= ' <a id="disablecustommenu-' . $count . '" onclick="statuscustommenu(\'disable\', \'' . $custommenu['custommenu_id'] . '\', \'custommenu-item-' . $custommenu['custommenu_id'] . '\', \'disablecustommenu-' . $count . '\')" data-type="iframe" style="top:2px!important;font-size:1.2em !important;" title="' . $this->language->get('button_disable') . '" class="btn btn-danger btn-xs btn-edit btn-group"><i class="fa fa-times-circle"></i></a>';
270 270
         $html .= ' <a onclick="savecustommenu(\'custommenu-item-settings-edit-' . $custommenu['custommenu_id'] . '\', \'custommenu-item-' . $custommenu['custommenu_id'] . '\')" data-type="iframe" style="top:2px!important;font-size:1.2em !important;" title="' . $this->language->get('button_save') . '" class="btn btn-success btn-xs btn-edit btn-group"><i class="fa fa-save"></i></a>';
271 271
         $html .= ' <button type="button" title="" style="top:2px!important;font-size:1.2em !important;" class="btn btn-danger btn-xs btn-edit btn-group btn-loading" onclick="confirm(\'Are you sure?\') ? deletecustommenu(\'' . $custommenu['custommenu_id'] . '\', \'custommenu-item-' . $custommenu['custommenu_id'] . '\') : false;" data-original-title="Delete"><i class="fa fa-trash-o"></i></button>';
272 272
         $html .= '</div>';
273 273
         $html .= '<br><br>';
274 274
 
275
-        $html .= '<input class="custommenu-item-data-typecustommenu" type="hidden" name="custommenu-item-typecustommenu[Maincustommenu-' . $custommenu['custommenu_id'].']" value="Maincustommenu">';
275
+        $html .= '<input class="custommenu-item-data-typecustommenu" type="hidden" name="custommenu-item-typecustommenu[Maincustommenu-' . $custommenu['custommenu_id'] . ']" value="Maincustommenu">';
276 276
         $html .= '<input class="custommenu-item-data-db-id" type="hidden" name="custommenu-item-db-id[Maincustommenu-' . $custommenu['custommenu_id'] . ']" value="' . $custommenu['custommenu_id'] . '">';
277
-        $html .= '<input class="custommenu-item-data-parent-id" type="hidden" name="custommenu-item-parent-id[Maincustommenu-' . $custommenu['custommenu_id'] .']" value="0">';
277
+        $html .= '<input class="custommenu-item-data-parent-id" type="hidden" name="custommenu-item-parent-id[Maincustommenu-' . $custommenu['custommenu_id'] . ']" value="0">';
278 278
         $html .= '<input class="custommenu-item-data-position" type="hidden" name="custommenu-item-position[Maincustommenu-' . $custommenu['custommenu_id'] . ']" value="' . $custommenu['custommenu_id'] . '">';
279 279
         $html .= '<input class="custommenu-item-data-type" type="hidden" name="custommenu-item-type[Maincustommenu-' . $custommenu['custommenu_id'] . ']" value="post_type">';
280 280
 
@@ -365,7 +365,7 @@  discard block
 block discarded – undo
365 365
 
366 366
         $id = explode('-', $this->request->post['id']);
367 367
 
368
-        $button = "<a id=\"disablecustommenu-" . $id[1] . "\" onclick=\"statuscustommenu('disable', '" . $this->request->post['custommenu_id'] . "', 'custommenu-item-" .  $this->request->post['custommenu_id'] . "', 'disablecustommenu-" . $id[1] . "')\" data-type=\"iframe\" data-toggle=\"tooltip\" style=\"top:2px!important;font-size:1.2em !important;\" title=\"\" class=\"btn btn-danger btn-xs btn-edit btn-group\"><i class=\"fa fa-times-circle\"></i></a>";
368
+        $button = "<a id=\"disablecustommenu-" . $id[1] . "\" onclick=\"statuscustommenu('disable', '" . $this->request->post['custommenu_id'] . "', 'custommenu-item-" . $this->request->post['custommenu_id'] . "', 'disablecustommenu-" . $id[1] . "')\" data-type=\"iframe\" data-toggle=\"tooltip\" style=\"top:2px!important;font-size:1.2em !important;\" title=\"\" class=\"btn btn-danger btn-xs btn-edit btn-group\"><i class=\"fa fa-times-circle\"></i></a>";
369 369
 
370 370
         echo $button;
371 371
         exit();
@@ -384,7 +384,7 @@  discard block
 block discarded – undo
384 384
 
385 385
         $id = explode('-', $this->request->post['id']);
386 386
 
387
-        $button = "<a id=\"enablecustommenu-" . $id[1] . "\" onclick=\"statuscustommenu('enable', '" . $this->request->post['custommenu_id'] . "', 'custommenu-item-" .  $this->request->post['custommenu_id'] . "', 'enablecustommenu-" . $id[1] . "')\" data-type=\"iframe\" data-toggle=\"tooltip\" style=\"top:2px!important;font-size:1.2em !important;\" title=\"\" class=\"btn btn-success btn-xs btn-edit btn-group\"><i class=\"fa fa-check-circle\"></i></a>";
387
+        $button = "<a id=\"enablecustommenu-" . $id[1] . "\" onclick=\"statuscustommenu('enable', '" . $this->request->post['custommenu_id'] . "', 'custommenu-item-" . $this->request->post['custommenu_id'] . "', 'enablecustommenu-" . $id[1] . "')\" data-type=\"iframe\" data-toggle=\"tooltip\" style=\"top:2px!important;font-size:1.2em !important;\" title=\"\" class=\"btn btn-success btn-xs btn-edit btn-group\"><i class=\"fa fa-check-circle\"></i></a>";
388 388
 
389 389
         echo $button;
390 390
         exit();
@@ -403,7 +403,7 @@  discard block
 block discarded – undo
403 403
 
404 404
         $id = explode('-', $this->request->post['id']);
405 405
 
406
-        $button = "<a id=\"disablecustommenu-" . $id[1] . "\" onclick=\"statuscustommenu('disable', '" . $this->request->post['custommenu_id'] . "', 'custommenu-child-item-" .  $this->request->post['custommenu_id'] . "', 'disablecustommenu-" . $id[1] . "')\" data-type=\"iframe\" data-toggle=\"tooltip\" style=\"top:2px!important;font-size:1.2em !important;\" title=\"\" class=\"btn btn-danger btn-xs btn-edit btn-group\"><i class=\"fa fa-times-circle\"></i></a>";
406
+        $button = "<a id=\"disablecustommenu-" . $id[1] . "\" onclick=\"statuscustommenu('disable', '" . $this->request->post['custommenu_id'] . "', 'custommenu-child-item-" . $this->request->post['custommenu_id'] . "', 'disablecustommenu-" . $id[1] . "')\" data-type=\"iframe\" data-toggle=\"tooltip\" style=\"top:2px!important;font-size:1.2em !important;\" title=\"\" class=\"btn btn-danger btn-xs btn-edit btn-group\"><i class=\"fa fa-times-circle\"></i></a>";
407 407
 
408 408
         echo $button;
409 409
         exit();
@@ -422,7 +422,7 @@  discard block
 block discarded – undo
422 422
 
423 423
         $id = explode('-', $this->request->post['id']);
424 424
 
425
-        $button = "<a id=\"enablecustommenu-" . $id[1] . "\" onclick=\"statuscustommenu('enable', '" . $this->request->post['custommenu_id'] . "', 'custommenu-child-item-" .  $this->request->post['custommenu_id'] . "', 'enablecustommenu-" . $id[1] . "')\" data-type=\"iframe\" data-toggle=\"tooltip\" style=\"top:2px!important;font-size:1.2em !important;\" title=\"\" class=\"btn btn-success btn-xs btn-edit btn-group\"><i class=\"fa fa-check-circle\"></i></a>";
425
+        $button = "<a id=\"enablecustommenu-" . $id[1] . "\" onclick=\"statuscustommenu('enable', '" . $this->request->post['custommenu_id'] . "', 'custommenu-child-item-" . $this->request->post['custommenu_id'] . "', 'enablecustommenu-" . $id[1] . "')\" data-type=\"iframe\" data-toggle=\"tooltip\" style=\"top:2px!important;font-size:1.2em !important;\" title=\"\" class=\"btn btn-success btn-xs btn-edit btn-group\"><i class=\"fa fa-check-circle\"></i></a>";
426 426
 
427 427
         echo $button;
428 428
         exit();
Please login to merge, or discard this patch.
administration/controller/design/layout.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -234,7 +234,7 @@  discard block
 block discarded – undo
234 234
         }
235 235
 
236 236
         if (isset($this->request->post['selected'])) {
237
-            $data['selected'] = (array) $this->request->post['selected'];
237
+            $data['selected'] = (array)$this->request->post['selected'];
238 238
         } else {
239 239
             $data['selected'] = array();
240 240
         }
@@ -396,7 +396,7 @@  discard block
 block discarded – undo
396 396
             foreach ($modules as $module) {
397 397
                 $module_data[] = array(
398 398
                     'name' => strip_tags($module['name']),
399
-                    'code' => $code . '.' .  $module['module_id']
399
+                    'code' => $code . '.' . $module['module_id']
400 400
                 );
401 401
             }
402 402
 
Please login to merge, or discard this patch.
administration/model/extension/module.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
             UPDATE `module` 
39 39
             SET `name` = '" . $this->db->escape($data['name']) . "', 
40 40
                 `setting` = '" . $this->db->escape(json_encode($data)) . "' 
41
-            WHERE `module_id` = '" . (int) $module_id . "'
41
+            WHERE `module_id` = '" . (int)$module_id . "'
42 42
         ");
43 43
     }
44 44
 
@@ -47,12 +47,12 @@  discard block
 block discarded – undo
47 47
         $this->db->query("
48 48
             DELETE 
49 49
             FROM `module` 
50
-            WHERE `module_id` = '" . (int) $module_id . "'
50
+            WHERE `module_id` = '" . (int)$module_id . "'
51 51
         ");
52 52
         $this->db->query("
53 53
             DELETE 
54 54
             FROM `layout_module` 
55
-            WHERE `code` LIKE '%." . (int) $module_id . "'
55
+            WHERE `code` LIKE '%." . (int)$module_id . "'
56 56
         ");
57 57
     }
58 58
 
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
     {
61 61
         $query = $this->db->query("
62 62
             SELECT * FROM `module` 
63
-            WHERE `module_id` = '" . (int) $module_id . "'
63
+            WHERE `module_id` = '" . (int)$module_id . "'
64 64
         ");
65 65
 
66 66
         if ($query->row) {
Please login to merge, or discard this patch.
administration/model/catalog/product.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -56,20 +56,20 @@  discard block
 block discarded – undo
56 56
             foreach ($data['product_tab'] as $tabdata) {
57 57
                 $this->db->query("
58 58
                     INSERT INTO product_tab 
59
-                    SET product_id = '".(int)$product_id."', 
60
-                        status = '".(int)$tabdata['status']."', 
61
-                        sort_order='".(int)$tabdata['sort_order']."'
59
+                    SET product_id = '".(int)$product_id . "', 
60
+                        status = '".(int)$tabdata['status'] . "', 
61
+                        sort_order='".(int)$tabdata['sort_order'] . "'
62 62
                 ");
63 63
             
64 64
                 $product_tab_id = $this->db->getLastId();
65 65
                 foreach ($tabdata['description'] as $language_id => $value) {
66 66
                     $this->db->query("
67 67
                         INSERT INTO product_tab_desc 
68
-                        SET product_tab_id = '".(int)$product_tab_id."', 
69
-                            heading = '".$this->db->escape($value['heading'])."', 
70
-                            description = '".$this->db->escape($value['description'])."', 
71
-                            product_id = '".(int)$product_id."', 
72
-                            language_id = '".(int)$language_id."'
68
+                        SET product_tab_id = '".(int)$product_tab_id . "', 
69
+                            heading = '".$this->db->escape($value['heading']) . "', 
70
+                            description = '".$this->db->escape($value['description']) . "', 
71
+                            product_id = '".(int)$product_id . "', 
72
+                            language_id = '".(int)$language_id . "'
73 73
                     ");
74 74
                 }
75 75
             }
@@ -410,9 +410,9 @@  discard block
 block discarded – undo
410 410
             foreach ($data['product_tab'] as $tabdata) {
411 411
                 $this->db->query("
412 412
                     INSERT INTO product_tab 
413
-                    SET product_id = '".(int)$product_id."', 
414
-                        status = '". (int)$tabdata['status']."', 
415
-                        sort_order='". (int)$tabdata['sort_order']."'
413
+                    SET product_id = '".(int)$product_id . "', 
414
+                        status = '". (int)$tabdata['status'] . "', 
415
+                        sort_order='". (int)$tabdata['sort_order'] . "'
416 416
                 ");
417 417
         
418 418
                 $product_tab_id = $this->db->getLastId();
@@ -420,11 +420,11 @@  discard block
 block discarded – undo
420 420
                 foreach ($tabdata['description'] as $language_id => $value) {
421 421
                     $this->db->query("
422 422
                         INSERT INTO product_tab_desc 
423
-                        SET product_tab_id = '".(int)$product_tab_id."', 
424
-                            heading = '".$this->db->escape($value['heading'])."', 
425
-                            description = '".$this->db->escape($value['description'])."', 
426
-                            product_id = '".(int)$product_id."', 
427
-                            language_id = '".(int)$language_id."'
423
+                        SET product_tab_id = '".(int)$product_tab_id . "', 
424
+                            heading = '".$this->db->escape($value['heading']) . "', 
425
+                            description = '".$this->db->escape($value['description']) . "', 
426
+                            product_id = '".(int)$product_id . "', 
427
+                            language_id = '".(int)$language_id . "'
428 428
                     ");
429 429
                 }
430 430
             }
@@ -1002,15 +1002,15 @@  discard block
 block discarded – undo
1002 1002
             $querys = $this->db->query("
1003 1003
                 SELECT * 
1004 1004
                 FROM product_tab_desc 
1005
-                WHERE product_tab_id = '" . (int)$result['product_tab_id']. "'
1005
+                WHERE product_tab_id = '" . (int)$result['product_tab_id'] . "'
1006 1006
             ");
1007 1007
             foreach ($querys->rows as $row) {
1008
-                $description[$row['language_id']]=array(
1008
+                $description[$row['language_id']] = array(
1009 1009
                         'heading' 	  => $row['heading'],
1010 1010
                         'description' => $row['description'],
1011 1011
                     );
1012 1012
             }
1013
-            $product_tab_data[]=array(
1013
+            $product_tab_data[] = array(
1014 1014
                     'status' 	 => $result['status'],
1015 1015
                     'sort_order' => $result['sort_order'],
1016 1016
                     'description' => $description,
@@ -1488,7 +1488,7 @@  discard block
 block discarded – undo
1488 1488
     {
1489 1489
         $benefits = array();
1490 1490
     
1491
-        $query  =  $this->db->query("
1491
+        $query = $this->db->query("
1492 1492
             SELECT benefit_id 
1493 1493
             FROM `product_to_benefit` 
1494 1494
             WHERE product_id = 
Please login to merge, or discard this patch.
administration/model/design/benefit.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -187,7 +187,7 @@
 block discarded – undo
187 187
         $query = $this->db->query("
188 188
 			SELECT COUNT(*) AS total 
189 189
 			FROM product_to_benefit 
190
-			WHERE benefit_id IN (". $selected .")
190
+			WHERE benefit_id IN (". $selected . ")
191 191
 		");
192 192
 
193 193
         return $query->row['total'];
Please login to merge, or discard this patch.
administration/model/design/custommenu.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -92,34 +92,34 @@  discard block
 block discarded – undo
92 92
             $link = (int)$data['id'];
93 93
 
94 94
             if ($data['type'] == 'information') {
95
-                $fields = 'title AS name, '.$data['type'].'_id, language_id';
95
+                $fields = 'title AS name, ' . $data['type'] . '_id, language_id';
96 96
             } else {
97
-                $fields = 'name, '.$data['type'].'_id, language_id';
97
+                $fields = 'name, ' . $data['type'] . '_id, language_id';
98 98
             }
99 99
         
100 100
             if ($data['type'] != 'manufacturer') {
101 101
                 $query = $this->db->query("
102 102
                     SELECT " . $fields . " F
103 103
                     ROM " . $data['type'] . "_description 
104
-                    WHERE ". $data['type'] ."_id = '" . (int)$data['id'] . "'
104
+                    WHERE ". $data['type'] . "_id = '" . (int)$data['id'] . "'
105 105
                 ");
106 106
 
107 107
                 $data['custommenu_desc'] = $query->rows;
108 108
             } else {
109
-                $fields = 'name, '.$data['type'].'_id ';
109
+                $fields = 'name, ' . $data['type'] . '_id ';
110 110
                 
111 111
                 $query = $this->db->query("
112 112
                     SELECT " . $fields . " 
113 113
                     FROM " . $data['type'] . " 
114
-                    WHERE ". $data['type'] ."_id = '" . (int)$data['id'] . "'
114
+                    WHERE ". $data['type'] . "_id = '" . (int)$data['id'] . "'
115 115
                 ");
116
-                $result  = array();
116
+                $result = array();
117 117
 
118 118
                 foreach ($languages as $language) {
119 119
                     $result[] = array('name' => $query->row['name'], 'manufacturer_id' => $query->row['manufacturer_id'], 'language_id' => $language['language_id']);
120 120
                 };
121 121
 
122
-                $data['custommenu_desc'] =  $result;
122
+                $data['custommenu_desc'] = $result;
123 123
             }
124 124
         }
125 125
 
@@ -416,7 +416,7 @@  discard block
 block discarded – undo
416 416
 
417 417
                 $this->db->query("
418 418
                     INSERT INTO custommenu_child 
419
-                    SET custommenu_id = '" . $data['custommenu-item-parent-id'][$key] ."', s
419
+                    SET custommenu_id = '" . $data['custommenu-item-parent-id'][$key] . "', s
420 420
                         ort_order = '" . (int)$insertData->row['sort_order'] . "', 
421 421
                         custommenu_type = '" . $insertData->row['custommenu_type'] . "', 
422 422
                         status = '1'
Please login to merge, or discard this patch.
administration/model/design/sticker.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -166,7 +166,7 @@
 block discarded – undo
166 166
         $query = $this->db->query("
167 167
 			SELECT COUNT(*) AS total 
168 168
 			FROM product_to_sticker 
169
-			WHERE sticker_id IN (". $selected .")
169
+			WHERE sticker_id IN (". $selected . ")
170 170
 		");
171 171
 
172 172
         return $query->row['total'];
Please login to merge, or discard this patch.
administration/language/en-gb/tool/log.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -21,10 +21,10 @@
 block discarded – undo
21 21
     along with this program. If not, see <http://www.gnu.org/licenses/>. */
22 22
 
23 23
 // Heading
24
-$_['heading_title']	   = 'Error Log';
24
+$_['heading_title'] = 'Error Log';
25 25
 
26 26
 // Text
27
-$_['text_success']	   = 'Success: You have successfully cleared your error log!';
27
+$_['text_success'] = 'Success: You have successfully cleared your error log!';
28 28
 $_['text_list']        = 'Errors List';
29 29
 
30 30
 // Error
Please login to merge, or discard this patch.
administration/language/en-gb/tool/updater.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,4 +31,4 @@
 block discarded – undo
31 31
 
32 32
 
33 33
 // Error
34
-$_['error_permission']          = 'Warning: You do not have permission to modify updater!';
34
+$_['error_permission'] = 'Warning: You do not have permission to modify updater!';
Please login to merge, or discard this patch.