Completed
Push — master ( 913952...f8c7e1 )
by Alexey
06:23
created
system/modules/Ecommerce/models/Card/Item.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -79,7 +79,7 @@
 block discarded – undo
79 79
 
80 80
     public function name()
81 81
     {
82
-        return $this->code ? $this->code : $this->id . ' - ' . $this->user->name();
82
+        return $this->code ? $this->code : $this->id.' - '.$this->user->name();
83 83
     }
84 84
 
85 85
 }
Please login to merge, or discard this patch.
system/modules/Ecommerce/models/Cart/Item.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
                     $event->save();
32 32
                 }
33 33
                 if ($cur->count != $this->count) {
34
-                    $event = new Event(['cart_id' => $this->cart->cart_id, 'user_id' => \Users\User::$cur->id, 'cart_event_type_id' => 4, 'info' => $this->item_offer_price_id . "|" . ($this->count - $cur->count)]);
34
+                    $event = new Event(['cart_id' => $this->cart->cart_id, 'user_id' => \Users\User::$cur->id, 'cart_event_type_id' => 4, 'info' => $this->item_offer_price_id."|".($this->count - $cur->count)]);
35 35
                     $event->save();
36 36
                 }
37 37
             }
Please login to merge, or discard this patch.
system/modules/Ecommerce/appAdminControllers/EcommerceController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -74,8 +74,8 @@
 block discarded – undo
74 74
                 unset($items[$key]);
75 75
                 unset($item);
76 76
             }
77
-            echo 'Происходит процесс индексации: проиндексировано ' . $i * $count;
78
-            Tools::redirect('/admin/ecommerce/reSearchIndex/' . $i);
77
+            echo 'Происходит процесс индексации: проиндексировано '.$i * $count;
78
+            Tools::redirect('/admin/ecommerce/reSearchIndex/'.$i);
79 79
         }
80 80
     }
81 81
 
Please login to merge, or discard this patch.
system/modules/Ecommerce/widgets/admin/contacts.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -16,11 +16,11 @@
 block discarded – undo
16 16
                         "mode": "",
17 17
                         "all": false,
18 18
                         "relation": "infos"}
19
-              )'><?= $count . ' ' . Tools::getNumEnding($count, ['Элемент', 'Элемента', 'Элементов']); ?></a>
19
+              )'><?= $count.' '.Tools::getNumEnding($count, ['Элемент', 'Элемента', 'Элементов']); ?></a>
20 20
     <?php
21 21
 } else {
22 22
     foreach ($item->infos as $info) {
23
-        echo $info->value . ' ';
23
+        echo $info->value.' ';
24 24
     }
25 25
 }
26 26
 ?>
27 27
\ No newline at end of file
Please login to merge, or discard this patch.
system/modules/Ecommerce/widgets/cart/cardSelect.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
 $userCards = \Ecommerce\Card\Item::getList(['where' => ['user_id', \Users\User::$cur->id]]);
4 4
 foreach ($userCards as $userCard) {
5 5
     $checked = $cart->card_item_id == $userCard->id;
6
-    $form->input('radio', "discounts[card_item_id]", $userCard->card->name, ['value' => $userCard->id, 'checked' => $checked, 'helpText' => $userCard->level->name . ' (' . $userCard->level->discount->name . ')<br />Сумма накоплений: ' . $userCard->sum . ' руб.']);
6
+    $form->input('radio', "discounts[card_item_id]", $userCard->card->name, ['value' => $userCard->id, 'checked' => $checked, 'helpText' => $userCard->level->name.' ('.$userCard->level->discount->name.')<br />Сумма накоплений: '.$userCard->sum.' руб.']);
7 7
 }
8 8
 if (!$userCards) {
9 9
     echo '<p>У вас нет <b>дисконтной карты</b>, вы можете её оформить и сразу начать пльзоваться её приемуществами.</p>';
Please login to merge, or discard this patch.
system/modules/Ecommerce/objects/CloseCartBtn.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@
 block discarded – undo
49 49
             $cart->save();
50 50
         }
51 51
         $count = count($carts);
