Passed
Push — master ( f28cef...79d87e )
by Alexey
04:47
created
system/modules/Dashboard/appAdminControllers/content/index.php 1 patch
Indentation   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -2,18 +2,18 @@
 block discarded – undo
2 2
     <h4 class ='dashboard-widgets-welcome'>Добро Пожаловать в панель управления<?= class_exists('\Users\User') ? ', ' . \Users\User::$cur->name() : ''; ?></h4>
3 3
     <div class = "row">
4 4
       <?php
5
-      $rowSum = 0;
6
-      foreach ($sections as $section) {
7
-          if (empty($section['widget'])) {
8
-              continue;
9
-          }
10
-          if (isset($section['accessCheck']) && !$section['accessCheck']()) {
11
-              continue;
12
-          }
5
+        $rowSum = 0;
6
+        foreach ($sections as $section) {
7
+            if (empty($section['widget'])) {
8
+                continue;
9
+            }
10
+            if (isset($section['accessCheck']) && !$section['accessCheck']()) {
11
+                continue;
12
+            }
13 13
 
14
-          $widgetSize = !empty($section['size']) ? $section['size'] : 1;
15
-          $rowSum += $widgetSize;
16
-          ?>
14
+            $widgetSize = !empty($section['size']) ? $section['size'] : 1;
15
+            $rowSum += $widgetSize;
16
+            ?>
17 17
             <div class="col-sm-<?= $widgetSize * 4; ?>" style="margin-bottom: 10px;"><?= $section['widget'](); ?></div>
18 18
             <?php
19 19
             if ($rowSum >= 3) {
Please login to merge, or discard this patch.
system/modules/Ecommerce/widgets/filters.php 1 patch
Indentation   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -1,10 +1,10 @@  discard block
 block discarded – undo
1 1
 <div class="filters">
2 2
     <form>
3 3
       <?php
4
-      $min = App::$cur->ecommerce->getItems(['sort' => ['price' => 'asc'], 'count' => 1, 'key' => false]);
5
-      $max = App::$cur->ecommerce->getItems(['sort' => ['price' => 'desc'], 'count' => 1, 'key' => false]);
6
-      if ($min && $min[0]->getPrice() && $max && $max[0]->getPrice()) {
7
-          ?>
4
+        $min = App::$cur->ecommerce->getItems(['sort' => ['price' => 'asc'], 'count' => 1, 'key' => false]);
5
+        $max = App::$cur->ecommerce->getItems(['sort' => ['price' => 'desc'], 'count' => 1, 'key' => false]);
6
+        if ($min && $min[0]->getPrice() && $max && $max[0]->getPrice()) {
7
+            ?>
8 8
             <label>Фильтр по цене</label>
9 9
             <div class="form-group">      
10 10
                 <div class="row">
@@ -18,24 +18,24 @@  discard block
 block discarded – undo
18 18
             ?>
19 19
             <div class="filter">  
20 20
               <?php
21
-              switch ($option->type) {
22
-                  case 'radio':
21
+                switch ($option->type) {
22
+                    case 'radio':
23 23
                       echo "<label>{$option->name}</label>";
24
-                      foreach ($option->items(['order' => ['value', 'asc']]) as $item) {
25
-                          $this->widget('Ui\Form/' . $option->type, [
26
-                              'label' => $item->name,
27
-                              'name' => "filters[options][{$option->id}]",
28
-                              !empty($_GET['filters']['options'][$option->id]) && $_GET['filters']['options'][$option->id] == $item->id ? 'checked' : false,
29
-                              'options' => [
30
-                                  'value' => $item->id,
31
-                              ]
32
-                          ]);
33
-                      }
34
-                      break;
35
-                  case 'select':
24
+                        foreach ($option->items(['order' => ['value', 'asc']]) as $item) {
25
+                            $this->widget('Ui\Form/' . $option->type, [
26
+                                'label' => $item->name,
27
+                                'name' => "filters[options][{$option->id}]",
28
+                                !empty($_GET['filters']['options'][$option->id]) && $_GET['filters']['options'][$option->id] == $item->id ? 'checked' : false,
29
+                                'options' => [
30
+                                    'value' => $item->id,
31
+                                ]
32
+                            ]);
33
+                        }
34
+                        break;
35
+                    case 'select':
36 36
                       echo "<label>{$option->name}</label>";
37
-                      foreach ($option->items(['order' => ['value', 'asc']]) as $item) {
38
-                          ?>
37
+                        foreach ($option->items(['order' => ['value', 'asc']]) as $item) {
38
+                            ?>
39 39
                             <div class="radio">
40 40
                                 <label>
41 41
                                     <input type="checkbox" name = 'filters[options][<?= $option->id; ?>][]' value ="<?= $item->id; ?>" <?= !empty($_GET['filters']['options'][$option->id]) && in_array($item->id, $_GET['filters']['options'][$option->id]) ? 'checked' : ''; ?>>
Please login to merge, or discard this patch.