Files
qds/app/Imports/ExcelImport.php
dhanabalan 3f0d529640
All checks were successful
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 1m4s
Initial commit for new repo
2025-12-16 17:05:04 +05:30

27 lines
467 B
PHP

<?php
namespace App\Imports;
use Illuminate\Support\Collection;
use Maatwebsite\Excel\Concerns\ToCollection;
class ExcelImport implements ToCollection
{
public $rows = [];
/**
* @param Collection $collection
*/
public function collection(Collection $collection)
{
foreach($collection as $item) {
self::$rows[] = $item->toArray();
}
}
public function getRows()
{
return self::$rows;
}
}