Completed
Push — master ( d192c7...9930d3 )
by Alexey
05:16
created
system/modules/Ui/objects/DataManager/Action/Href.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
         if (!empty($actionParams['query'])) {
29 29
             $query = $query + $actionParams['query'];
30 30
         }
31
-        return "<a class='" . (isset($actionParams['class']) ? $actionParams['class'] : '') . "' href='{$actionParams['href']}?" . http_build_query($query) . "'>{$actionParams['text']}</a>";
31
+        return "<a class='".(isset($actionParams['class']) ? $actionParams['class'] : '')."' href='{$actionParams['href']}?".http_build_query($query)."'>{$actionParams['text']}</a>";
32 32
     }
33 33
 
34 34
 }
Please login to merge, or discard this patch.
system/modules/Ui/objects/DataManager/Action/Edit.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
             'formName' => !empty($dataManager->managerOptions['editForm']) ? $dataManager->managerOptions['editForm'] : 'manager'
25 25
         ];
26 26
 
27
-        return '<a href ="#" onclick=\'inji.Ui.forms.popUp("' . addcslashes(get_class($item), '\\') . ':' . $item->pk() . '",' . json_encode($formParams) . ');
27
+        return '<a href ="#" onclick=\'inji.Ui.forms.popUp("'.addcslashes(get_class($item), '\\').':'.$item->pk().'",'.json_encode($formParams).');
28 28
                                       return false;\'><i class="glyphicon glyphicon-edit"></i></a>';
29 29
     }
30 30
 
Please login to merge, or discard this patch.
system/modules/Ui/objects/DataManager/Action/Delete.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
 
20 20
     public static function rowButton($dataManager, $item, $params, $actionParams)
21 21
     {
22
-        return '<a href ="#" onclick=\'inji.Ui.dataManagers.get(this).delRow(' . $item->pk() . ');
22
+        return '<a href ="#" onclick=\'inji.Ui.dataManagers.get(this).delRow('.$item->pk().');
23 23
                                       return false;\'><i class="glyphicon glyphicon-remove"></i></a>';
24 24
     }
25 25
 
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
             $model->delete();
32 32
         }
33 33
         $count = count($models);
34
-        return 'Удалено <b>' . $count . '</b> ' . \Tools::getNumEnding($count, ['запись', 'записи', 'записей']);
34
+        return 'Удалено <b>'.$count.'</b> '.\Tools::getNumEnding($count, ['запись', 'записи', 'записей']);
35 35
     }
36 36
 
37 37
 }
Please login to merge, or discard this patch.
system/modules/Ui/objects/Tree.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
           }
32 32
           $count += count($items);
33 33
           foreach ($items as $objectChild) {
34
-              $count+=static::showLi($objectChild, 1, $maxDeep, $hrefFunc);
34
+              $count += static::showLi($objectChild, 1, $maxDeep, $hrefFunc);
35 35
           }
36 36
           ?>
37 37
         </ul>
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
             $item = $item['text'];
53 53
         }
54 54
         if (!isset($attributes['id'])) {
55
-            $attributes['id'] = str_replace('\\', '_', get_class($object)) . "-{$object->pk()}";
55
+            $attributes['id'] = str_replace('\\', '_', get_class($object))."-{$object->pk()}";
56 56
         }
57 57
         if (!$maxDeep || $deep < $maxDeep) {
58 58
             $items = $class::getList(['where' => ['parent_id', $object->pk()]]);
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
                     echo \Html::el('li', $attributes, $item, true);
64 64
                     echo '<ul>';
65 65
                 }
66
-                $count+=static::showLi($objectChild, $deep + 1, $maxDeep, $hrefFunc);
66
+                $count += static::showLi($objectChild, $deep + 1, $maxDeep, $hrefFunc);
67 67
             }
68 68
         }
69 69
         if ($isset) {
Please login to merge, or discard this patch.
system/modules/UserForms/widgets/userForm.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
     echo "<p class = 'text-center'>{$userForm->description}</p>";
20 20
 }
21 21
 foreach ($userForm->inputs(['order' => ['weight']]) as $input) {
22
-    $form->input($input->type, 'UserForms[' . (int) $form_id . '][input' . $input->id . ']', $input->label, ['required' => $input->required]);
22
+    $form->input($input->type, 'UserForms['.(int) $form_id.'][input'.$input->id.']', $input->label, ['required' => $input->required]);
23 23
 }
24 24
 ?>
25 25
 <button class = 'btn btn-success btn-block'>Отправить</button>
Please login to merge, or discard this patch.
system/modules/UserForms/widgets/formData.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@
 block discarded – undo
2 2
 
3 3
 $inputs = json_decode($params[0]->fr_data, true);
