Completed
Push — master ( 49d50b...c2310d )
by Maxime
11s
created
src/Distilleries/Expendable/Exports/BaseExport.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -32,6 +32,9 @@
 block discarded – undo
32 32
         $this->setRange($data);
33 33
     }
34 34
 
35
+    /**
36
+     * @param string $fileName
37
+     */
35 38
     public function export($fileName)
36 39
     {
37 40
         return $this->download($fileName);
Please login to merge, or discard this patch.
src/Distilleries/Expendable/Imports/BaseImport.php 2 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -20,6 +20,9 @@
 block discarded – undo
20 20
         $this->setModel($model);
21 21
     }
22 22
 
23
+    /**
24
+     * @param string $filepath
25
+     */
23 26
     public function importFromFile($filepath)
24 27
     {
25 28
         return $this->import($filepath);
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
     public function model(array $row)
32 32
     {
33 33
         $data = [];
34
-        foreach($this->model->getFillable() as $value)
34
+        foreach ($this->model->getFillable() as $value)
35 35
         {
36 36
             $data[$value] = $row[$value];
37 37
         }
Please login to merge, or discard this patch.
src/Distilleries/Expendable/States/ExportStateTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
         $dateStart = !empty($data['range']) && !empty($data['range']['start']) ? $data['range']['start'] : Carbon::now()->format('Y-m-d');
54 54
         $dateEnd = !empty($data['range']) && !empty($data['range']['end']) ? $data['range']['end'] : Carbon::now()->format('Y-m-d');
55 55
         $type = !empty($data['type']) ? $data['type'] : 'csv';
56
-        $filename = $dateStart . ' ' . $dateEnd . '.' . $type;
56
+        $filename = $dateStart.' '.$dateEnd.'.'.$type;
57 57
 
58 58
         return (new BaseExport($this->model, $data))->export($filename);
59 59
     }
Please login to merge, or discard this patch.