@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | { |
28 | 28 | header("Content-Type: text/xml"); |
29 | 29 | header("Expires: Thu, 19 Feb 1998 13:24:18 GMT"); |
30 | - header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); |
|
30 | + header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); |
|
31 | 31 | header("Cache-Control: no-cache, must-revalidate"); |
32 | 32 | header("Cache-Control: post-check=0,pre-check=0"); |
33 | 33 | header("Cache-Control: max-age=0"); |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | $root->setAttribute("xmlns", "http://www.sitemaps.org/schemas/sitemap/0.9"); |
40 | 40 | $root = $xml->appendChild($root); |
41 | 41 | |
42 | - $addToXml = function ($xml, $parent, $nodeName, $text) { |
|
42 | + $addToXml = function($xml, $parent, $nodeName, $text) { |
|
43 | 43 | $node = $parent->appendChild($xml->createElement($nodeName)); |
44 | 44 | $node->appendChild($xml->createTextNode($text)); |
45 | 45 | return $node; |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -return function ($step = NULL, $params = []) { |
|
3 | +return function($step = NULL, $params = []) { |
|
4 | 4 | |
5 | 5 | $groups = [ |
6 | 6 | [ |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | |
42 | 42 | if (!empty($conf['files']['aditionTemplateFiels'])) { |
43 | 43 | foreach ($conf['files']['aditionTemplateFiels'] as $file) { |
44 | - $return[$file['file']] = '- ' . $file['name']; |
|
44 | + $return[$file['file']] = '- '.$file['name']; |
|
45 | 45 | } |
46 | 46 | } |
47 | 47 | return $return; |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | |
78 | 78 | if (!empty($conf['files']['aditionTemplateFiels'])) { |
79 | 79 | foreach ($conf['files']['aditionTemplateFiels'] as $file) { |
80 | - $return[$file['file']] = '- ' . $file['name']; |
|
80 | + $return[$file['file']] = '- '.$file['name']; |
|
81 | 81 | } |
82 | 82 | } |
83 | 83 | return $return; |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | $map[] = [ |
92 | 92 | 'name' => $mat->name, |
93 | 93 | 'url' => [ |
94 | - 'loc' => (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://' . INJI_DOMAIN_NAME . ($mat->getHref()) |
|
94 | + 'loc' => (!empty($_SERVER['HTTPS']) ? 'https' : 'http').'://'.INJI_DOMAIN_NAME.($mat->getHref()) |
|
95 | 95 | ], |
96 | 96 | ]; |
97 | 97 | } |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | $map[] = [ |
105 | 105 | 'name' => $mat->name, |
106 | 106 | 'url' => [ |
107 | - 'loc' => (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://' . INJI_DOMAIN_NAME . ($mat->getHref()) |
|
107 | + 'loc' => (!empty($_SERVER['HTTPS']) ? 'https' : 'http').'://'.INJI_DOMAIN_NAME.($mat->getHref()) |
|
108 | 108 | ], |
109 | 109 | ]; |
110 | 110 | } |
@@ -18,7 +18,7 @@ discard block |
||
18 | 18 | <td class="text-left" style="width: 50%;"> |
19 | 19 | <?php |
20 | 20 | foreach ($orderDeatilCols as $col => $label) { |
21 | - echo "<b>{$label}</b> " . $cart->$col . "<br>"; |
|
21 | + echo "<b>{$label}</b> ".$cart->$col."<br>"; |
|
22 | 22 | } |
23 | 23 | ?> |
24 | 24 | </td> |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | <?php |
42 | 42 | if ($cart->infos) { |
43 | 43 | foreach ($cart->infos as $info) { |
44 | - echo "<b>{$info->field->name()}</b> " . $info->value . "<br>"; |
|
44 | + echo "<b>{$info->field->name()}</b> ".$info->value."<br>"; |
|
45 | 45 | } |
46 | 46 | } |
47 | 47 | ?> |
@@ -125,7 +125,7 @@ discard block |
||
125 | 125 | if (App::$cur->money) { |
126 | 126 | $currency = Money\Currency::get($currency_id); |
127 | 127 | if ($currency) { |
128 | - echo ' ' . $currency->acronym(); |
|
128 | + echo ' '.$currency->acronym(); |
|
129 | 129 | } else { |
130 | 130 | echo ' руб.'; |
131 | 131 | } |
@@ -168,7 +168,7 @@ discard block |
||
168 | 168 | if (App::$cur->money) { |
169 | 169 | $currency = Money\Currency::get($currency_id); |
170 | 170 | if ($currency) { |
171 | - echo ' ' . $currency->acronym(); |
|
171 | + echo ' '.$currency->acronym(); |
|
172 | 172 | } else { |
173 | 173 | echo ' руб.'; |
174 | 174 | } |
@@ -207,7 +207,7 @@ discard block |
||
207 | 207 | case'2': |
208 | 208 | $price = Ecommerce\Item\Offer\Price::get($status->info); |
209 | 209 | if ($price) { |
210 | - echo "<a href = '/ecommerce/view/{$item->id}'>" . $price->offer->item->name() . "</a>"; |
|
210 | + echo "<a href = '/ecommerce/view/{$item->id}'>".$price->offer->item->name()."</a>"; |
|
211 | 211 | } else { |
212 | 212 | echo 'Товар удален'; |
213 | 213 | } |
@@ -216,7 +216,7 @@ discard block |
||
216 | 216 | $info = explode('|', $status->info); |
217 | 217 | $price = Ecommerce\Item\Offer\Price::get($info[0]); |
218 | 218 | if ($price) { |
219 | - echo "<a href = '/ecommerce/view/{$item->id}'>" . $price->offer->item->name() . "</a> " . ($info[1] > 0 ? '+' . $info[1] : $info[1]); |
|
219 | + echo "<a href = '/ecommerce/view/{$item->id}'>".$price->offer->item->name()."</a> ".($info[1] > 0 ? '+'.$info[1] : $info[1]); |
|
220 | 220 | } else { |
221 | 221 | echo 'Товар удален'; |
222 | 222 | } |
@@ -74,7 +74,7 @@ discard block |
||
74 | 74 | $dir = pathinfo($this->object->walker->migtarionLog->source, PATHINFO_DIRNAME); |
75 | 75 | if ($this->model->{$this->param->value}) { |
76 | 76 | $file = \Files\File::get($this->model->{$this->param->value}); |
77 | - if ($file && $value && file_exists($dir . '/' . $value) && file_exists(\App::$primary->path . $file->path) && md5_file($dir . '/' . $value) == md5_file(\App::$primary->path . $file->path)) { |
|
77 | + if ($file && $value && file_exists($dir.'/'.$value) && file_exists(\App::$primary->path.$file->path) && md5_file($dir.'/'.$value) == md5_file(\App::$primary->path.$file->path)) { |
|
78 | 78 | $notEq = false; |
79 | 79 | } |
80 | 80 | if ($file && $notEq) { |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | } |
84 | 84 | } |
85 | 85 | if ($notEq) { |
86 | - $this->model->{$this->param->value} = \App::$primary->files->uploadFromUrl($dir . '/' . $value, ['accept_group' => 'image', 'upload_code' => 'MigrationUpload']); |
|
86 | + $this->model->{$this->param->value} = \App::$primary->files->uploadFromUrl($dir.'/'.$value, ['accept_group' => 'image', 'upload_code' => 'MigrationUpload']); |
|
87 | 87 | } |
88 | 88 | break; |
89 | 89 | default: |
@@ -48,7 +48,7 @@ discard block |
||
48 | 48 | $name = ''; |
49 | 49 | foreach ($fields as $field) { |
50 | 50 | if ($field->save && !empty($data[$field->id])) { |
51 | - $name .= htmlspecialchars($data[$field->id]) . ' '; |
|
51 | + $name .= htmlspecialchars($data[$field->id]).' '; |
|
52 | 52 | } |
53 | 53 | } |
54 | 54 | $name = trim($name); |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | $name = ''; |
105 | 105 | foreach ($fields as $field) { |
106 | 106 | if ($field->save && !empty($data[$field->id])) { |
107 | - $name .= htmlspecialchars($data[$field->id]) . ' '; |
|
107 | + $name .= htmlspecialchars($data[$field->id]).' '; |
|
108 | 108 | } |
109 | 109 | } |
110 | 110 | $name = trim($name); |
@@ -189,7 +189,7 @@ discard block |
||
189 | 189 | foreach ($options['sort'] as $col => $direction) { |
190 | 190 | switch ($col) { |
191 | 191 | case 'price': |
192 | - $selectOptions['order'][] = [Ecommerce\Item\Offer\Price::colPrefix() . 'price', strtolower($direction) == 'desc' ? 'desc' : 'asc']; |
|
192 | + $selectOptions['order'][] = [Ecommerce\Item\Offer\Price::colPrefix().'price', strtolower($direction) == 'desc' ? 'desc' : 'asc']; |
|
193 | 193 | break; |
194 | 194 | case 'name': |
195 | 195 | $selectOptions['order'][] = ['name', strtolower($direction) == 'desc' ? 'desc' : 'asc']; |
@@ -208,22 +208,22 @@ discard block |
||
208 | 208 | $selectOptions['where'][] = ['image_file_id', 0, '!=']; |
209 | 209 | } |
210 | 210 | |
211 | - $selectOptions['join'][] = [Ecommerce\Item\Offer::table(), Ecommerce\Item::index() . ' = ' . Ecommerce\Item\Offer::colPrefix() . Ecommerce\Item::index(), 'inner']; |
|
211 | + $selectOptions['join'][] = [Ecommerce\Item\Offer::table(), Ecommerce\Item::index().' = '.Ecommerce\Item\Offer::colPrefix().Ecommerce\Item::index(), 'inner']; |
|
212 | 212 | |
213 | 213 | $selectOptions['join'][] = [Ecommerce\Item\Offer\Price::table(), |
214 | - Ecommerce\Item\Offer::index() . ' = ' . Ecommerce\Item\Offer\Price::colPrefix() . Ecommerce\Item\Offer::index() . |
|
215 | - (empty($this->config['show_zero_price']) ? ' and ' . Ecommerce\Item\Offer\Price::colPrefix() . 'price>0' : ''), |
|
214 | + Ecommerce\Item\Offer::index().' = '.Ecommerce\Item\Offer\Price::colPrefix().Ecommerce\Item\Offer::index(). |
|
215 | + (empty($this->config['show_zero_price']) ? ' and '.Ecommerce\Item\Offer\Price::colPrefix().'price>0' : ''), |
|
216 | 216 | empty($this->config['show_without_price']) ? 'inner' : 'left']; |
217 | 217 | |
218 | 218 | $selectOptions['join'][] = [ |
219 | - Ecommerce\Item\Offer\Price\Type::table(), Ecommerce\Item\Offer\Price::colPrefix() . Ecommerce\Item\Offer\Price\Type::index() . ' = ' . Ecommerce\Item\Offer\Price\Type::index() |
|
219 | + Ecommerce\Item\Offer\Price\Type::table(), Ecommerce\Item\Offer\Price::colPrefix().Ecommerce\Item\Offer\Price\Type::index().' = '.Ecommerce\Item\Offer\Price\Type::index() |
|
220 | 220 | ]; |
221 | 221 | |
222 | 222 | $selectOptions['where'][] = [ |
223 | 223 | [Ecommerce\Item\Offer\Price\Type::index(), NULL, 'is'], |
224 | 224 | [ |
225 | - [Ecommerce\Item\Offer\Price\Type::colPrefix() . 'roles', '', '=', 'OR'], |
|
226 | - [Ecommerce\Item\Offer\Price\Type::colPrefix() . 'roles', '%|' . \Users\User::$cur->role_id . '|%', 'LIKE', 'OR'], |
|
225 | + [Ecommerce\Item\Offer\Price\Type::colPrefix().'roles', '', '=', 'OR'], |
|
226 | + [Ecommerce\Item\Offer\Price\Type::colPrefix().'roles', '%|'.\Users\User::$cur->role_id.'|%', 'LIKE', 'OR'], |
|
227 | 227 | ], |
228 | 228 | ]; |
229 | 229 | |
@@ -231,10 +231,10 @@ discard block |
||
231 | 231 | if (!empty($this->config['view_filter'])) { |
232 | 232 | if (!empty($this->config['view_filter']['options'])) { |
233 | 233 | foreach ($this->config['view_filter']['options'] as $optionId => $optionValue) { |
234 | - $selectOptions['join'][] = [Ecommerce\Item\Param::table(), Ecommerce\Item::index() . ' = ' . 'option' . $optionId . '.' . Ecommerce\Item\Param::colPrefix() . Ecommerce\Item::index() . ' AND ' . |
|
235 | - 'option' . $optionId . '.' . Ecommerce\Item\Param::colPrefix() . Ecommerce\Item\Option::index() . ' = "' . (int) $optionId . '" AND ' . |
|
236 | - 'option' . $optionId . '.' . Ecommerce\Item\Param::colPrefix() . 'value = "' . (int) $optionValue . '"', |
|
237 | - 'inner', 'option' . $optionId]; |
|
234 | + $selectOptions['join'][] = [Ecommerce\Item\Param::table(), Ecommerce\Item::index().' = '.'option'.$optionId.'.'.Ecommerce\Item\Param::colPrefix().Ecommerce\Item::index().' AND '. |
|
235 | + 'option'.$optionId.'.'.Ecommerce\Item\Param::colPrefix().Ecommerce\Item\Option::index().' = "'.(int) $optionId.'" AND '. |
|
236 | + 'option'.$optionId.'.'.Ecommerce\Item\Param::colPrefix().'value = "'.(int) $optionValue.'"', |
|
237 | + 'inner', 'option'.$optionId]; |
|
238 | 238 | } |
239 | 239 | } |
240 | 240 | } |
@@ -244,10 +244,10 @@ discard block |
||
244 | 244 | switch ($col) { |
245 | 245 | case 'price': |
246 | 246 | if (!empty($filter['min'])) { |
247 | - $selectOptions['where'][] = [Ecommerce\Item\Offer\Price::colPrefix() . 'price', (float) $filter['min'], '>=']; |
|
247 | + $selectOptions['where'][] = [Ecommerce\Item\Offer\Price::colPrefix().'price', (float) $filter['min'], '>=']; |
|
248 | 248 | } |
249 | 249 | if (!empty($filter['max'])) { |
250 | - $selectOptions['where'][] = [Ecommerce\Item\Offer\Price::colPrefix() . 'price', (float) $filter['max'], '<=']; |
|
250 | + $selectOptions['where'][] = [Ecommerce\Item\Offer\Price::colPrefix().'price', (float) $filter['max'], '<=']; |
|
251 | 251 | } |
252 | 252 | break; |
253 | 253 | case 'options': |
@@ -258,14 +258,14 @@ discard block |
||
258 | 258 | foreach ($optionValue as $val) { |
259 | 259 | $optionValueArr[] = \App::$cur->db->connection->pdo->quote($val); |
260 | 260 | } |
261 | - $qstr = 'IN (' . implode(',', $optionValueArr) . ')'; |
|
261 | + $qstr = 'IN ('.implode(',', $optionValueArr).')'; |
|
262 | 262 | } else { |
263 | - $qstr = '= ' . \App::$cur->db->connection->pdo->quote($optionValue); |
|
263 | + $qstr = '= '.\App::$cur->db->connection->pdo->quote($optionValue); |
|
264 | 264 | } |
265 | - $selectOptions['join'][] = [Ecommerce\Item\Param::table(), Ecommerce\Item::index() . ' = ' . 'option' . $optionId . '.' . Ecommerce\Item\Param::colPrefix() . Ecommerce\Item::index() . ' AND ' . |
|
266 | - 'option' . $optionId . '.' . Ecommerce\Item\Param::colPrefix() . Ecommerce\Item\Option::index() . ' = "' . (int) $optionId . '" AND ' . |
|
267 | - 'option' . $optionId . '.' . Ecommerce\Item\Param::colPrefix() . 'value ' . $qstr . '', |
|
268 | - 'inner', 'option' . $optionId]; |
|
265 | + $selectOptions['join'][] = [Ecommerce\Item\Param::table(), Ecommerce\Item::index().' = '.'option'.$optionId.'.'.Ecommerce\Item\Param::colPrefix().Ecommerce\Item::index().' AND '. |
|
266 | + 'option'.$optionId.'.'.Ecommerce\Item\Param::colPrefix().Ecommerce\Item\Option::index().' = "'.(int) $optionId.'" AND '. |
|
267 | + 'option'.$optionId.'.'.Ecommerce\Item\Param::colPrefix().'value '.$qstr.'', |
|
268 | + 'inner', 'option'.$optionId]; |
|
269 | 269 | } |
270 | 270 | break; |
271 | 271 | case 'offerOptions': |
@@ -277,14 +277,14 @@ discard block |
||
277 | 277 | foreach ($optionValue as $val) { |
278 | 278 | $optionValueArr[] = \App::$cur->db->connection->pdo->quote($val); |
279 | 279 | } |
280 | - $qstr = 'IN (' . implode(',', $optionValueArr) . ')'; |
|
280 | + $qstr = 'IN ('.implode(',', $optionValueArr).')'; |
|
281 | 281 | } else { |
282 | - $qstr = '= ' . \App::$cur->db->connection->pdo->quote($optionValue); |
|
282 | + $qstr = '= '.\App::$cur->db->connection->pdo->quote($optionValue); |
|
283 | 283 | } |
284 | - $selectOptions['join'][] = [Ecommerce\Item\Offer\Param::table(), Ecommerce\Item\Offer::index() . ' = ' . 'offerOption' . $optionId . '.' . Ecommerce\Item\Offer\Param::colPrefix() . Ecommerce\Item\Offer::index() . ' AND ' . |
|
285 | - 'offerOption' . $optionId . '.' . Ecommerce\Item\Offer\Param::colPrefix() . Ecommerce\Item\Offer\Option::index() . ' = "' . (int) $optionId . '" AND ' . |
|
286 | - 'offerOption' . $optionId . '.' . Ecommerce\Item\Offer\Param::colPrefix() . 'value ' . $qstr, |
|
287 | - 'inner', 'offerOption' . $optionId]; |
|
284 | + $selectOptions['join'][] = [Ecommerce\Item\Offer\Param::table(), Ecommerce\Item\Offer::index().' = '.'offerOption'.$optionId.'.'.Ecommerce\Item\Offer\Param::colPrefix().Ecommerce\Item\Offer::index().' AND '. |
|
285 | + 'offerOption'.$optionId.'.'.Ecommerce\Item\Offer\Param::colPrefix().Ecommerce\Item\Offer\Option::index().' = "'.(int) $optionId.'" AND '. |
|
286 | + 'offerOption'.$optionId.'.'.Ecommerce\Item\Offer\Param::colPrefix().'value '.$qstr, |
|
287 | + 'inner', 'offerOption'.$optionId]; |
|
288 | 288 | } |
289 | 289 | break; |
290 | 290 | } |
@@ -299,13 +299,13 @@ discard block |
||
299 | 299 | continue; |
300 | 300 | } |
301 | 301 | $category = \Ecommerce\Category::get($categoryId); |
302 | - $where[] = ['tree_path', $category->tree_path . (int) $categoryId . '/%', 'LIKE', $first ? 'AND' : 'OR']; |
|
302 | + $where[] = ['tree_path', $category->tree_path.(int) $categoryId.'/%', 'LIKE', $first ? 'AND' : 'OR']; |
|
303 | 303 | $first = false; |
304 | 304 | } |
305 | 305 | $selectOptions['where'][] = $where; |
306 | 306 | } elseif (!empty($options['parent'])) { |
307 | 307 | $category = \Ecommerce\Category::get($options['parent']); |
308 | - $selectOptions['where'][] = ['tree_path', $category->tree_path . (int) $options['parent'] . '/%', 'LIKE']; |
|
308 | + $selectOptions['where'][] = ['tree_path', $category->tree_path.(int) $options['parent'].'/%', 'LIKE']; |
|
309 | 309 | } |
310 | 310 | |
311 | 311 | //search |
@@ -315,7 +315,7 @@ discard block |
||
315 | 315 | foreach (explode(' ', $searchStr) as $part) { |
316 | 316 | $part = trim($part); |
317 | 317 | if ($part && strlen($part) > 2) { |
318 | - $searchArr[] = ['search_index', '%' . $part . '%', 'LIKE']; |
|
318 | + $searchArr[] = ['search_index', '%'.$part.'%', 'LIKE']; |
|
319 | 319 | } |
320 | 320 | } |
321 | 321 | if (!empty($searchArr)) { |
@@ -334,19 +334,19 @@ discard block |
||
334 | 334 | } |
335 | 335 | $selectOptions['where'][] = [ |
336 | 336 | '( |
337 | - (SELECT COALESCE(sum(`' . \Ecommerce\Item\Offer\Warehouse::colPrefix() . 'count`),0) |
|
338 | - FROM ' . \App::$cur->db->table_prefix . \Ecommerce\Item\Offer\Warehouse::table() . ' iciw |
|
339 | - WHERE iciw.' . \Ecommerce\Item\Offer\Warehouse::colPrefix() . \Ecommerce\Item\Offer::index() . ' = ' . \Ecommerce\Item\Offer::index() . ' |
|
340 | - ' . ($warehouseIds ? ' AND iciw.' . \Ecommerce\Item\Offer\Warehouse::colPrefix() . \Ecommerce\Warehouse::index() . ' IN(' . implode(',', $warehouseIds) . ')' : '') . ' |
|
337 | + (SELECT COALESCE(sum(`' . \Ecommerce\Item\Offer\Warehouse::colPrefix().'count`),0) |
|
338 | + FROM ' . \App::$cur->db->table_prefix.\Ecommerce\Item\Offer\Warehouse::table().' iciw |
|
339 | + WHERE iciw.' . \Ecommerce\Item\Offer\Warehouse::colPrefix().\Ecommerce\Item\Offer::index().' = '.\Ecommerce\Item\Offer::index().' |
|
340 | + ' . ($warehouseIds ? ' AND iciw.'.\Ecommerce\Item\Offer\Warehouse::colPrefix().\Ecommerce\Warehouse::index().' IN('.implode(',', $warehouseIds).')' : '').' |
|
341 | 341 | ) |
342 | 342 | - |
343 | - (SELECT COALESCE(sum(' . \Ecommerce\Warehouse\Block::colPrefix() . 'count) ,0) |
|
344 | - FROM ' . \App::$cur->db->table_prefix . \Ecommerce\Warehouse\Block::table() . ' iewb |
|
345 | - inner JOIN ' . \App::$cur->db->table_prefix . \Ecommerce\Cart::table() . ' icc ON icc.' . \Ecommerce\Cart::index() . ' = iewb.' . \Ecommerce\Warehouse\Block::colPrefix() . \Ecommerce\Cart::index() . ' AND ( |
|
346 | - (`' . \Ecommerce\Cart::colPrefix() . 'warehouse_block` = 1 and `' . \Ecommerce\Cart::colPrefix() . 'cart_status_id` in(2,3,6)) || |
|
347 | - (`' . \Ecommerce\Cart::colPrefix() . \Ecommerce\Cart\Status::index() . '` in(0,1) and `' . \Ecommerce\Cart::colPrefix() . 'date_last_activ` >=subdate(now(),INTERVAL 30 MINUTE)) |
|
343 | + (SELECT COALESCE(sum(' . \Ecommerce\Warehouse\Block::colPrefix().'count) ,0) |
|
344 | + FROM ' . \App::$cur->db->table_prefix.\Ecommerce\Warehouse\Block::table().' iewb |
|
345 | + inner JOIN ' . \App::$cur->db->table_prefix.\Ecommerce\Cart::table().' icc ON icc.'.\Ecommerce\Cart::index().' = iewb.'.\Ecommerce\Warehouse\Block::colPrefix().\Ecommerce\Cart::index().' AND ( |
|
346 | + (`' . \Ecommerce\Cart::colPrefix().'warehouse_block` = 1 and `'.\Ecommerce\Cart::colPrefix().'cart_status_id` in(2,3,6)) || |
|
347 | + (`' . \Ecommerce\Cart::colPrefix().\Ecommerce\Cart\Status::index().'` in(0,1) and `'.\Ecommerce\Cart::colPrefix().'date_last_activ` >=subdate(now(),INTERVAL 30 MINUTE)) |
|
348 | 348 | ) |
349 | - WHERE iewb.' . \Ecommerce\Warehouse\Block::colPrefix() . \Ecommerce\Item\Offer::index() . ' = ' . \Ecommerce\Item\Offer::index() . ') |
|
349 | + WHERE iewb.' . \Ecommerce\Warehouse\Block::colPrefix().\Ecommerce\Item\Offer::index().' = '.\Ecommerce\Item\Offer::index().') |
|
350 | 350 | )', |
351 | 351 | 0, |
352 | 352 | '>' |
@@ -374,7 +374,7 @@ discard block |
||
374 | 374 | $items = Ecommerce\Item::getList($selectOptions); |
375 | 375 | $items = Ecommerce\Item\Param::getList([ |
376 | 376 | 'where' => ['item_id', array_keys($items), 'IN'], |
377 | - 'join' => [[Ecommerce\Item\Option::table(), Ecommerce\Item\Option::index() . ' = ' . \Ecommerce\Item\Param::colPrefix() . Ecommerce\Item\Option::index() . ' and ' . \Ecommerce\Item\Option::colPrefix() . 'searchable = 1', 'inner']], |
|
377 | + 'join' => [[Ecommerce\Item\Option::table(), Ecommerce\Item\Option::index().' = '.\Ecommerce\Item\Param::colPrefix().Ecommerce\Item\Option::index().' and '.\Ecommerce\Item\Option::colPrefix().'searchable = 1', 'inner']], |
|
378 | 378 | 'distinct' => \Ecommerce\Item\Option::index() |
379 | 379 | ]); |
380 | 380 | return $items; |
@@ -405,7 +405,7 @@ discard block |
||
405 | 405 | if (is_array($counts)) { |
406 | 406 | $sum = 0; |
407 | 407 | foreach ($counts as $count) { |
408 | - $sum +=$count['count']; |
|
408 | + $sum += $count['count']; |
|
409 | 409 | } |
410 | 410 | return $sum; |
411 | 411 | } |
@@ -439,7 +439,7 @@ discard block |
||
439 | 439 | |
440 | 440 | if (!empty($conf['files']['aditionTemplateFiels'])) { |
441 | 441 | foreach ($conf['files']['aditionTemplateFiels'] as $file) { |
442 | - $return[$file['file']] = '- ' . $file['name']; |
|
442 | + $return[$file['file']] = '- '.$file['name']; |
|
443 | 443 | } |
444 | 444 | } |
445 | 445 | return $return; |
@@ -513,7 +513,7 @@ discard block |
||
513 | 513 | $map[] = [ |
514 | 514 | 'name' => $item->name, |
515 | 515 | 'url' => [ |
516 | - 'loc' => (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://' . INJI_DOMAIN_NAME . ($item->getHref()) |
|
516 | + 'loc' => (!empty($_SERVER['HTTPS']) ? 'https' : 'http').'://'.INJI_DOMAIN_NAME.($item->getHref()) |
|
517 | 517 | ], |
518 | 518 | ]; |
519 | 519 | } |
@@ -526,7 +526,7 @@ discard block |
||
526 | 526 | $map[] = [ |
527 | 527 | 'name' => $item->name, |
528 | 528 | 'url' => [ |
529 | - 'loc' => (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://' . INJI_DOMAIN_NAME . ($item->getHref()) |
|
529 | + 'loc' => (!empty($_SERVER['HTTPS']) ? 'https' : 'http').'://'.INJI_DOMAIN_NAME.($item->getHref()) |
|
530 | 530 | ], |
531 | 531 | ]; |
532 | 532 | } |
@@ -3,7 +3,7 @@ discard block |
||
3 | 3 | 'id' => $dataManager->managerId, |
4 | 4 | 'class' => 'dataManager', |
5 | 5 | 'data-params' => $params, |
6 | - 'data-modelname' => ($model ? get_class($model) : $dataManager->modelName) . ($model && $model->pk() ? ':' . $model->pk() : ''), |
|
6 | + 'data-modelname' => ($model ? get_class($model) : $dataManager->modelName).($model && $model->pk() ? ':'.$model->pk() : ''), |
|
7 | 7 | 'data-managername' => $dataManager->managerName, |
8 | 8 | 'data-cols' => $dataManager->cols, |
9 | 9 | 'data-options' => array_merge($dataManager->managerOptions, ['actions'=>$dataManager->getActions()]) |
@@ -22,7 +22,7 @@ discard block |
||
22 | 22 | 'style' => '' |
23 | 23 | ]; |
24 | 24 | if (!empty($dataManager->managerOptions['categorys'])) { |
25 | - $mainCol['style'].='margin-left:260px;'; |
|
25 | + $mainCol['style'] .= 'margin-left:260px;'; |
|
26 | 26 | echo '<div class ="pull-left dataManager-categorys" style = "width:250px;">'; |
27 | 27 | $this->widget('Ui\DataManager/categorys', compact('dataManager')); |
28 | 28 | echo '</div>'; |
@@ -40,7 +40,7 @@ |
||
40 | 40 | if (!empty($modelName)) { |
41 | 41 | $inputOptions['createBtn'] = [ |
42 | 42 | 'text' => 'Создать элемент', |
43 | - 'onclick' => 'inji.Ui.forms.popUp(\'' . addslashes($modelName) . '\',{},function(elem){' |
|
43 | + 'onclick' => 'inji.Ui.forms.popUp(\''.addslashes($modelName).'\',{},function(elem){' |
|
44 | 44 | . 'return function(data,modal){inji.Ui.forms.submitAjax($(elem).closest(\'form\')[0], {notSave: true});}}(this))' |
45 | 45 | ]; |
46 | 46 | } |
@@ -23,7 +23,7 @@ discard block |
||
23 | 23 | case 'radio': |
24 | 24 | echo "<label>{$option->name}</label>"; |
25 | 25 | foreach ($option->items as $item) { |
26 | - $this->widget('Ui\Form/' . $option->type, [ |
|
26 | + $this->widget('Ui\Form/'.$option->type, [ |
|
27 | 27 | 'label' => $item->name, |
28 | 28 | 'name' => "filters[options][{$option->id}]", |
29 | 29 | !empty($_GET['filters']['options'][$option->id]) && $_GET['filters']['options'][$option->id] == $item->id ? 'checked' : false, |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | } |
48 | 48 | break; |
49 | 49 | default: |
50 | - $this->widget('Ui\Form/' . ($option->type ? $option->type : 'text'), [ |
|
50 | + $this->widget('Ui\Form/'.($option->type ? $option->type : 'text'), [ |
|
51 | 51 | 'label' => $option->name, |
52 | 52 | 'name' => "filters[options][{$option->id}]", |
53 | 53 | 'options' => [ |