52
-        return 'Завершено <b>' . $count . '</b> ' . \Tools::getNumEnding($count, ['корзина', 'корзины', 'корзин']);
52
+        return 'Завершено <b>'.$count.'</b> '.\Tools::getNumEnding($count, ['корзина', 'корзины', 'корзин']);
53 53
     }
54 54
 
55 55
 }
Please login to merge, or discard this patch.
system/modules/Ecommerce/snippets/payTypeHandler/onlinePay.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@  discard block
 block discarded – undo
20 20
                         'currency_id' => $currency_id,
21 21
                         'user_id' => \Users\User::$cur->id,
22 22
                         'sum' => $sum,
23
-                        'description' => 'Оплата заказа №' . $cart->id . ' в онлайн-магазине',
23
+                        'description' => 'Оплата заказа №'.$cart->id.' в онлайн-магазине',
24 24
                         'type' => 'pay',
25 25
                         'pay_status_id' => 1,
26 26
                         'callback_module' => 'Ecommerce',
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
                     $pay->save();
33 33
                 }
34 34
             }
35
-            return ['/money/merchants/pay/?data=' . $cart->id, 'Ваш заказ был создан. Вам необходимо оплатить счета, после чего с вами свяжется администратор для уточнения дополнительной информации', 'success'];
35
+            return ['/money/merchants/pay/?data='.$cart->id, 'Ваш заказ был создан. Вам необходимо оплатить счета, после чего с вами свяжется администратор для уточнения дополнительной информации', 'success'];
36 36
         }
37 37
     }
38 38
         ];
Please login to merge, or discard this patch.
system/modules/Libs/Libs.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
     public function loadLib($libName, $options = [])
