@@ -330,7 +330,7 @@ discard block |
||
| 330 | 330 | } |
| 331 | 331 | |
| 332 | 332 | // clean "false positive" space groups |
| 333 | - $spaceGroups = array_filter($spaceGroups, function ($spaceGroup) { |
|
| 333 | + $spaceGroups = array_filter($spaceGroups, function($spaceGroup) { |
|
| 334 | 334 | return $spaceGroup['end'] - $spaceGroup['start'] > 1; |
| 335 | 335 | }); |
| 336 | 336 | |
@@ -364,7 +364,7 @@ discard block |
||
| 364 | 364 | $tmpPath = $this->temporaryDirectoryPath . '/' . rand(0, 10000) . '.txt'; |
| 365 | 365 | $process = new Process('/usr/bin/pdftotext -layout ' . $filePath . ' ' . $tmpPath); |
| 366 | 366 | $this->logger->info('Execute Pdftotext', ['file' => $filePath]); |
| 367 | - $process->run(function ($type, $buffer) { |
|
| 367 | + $process->run(function($type, $buffer) { |
|
| 368 | 368 | if (Process::ERR === $type) { |
| 369 | 369 | echo 'ERR > ' . $buffer; |
| 370 | 370 | } else { |
@@ -26,7 +26,7 @@ discard block |
||
| 26 | 26 | */ |
| 27 | 27 | public function format(ArrayCollection $data) |
| 28 | 28 | { |
| 29 | - $data = $data->map(function ($item) { |
|
| 29 | + $data = $data->map(function($item) { |
|
| 30 | 30 | // Date |
| 31 | 31 | $dateRaw = $item[1]; |
| 32 | 32 | $date = new \DateTime(); |
@@ -35,10 +35,10 @@ discard block |
||
| 35 | 35 | |
| 36 | 36 | // Value |
| 37 | 37 | if (strlen($item[3])) { |
| 38 | - $value = abs((float) str_replace(',', '.', str_replace(' ', '', $item[3]))); |
|
| 38 | + $value = abs((float)str_replace(',', '.', str_replace(' ', '', $item[3]))); |
|
| 39 | 39 | $debit = true; |
| 40 | 40 | } else { |
| 41 | - $value = (float) str_replace(',', '.', str_replace(' ', '', $item[4])); |
|
| 41 | + $value = (float)str_replace(',', '.', str_replace(' ', '', $item[4])); |
|
| 42 | 42 | $debit = false; |
| 43 | 43 | } |
| 44 | 44 | |
@@ -22,7 +22,7 @@ |
||
| 22 | 22 | |
| 23 | 23 | public function __toString() |
| 24 | 24 | { |
| 25 | - return (string) $this->configuration['name']; |
|
| 25 | + return (string)$this->configuration['name']; |
|
| 26 | 26 | } |
| 27 | 27 | |
| 28 | 28 | public function frenchDateFormatter($raw) |
@@ -26,20 +26,20 @@ |
||
| 26 | 26 | */ |
| 27 | 27 | public function format(ArrayCollection $data) |
| 28 | 28 | { |
| 29 | - $data = $data->map(function ($item) { |
|
| 29 | + $data = $data->map(function($item) { |
|
| 30 | 30 | // Date |
| 31 | 31 | $dateRaw = $item[2]; |
| 32 | 32 | $date = new \DateTime(); |
| 33 | - $date->setDate(2000 + (int) substr($dateRaw, 6, 2), (int) substr($dateRaw, 3, 2), (int) substr($dateRaw, 0, 2)); |
|
| 33 | + $date->setDate(2000 + (int)substr($dateRaw, 6, 2), (int)substr($dateRaw, 3, 2), (int)substr($dateRaw, 0, 2)); |
|
| 34 | 34 | $date->setTime(12, 0, 0); |
| 35 | 35 | // Value |
| 36 | 36 | $debitRaw = $item[3]; |
| 37 | 37 | if (strlen($debitRaw)) { |
| 38 | - $value = abs((float) str_replace(',', '.', str_replace(' ', '', $debitRaw))); |
|
| 38 | + $value = abs((float)str_replace(',', '.', str_replace(' ', '', $debitRaw))); |
|
| 39 | 39 | $debit = true; |
| 40 | 40 | } else { |
| 41 | 41 | $creditRaw = $item[4]; |
| 42 | - $value = (float) str_replace(',', '.', str_replace(' ', '', $creditRaw)); |
|
| 42 | + $value = (float)str_replace(',', '.', str_replace(' ', '', $creditRaw)); |
|
| 43 | 43 | $debit = false; |
| 44 | 44 | } |
| 45 | 45 | |
@@ -28,27 +28,27 @@ |
||
| 28 | 28 | */ |
| 29 | 29 | public function format(ArrayCollection $data) |
| 30 | 30 | { |
| 31 | - $data = $data->map(function ($item) { |
|
| 31 | + $data = $data->map(function($item) { |
|
| 32 | 32 | // Date |
| 33 | 33 | $dateRaw = $item[0]; |
| 34 | 34 | $date = new \DateTime(); |
| 35 | - $date->setDate((int) substr($dateRaw, 6, 4), (int) substr($dateRaw, 3, 2), (int) substr($dateRaw, 0, 2)); |
|
| 35 | + $date->setDate((int)substr($dateRaw, 6, 4), (int)substr($dateRaw, 3, 2), (int)substr($dateRaw, 0, 2)); |
|
| 36 | 36 | $date->setTime(12, 0, 0); |
| 37 | 37 | |
| 38 | 38 | // Value Date |
| 39 | 39 | $dateRaw = $item[1]; |
| 40 | 40 | $valueDate = new \DateTime(); |
| 41 | - $valueDate->setDate((int) substr($dateRaw, 6, 4), (int) substr($dateRaw, 3, 2), (int) substr($dateRaw, 0, 2)); |
|
| 41 | + $valueDate->setDate((int)substr($dateRaw, 6, 4), (int)substr($dateRaw, 3, 2), (int)substr($dateRaw, 0, 2)); |
|
| 42 | 42 | $valueDate->setTime(12, 0, 0); |
| 43 | 43 | |
| 44 | 44 | // Value |
| 45 | 45 | $debitRaw = $item[3]; |
| 46 | 46 | if (strlen($debitRaw)) { |
| 47 | - $value = abs((float) str_replace(',', '.', str_replace('.', '', $debitRaw))); |
|
| 47 | + $value = abs((float)str_replace(',', '.', str_replace('.', '', $debitRaw))); |
|
| 48 | 48 | $debit = true; |
| 49 | 49 | } else { |
| 50 | 50 | $creditRaw = $item[4]; |
| 51 | - $value = (float) str_replace(',', '.', str_replace('.', '', $creditRaw)); |
|
| 51 | + $value = (float)str_replace(',', '.', str_replace('.', '', $creditRaw)); |
|
| 52 | 52 | $debit = false; |
| 53 | 53 | } |
| 54 | 54 | |