Add validation to importers to fix invalid/empty columns #222

This commit is contained in:
Nabeel Shahzad
2018-03-30 17:27:29 -05:00
parent bd30b1f900
commit 63544088cd
21 changed files with 124 additions and 68 deletions

View File

@@ -53,7 +53,7 @@ class ExportService extends Service
$writer = $this->openCsv($path);
// Write out the header first
$writer->insertOne($exporter->getColumns());
$writer->insertOne(array_keys($exporter->getColumns()));
// Write the rest of the rows
foreach ($collection as $row) {