14 14
     {
15 15
 
16
-        $className = 'Libs\\' . ucfirst($libName);
16
+        $className = 'Libs\\'.ucfirst($libName);
17 17
         if (class_exists($className)) {
18 18
             if (!empty($className::$composerPacks)) {
19 19
                 foreach ($className::$composerPacks as $packageName => $version) {
@@ -25,12 +25,12 @@  discard block
 block discarded – undo
25 25
                     $this->loadLib($rLib);
26 26
                 }
27 27
             }
28
-            if (!empty($className::$files['css']) && (!isset($options['loadCss']) || $options['loadCss'] )) {
28
+            if (!empty($className::$files['css']) && (!isset($options['loadCss']) || $options['loadCss'])) {
29 29
                 foreach ($className::$files['css'] as $file) {
30 30
                     if (strpos($file, '/') === 0 || strpos($file, 'http') === 0) {
31 31
                         App::$cur->view->customAsset('css', $file, $libName);
32 32
                     } else {
33
-                        App::$cur->view->customAsset('css', '/static/libs/vendor/' . ucfirst($libName) . '/' . $file, $libName);
33
+                        App::$cur->view->customAsset('css', '/static/libs/vendor/'.ucfirst($libName).'/'.$file, $libName);
34 34
                     }
35 35
                 }
36 36
             }
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
                     if (strpos($file, '/') === 0 || strpos($file, 'http') === 0) {
40 40
                         App::$cur->view->customAsset('js', $file, $libName);
41 41
                     } else {
42
-                        App::$cur->view->customAsset('js', '/static/libs/vendor/' . ucfirst($libName) . '/' . $file, $libName);
42
+                        App::$cur->view->customAsset('js', '/static/libs/vendor/'.ucfirst($libName).'/'.$file, $libName);
43 43
                     }
44 44
                 }
45 45
             }
@@ -50,30 +50,30 @@  discard block
 block discarded – undo
50 50
     {
51 51
         $libPath = preg_replace('!^libs/!', '', $file);
52 52
         $libName = substr($libPath, 0, strpos($libPath, '/'));
53
-        $className = 'Libs\\' . ucfirst($libName);
53
+        $className = 'Libs\\'.ucfirst($libName);
54 54
         if (class_exists($className)) {
55 55
             if (!empty($className::$programDirs)) {
56 56
                 $fileDir = substr($libPath, strlen($libName) + 1, strpos($libPath, '/', strlen($libName) + 1) - strlen($libName) - 1);
57 57
                 foreach ($className::$programDirs as $programDir) {
58 58
                     if ($programDir == $fileDir) {
59
-                        include $dir . $file;
59
+                        include $dir.$file;
60 60
                         exit();
61 61
                     }
62 62
                 }
63 63
             }
64 64
         }
65
-        return $dir . $file;
65
+        return $dir.$file;
66 66
     }
67 67
 
68 68
     public function getPath($args)
69 69
     {
70 70
         if (!empty($args[0])) {
71
-            $libName = 'Libs\\' . ucfirst($args[0]);
71
+            $libName = 'Libs\\'.ucfirst($args[0]);
72 72
             if (class_exists($libName)) {
73 73
                 $file = implode('/', array_slice($args, 1));
74 74
                 foreach ($libName::$staticDirs as $dir) {
75 75
                     if (strpos($file, $dir) === 0) {
76
-                        return \App::$primary->path . '/vendor/' . $file;
76
+                        return \App::$primary->path.'/vendor/'.$file;
77 77
                     }
78 78
                 }
79 79
             }
Please login to merge, or discard this patch.
system/modules/View/appAdminControllers/ViewController.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -48,9 +48,9 @@  discard block
 block discarded – undo
48 48
             $templates = App::$primary->view->config;
49 49
             $templates['app']['installed'][$_POST['name']] = $_POST['name'];
50 50
             Config::save('module', $templates, 'View', App::$primary);
51
-            $path = App::$primary->path . '/templates/' . $_POST['name'] . '/index.html';
52
-            $pathMap = App::$primary->path . '/templates/' . $_POST['name'] . '/map.html';
53
-            Tools::createDir(App::$primary->path . '/templates/' . $_POST['name']);
51
+            $path = App::$primary->path.'/templates/'.$_POST['name'].'/index.html';
52
+            $pathMap = App::$primary->path.'/templates/'.$_POST['name'].'/map.html';
53
+            Tools::createDir(App::$primary->path.'/templates/'.$_POST['name']);
54 54
             file_put_contents($path, $text);
55 55
             file_put_contents($pathMap, trim($_POST['map']));
56 56
             $template = [
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
                 'name' => $_POST['name'],
59 59
                 'file' => 'index.html',
60 60
             ];
61
-            Config::save(App::$primary->path . '/templates/' . $_POST['name'] . '/config.php', $template);
61
+            Config::save(App::$primary->path.'/templates/'.$_POST['name'].'/config.php', $template);
62 62
             Tools::redirect('/admin/View');
63 63
         }
64 64
         $this->view->page();
@@ -69,8 +69,8 @@  discard block
 block discarded – undo
69 69
         $this->view->setTitle('Редактирование шаблона');
70 70
         App::$cur->view->customAsset('css', '/static/moduleAsset/View/css/blockDrop.css');
71 71
         App::$cur->view->customAsset('js', '/static/moduleAsset/View/js/blockDrop.js');
72
-        $template = Config::custom(App::$primary->path . '/templates/' . $templateName . '/config.php');
73
-        $pathMap = App::$primary->path . '/templates/' . $templateName . '/map.html';
72
+        $template = Config::custom(App::$primary->path.'/templates/'.$templateName.'/config.php');
73
+        $pathMap = App::$primary->path.'/templates/'.$templateName.'/map.html';
74 74
         if (!empty($_POST)) {
75 75
             $templates = App::$primary->view->config;
76 76
             $templates['app']['installed'][$templateName] = $_POST['name'];
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
 
81 81
             $template['template_name'] = $templateName;
82 82
             $template['name'] = $templateName;
83
-            Config::save(App::$primary->path . '/templates/' . $_POST['name'] . '/config.php', $template);
83
+            Config::save(App::$primary->path.'/templates/'.$_POST['name'].'/config.php', $template);
84 84
             Tools::redirect('/admin/View');
85 85
         }
86 86
         $template['map'] = file_get_contents($pathMap);
Please login to merge, or discard this patch.