Completed
Push — develop ( 0e60d3...418abb )
by Abdelrahman
10:31
created

DefaultImporter::getFile()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Cortex\Foundation\Importers;
6
7
use Maatwebsite\Excel\Files\ExcelFile;
8
9
class DefaultImporter extends ExcelFile
10
{
11
    /**
12
     * The importer config.
13
     *
14
     * @var array
15
     */
16
    public $config = [
17
        'name' => 'name',
18
        'log' => true,
19
    ];
20
21
    /**
22
     * {@inheritdoc}
23
     */
24
    protected $delimiter = ';';
25
26
    /**
27
     * {@inheritdoc}
28
     */
29
    protected $enclosure = '"';
30
31
    /**
32
     * {@inheritdoc}
33
     */
34
    protected $lineEnding = '\r\n';
35
36
    /**
37
     * {@inheritdoc}
38
     */
39
    public function getFile()
40
    {
41
        return request()->file('file');
42
    }
43
}
44