4 4
 foreach ($params[0]->form->inputs as $input) {
5
-    if (isset($inputs['input' . $input->fi_id])) {
6
-        echo "{$input->fi_label}: " . htmlspecialchars($inputs['input' . $input->fi_id]) . "<br />";
5
+    if (isset($inputs['input'.$input->fi_id])) {
6
+        echo "{$input->fi_label}: ".htmlspecialchars($inputs['input'.$input->fi_id])."<br />";
7 7
     }
8 8
 }
Please login to merge, or discard this patch.
system/modules/UserForms/UserForms.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -24,13 +24,13 @@  discard block
 block discarded – undo
24 24
                 $data = [];
25 25
                 $error = false;
26 26
                 foreach ($form->inputs as $input) {
27
-                    if (isset($inputs['input' . $input->id])) {
28
-                        $data['input' . $input->id] = htmlspecialchars($inputs['input' . $input->id]);
27
+                    if (isset($inputs['input'.$input->id])) {
28
+                        $data['input'.$input->id] = htmlspecialchars($inputs['input'.$input->id]);
29 29
                     } elseif ($input->required) {
30 30
                         $error = true;
31
-                        Msg::add('Вы не заполнили поле: ' . $input->label);
31
+                        Msg::add('Вы не заполнили поле: '.$input->label);
32 32
                     } else {
33
-                        $data['input' . $input->id] = '';
33
+                        $data['input'.$input->id] = '';
34 34
                     }
35 35
                 }
36 36
                 if (!$error) {
@@ -42,13 +42,13 @@  discard block
 block discarded – undo
42 42
             if (!$error && !empty(App::$cur->config['site']['email'])) {
43 43
                 $text = '';
44 44
                 foreach ($form->inputs as $input) {
45
-                    if (isset($inputs['input' . $input->id])) {
46
-                        $text .="<b>{$input->label}:</b> " . htmlspecialchars($inputs['input' . $input->id]) . "<br />";
45
+                    if (isset($inputs['input'.$input->id])) {
46
+                        $text .= "<b>{$input->label}:</b> ".htmlspecialchars($inputs['input'.$input->id])."<br />";
47 47
                     }
48 48
                 }
49 49
                 if ($text) {
50
-                    $text = 'Дата получения по серверному времени: ' . date('Y-m-d H:i:s') . '<br />Заполненые поля:<br />' . $text;
51
-                    Tools::sendMail('noreply@' . INJI_DOMAIN_NAME, App::$cur->config['site']['email'], $form->name, $text);
50
+                    $text = 'Дата получения по серверному времени: '.date('Y-m-d H:i:s').'<br />Заполненые поля:<br />'.$text;
51
+                    Tools::sendMail('noreply@'.INJI_DOMAIN_NAME, App::$cur->config['site']['email'], $form->name, $text);
52 52
                 }
53 53
             }
54 54
             Tools::redirect($_SERVER['REQUEST_URI'], 'Ваша форма была успешно отправлена', 'success');
@@ -60,8 +60,8 @@  discard block
 block discarded – undo
60 60
         $inputs = json_decode($item->data, true);
61 61
         $text = '';
62 62
         foreach ($item->form->inputs as $input) {
63
-            if (isset($inputs['input' . $input->id])) {
64
-                $text .= "{$input->label}: " . htmlspecialchars($inputs['input' . $input->id]) . "<br />";
63
+            if (isset($inputs['input'.$input->id])) {
64
+                $text .= "{$input->label}: ".htmlspecialchars($inputs['input'.$input->id])."<br />";
65 65
             }
66 66
         }
67 67
         return $text;
Please login to merge, or discard this patch.
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/Item.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -112,17 +112,17 @@  discard block
 block discarded – undo
112 112
     {
113 113
 
114 114
         if ($this->id) {
115
-            $this->search_index = $this->name . ' ';
115
+            $this->search_index = $this->name.' ';
116 116
             if ($this->category) {
117
-                $this->search_index .= $this->category->name . ' ';
117
+                $this->search_index .= $this->category->name.' ';
118 118
             }
119 119
             if ($this->options) {
120 120
                 foreach ($this->options as $option) {
121 121
                     if ($option->item_option_searchable && $option->value) {
122 122
                         if ($option->item_option_type != 'select') {
123
-                            $this->search_index .= $option->value . ' ';
123
+                            $this->search_index .= $option->value.' ';
124 124
                         } elseif (!empty($option->option->items[$option->value])) {
125
-                            $option->option->items[$option->value]->value . ' ';
125
+                            $option->option->items[$option->value]->value.' ';
126 126
                         }
127 127
                     }
128 128
                 }
@@ -144,7 +144,7 @@  discard block
 block discarded – undo
144 144
                 'col' => 'item_id',
145 145
                 //'resultKey' => 'code',
146 146
                 'resultKey' => 'item_option_id',
147
-                'join' => [Item\Option::table(), Item\Option::index() . ' = ' . Item\Param::colPrefix() . Item\Option::index()]
147
+                'join' => [Item\Option::table(), Item\Option::index().' = '.Item\Param::colPrefix().Item\Option::index()]
148 148
             ],
149 149
             'offers' => [
150 150
                 'type' => 'many',
@@ -181,7 +181,7 @@  discard block
 block discarded – undo
181 181
                 $curPrice = $price;
182 182
             } elseif (
183 183
                     (!$price->type->roles && !$curPrice) ||
184
-                    ($price->type->roles && !$curPrice && strpos($price->type->roles, "|" . \Users\User::$cur->role_id . "|") !== false)
184
+                    ($price->type->roles && !$curPrice && strpos($price->type->roles, "|".\Users\User::$cur->role_id."|") !== false)
185 185
             ) {
186 186
                 $curPrice = $price;
187 187
             }
Please login to merge, or discard this patch.