Add headers to csv file. #539

This commit is contained in:
Korina Cordero 2021-03-02 01:49:03 +00:00
parent fd8845118e
commit 8f839674b5

View file

@ -77,6 +77,23 @@ class GenerateCustomerSourceReportCommand extends Command
'year' => $year,
]);
// add header rows
fputcsv($fp, [
'Customer ID',
'First Name',
'Last Name',
'Mobile Phone',
'Landline',
'Office Phone',
'Fax',
'Email Address',
'Vehicle Manufacturer',
'Vehicle Make',
'Model Year',
'Plate Number',
'Source',
]);
// go through rows
while ($row = $stmt->fetch(PDO::FETCH_NUM))
{