@@ -20,21 +20,21 @@ |
||
20 | 20 | $file = new \Exchange1c\Exchange\File(); |
21 | 21 | $file->name = $_GET['filename']; |
22 | 22 | $file->exchange_id = $this->exchange->id; |
23 | - $file->size = ceil(filesize($dir . '/' . $_GET['filename'])); |
|
23 | + $file->size = ceil(filesize($dir.'/'.$_GET['filename'])); |
|
24 | 24 | $file->save(); |
25 | 25 | |
26 | 26 | if (strpos($_GET['filename'], '/') !== false) { |
27 | 27 | $subDir = substr($_GET['filename'], 0, strrpos($_GET['filename'], "/") + 1); |
28 | - \Tools::createDir($dir . '/' . $subDir); |
|
28 | + \Tools::createDir($dir.'/'.$subDir); |
|
29 | 29 | } |
30 | 30 | $status = 'success'; |
31 | 31 | $text = ''; |
32 | - if (false === file_put_contents($dir . '/' . $_GET['filename'], file_get_contents("php://input"))) { |
|
32 | + if (false === file_put_contents($dir.'/'.$_GET['filename'], file_get_contents("php://input"))) { |
|
33 | 33 | $status = 'failure'; |
34 | - $text = 'Fail on save file: ' . $_GET['filename']; |
|
34 | + $text = 'Fail on save file: '.$_GET['filename']; |
|
35 | 35 | } |
36 | 36 | if (strpos($_GET['filename'], '1cbitrix') !== false) { |
37 | - $data = new \SimpleXMLElement(file_get_contents($dir . '/' . $_GET['filename'])); |
|
37 | + $data = new \SimpleXMLElement(file_get_contents($dir.'/'.$_GET['filename'])); |
|
38 | 38 | $orders = new \Exchange1c\Parser\Orders($data); |
39 | 39 | $orders->process(); |
40 | 40 | } |
@@ -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: |