File tree 1 file changed +14
-14
lines changed
1 file changed +14
-14
lines changed Original file line number Diff line number Diff line change @@ -123,19 +123,19 @@ protected function importCsv()
123
123
$ import = $ this ->createNewImport ();
124
124
$ chunks = (new ChunkIterator ($ this ->csvRecords ->getIterator (), 10 ))->get ();
125
125
126
- // $jobs = collect($chunks)
127
- // ->map(
128
- // fn ($chunk) => new ImportCsv(
129
- // $import,
130
- // $this->model,
131
- // $chunk,
132
- // $this->columnsToMap
133
- // )
134
- // );
135
-
136
- // Bus::batch($jobs)
137
- // ->finally(
138
- // fn () => $import->touch('compoleted_at')
139
- // )->dispatch();
126
+ $ jobs = collect ($ chunks )
127
+ ->map (
128
+ fn ($ chunk ) => new ImportCsv (
129
+ $ import ,
130
+ $ this ->model ,
131
+ $ chunk ,
132
+ $ this ->columnsToMap
133
+ )
134
+ );
135
+
136
+ Bus::batch ($ jobs )
137
+ ->finally (
138
+ fn () => $ import ->touch ('compoleted_at ' )
139
+ )->dispatch ();
140
140
}
141
141
}
You can’t perform that action at this time.
0 commit comments